« first day (900 days earlier)      last day (4055 days later) » 

10:00 PM
(clang doesn't seem to treat the friend as a new declaration or friend the original declaration, if you play around with it, so it seems to be a bug no matter what)
 
GCC probably on grounds of being GCC
 
@R.MartinhoFernandes GSQ?
@CatPlusPlus icc is EDG though, they're pretty good
 
Yeah... no
 
@StephenLin Gratuitous Standard Quotes ;)
 
haha
ok, well, let me know if you find anything
i think it ought to be legal unless there's something else
 
10:00 PM
Anyway, that seems a tad out of my sphere of standardese knowledge.
 
so gcc and icc seem to be in error
yeah, it's a nitpick
 
Did you ping him? @Johannes
 
it doesn't autocomplete
 
@StephenLin Your comment looks to me as though it is a new (related) question
 
since he's not on
well, technically its a the same question
 
10:01 PM
He was here a few hours ago, so he will receive a ping anyway when he logs back in.
 
so I just spell his name without the spaces?
 
Stand in front of the mirror and say his name three times and you'll get a standard quote
15
 
lol
 
Ell
@BartekBanachewicz how are you deleting such gl_id s at the minute?
 
10:02 PM
@sehe it's the same question actually, he only answered in the qualified name case since that's the example I gave
 
@StephenLin Yeah. Or just the start.
 
@R.MartinhoFernandes To be fair, that answer is a bit more than the usual Luchian/Kerrek/Tomalak level standards quoting. I honestly don't know how he keeps that information straight in his mind.
 
@JohannesSchaub-litb ping (stackoverflow.com/a/15692739/2008149 follow up)
 
@CatPlusPlus made my day
 
@sehe Right on time, huh?
 
user142019
10:03 PM
He will get a red dot in the multicollider anyway, won't he?
 
@R.MartinhoFernandes Darn, that's early yeah
@StephenLin You do realize he gets notifications for comments on his own answers anyways
 
user142019
@R.MartinhoFernandes lol
 
user142019
Okay.
 
user142019
It's "tomorrow".
 
10:04 PM
Now. I know I was in the middle of something.
 
user142019
Time to do homework.
 
@R.MartinhoFernandes You were polishing up older highvoted answers?
 
@sehe oh, right
 
@Zoidberg It's never tomorrow
 
10:05 PM
I love the fuzzy clock.
 
user142019
@sehe but it is "tomorrow"!
 
@R.MartinhoFernandes And you were in the middle of the week, a few minutes ago
 
regarding that VB string question.... are strings in .net immutable... aka doing for with push_back is gazzilion times faster than doing same thing in .net ?
 
@sehe well, was hoping he happened to be on here anyway
that's why i came on
 
@NoSenseEtAl Yes. In .NET you would use a StringBuilder for that scenario.
Only noobs append to strings in loops.
 
10:06 PM
@R.MartinhoFernandes I do... :D when i generate test csv data. Any way maybe you should A that Q. :)
 
StringBuilders are pretty decent. And they have 'stream adaptors' (StringWriter). If all else fails, (Unmanaged)MemoryStream
 
Also, note that the C# compiler will optimise things like string s = a + b + c + d; to string s = string.Concat(a, b, c, d); (i.e. single allocation) which is really cool and something that Java took years to get.
 
user142019
0
Q: regex undeclared (Dev C++)

user2136754#include <iostream> #include <fstream> #include <string> #include <vector> #include <regex.h> using namespace std; string input; int main() { //Input .ply file ifstream inputFile ("input.ply"); //input file is read if (inputFile.is_open()) { int i = 1; //Line ...

 
user142019
lol Dev-C++
 
@NoSenseEtAl Wut? That has been asked a gazillion times
9
A: Why is StringBuilder slower than string concatenation?

seheChange so that the StringBuilder isn't instantiated all the time, instead .Clear() it: time: 1 String + : 3348ms StringBuilder : 3151ms time: 2 String + : 3346ms StringBuilder : 3050ms etc. Note that this still tests exactly the same functionality, but tries to reuse resou...

I remember that one
 
@R.MartinhoFernandes What about it? Is it C++11 regex support?
 
@NoSenseEtAl I think this is the best choice: msdn.microsoft.com/en-us/library/dd991828.aspx. No loops, no nothing.
@sehe Dunno.
Just bringing it out here in case someone cares. I don't.
 
Probably wishful thinking then
 
10:10 PM
@sehe regex in gcc... is it 1 April :P @R.MartinhoFernandes IDK, me cant think in C# :(
 
@R.MartinhoFernandes Arrrrg. Not seriously for large-scale text processing, right?
@NoSenseEtAl Well, it's gonna get done one day
 
Ell
I think I can use a value_deleter and a unique_ptr which deadmg told me to use long ago when I first asked this question
 
@sehe Erm, why not?
 
@R.MartinhoFernandes Because I don't think it will. Scale, I mean
 
Barring idiotic implementation, it scales as well as good ole loop with StringBuilder.
 
10:11 PM
@Ell why would you want to use unique_ptr
no pointers needed
 
Ell
@BartekBanachewicz because it's already there
 
I loop and append :(
 
Ell
and it wouldn't be a pointer
just a ready made RAII
 
well, uh
adding template deleter to gl_id is also quite easy
 
@sehe I cannot look at it right now, but I expect the implementation to be: the usual test for Collection<T> for optimising to one allocation; fallback to loop with StringBuilder otherwise.
 
10:12 PM
just SFINAE on glDeleteXs and glDelete
 
It's not rocket science.
 
If you had to make a networked version of sodoku, how many classes would that probably break down to and what would their purposes be? I imagine a client and a server, and a board... but what else?
 
@Crowz no. just no.
 
Concat will lead to lot's of instantiations of small helper classes, right. 3000x concat, will instantiate at least 3000 IEnumerable implementations, AFAICT.
 
@BartekBanachewicz why u hate me bby
 
10:12 PM
WHAT
 
btw this perf talk made me wonder... does somebody know why map doesnt have reserve... stability of iterators and deallocation problems ?
 
@R.MartinhoFernandes Hmm. Ah. You expect that to be optimized specifically for String. I don't, actually. I expect StringBuilder to be optimized to death, but not Concat (being a generic extension method)
 
@Crowz because you are asking questions that don't make sense. You are supposed to solve the problems and design the classes
 
@NoSenseEtAl because it's a tree, usually
 
Ell
@Crowz Server class, Client handle, client, board, probsies :3
 
10:13 PM
there must be a conventional way to do it
 
@CatPlusPlus this is old, but what do you mean by no? icc is usually ok about standards right?
 
@sehe Yes, I expect string.Concat to be optimised for string, because what else would it be optimised for?
 
user142019
@Crowz socket, message.
 
@R.MartinhoFernandes Wait, I was on the wrong track. I didn't know about string.Concat :)
 
@CatPlusPlus or was that about something else?
 
10:14 PM
Oops.
Can you tell, I don't use it
 
@sehe doesnt matter... I built trees that store data to vector, but those dont have deallocation :D
 
Ell
@BartekBanachewicz I can't "just SFINAE" anything :'(
 
@Zoidberg what would those do? Don't you put socket and message inside of the client and server?
 
I don't think there are regulars that have dabbled in Rust, are there?
 
@NoSenseEtAl (a) you're not making much sense to me (b) please reply to specific messages
 
user142019
10:15 PM
@Crowz If you want to duplicate socket stuff, sure.
 
@LucDanton You did, IIRC
 
@sehe Yeah, for a moment there I had to go back and check if I had linked to the right MSDN page.
 
@Ell what?
 
@sehe I haven't.
 
user142019
(Pro tip: have a class abstracting the concept "socket".)
 
10:15 PM
@LucDanton Does building a hello world count?
 
@sehe i had vector and pointers to next nodes were idxs in vector... but no deallocation
 
@R.MartinhoFernandes It may be the furthest any of us have reached!
 
I did read most of the manual.
 
user142019
You can build "server" and "client" on top of that through composition.
 
@Zoidberg well, yeah, you'd be kind of making the same code twice in some ways, right? Especially on receiveMessage() and sendMessage()
 
10:16 PM
Mar 13 at 3:18, by Rapptz
then you'd like Rust
 
Ell
@BartekBanachewicz I haven't quite figured out SFINAE yet
 
They've released 0.6 and I'm interested in the changes to nominal/structural typing.
 
@Ell oh welp then going into intricacies of unique_ptr isn't a very wise idea
 
Guess I'll read the manual.
 
@Ell you know, basic stuff first.
I have to refactor minicraft.
 
Ell
10:17 PM
It's okay, I don't think it really is an intricacy
 
@LucDanton The robot liked some things:
Aug 28 '12 at 18:50, by R. Martinho Fernandes
I like Rust's check, prove, claim thingies.
But not all things:
Aug 28 '12 at 18:42, by R. Martinho Fernandes
Rust sounds weird.
 
... ok I guess I'll let you search chat history on your own :|
 
@sehe I think all those were dropped in later releases though.
 
@Ell you were supposed to learn OpenGL :) And it seems you are learning C++
just pointing out how difficult game making actually is.
 
Ell
10:18 PM
@BartekBanachewicz Gotta learn c++ with something :P
 
@Ell no, that doesn't work that way
learning C++ and OpenGL at the same time will only cause you headaches
 
> A structure is a nominal structure type defined with the keyword struct. [...] A tuple structure is a nominal tuple type, also defined with the keyword struct.
Oh boy.
 
I think 'nominal structure' and 'nominal tuples' explain better the differences of both. The Rust devs use some really, really wild naming schemes. Only at first though, it tends to mature to something saner at some point.
 
Xeo
@LucDanton Well, a tuple really is just a struct, no? Or the other way around, depending on how you see it.
 
10:20 PM
I like that they don't cater to the lowest common denominator.
 
user142019
The C in C++ means "clusterfuck".
 
@Xeo Information theoretically speaking, yes. But no, one isn't 'really just' the other.
Or one isn't 'basically' the other.
 
also, zoidberg, would a class for userInterface that includes any graphical stuff be a good idea, or just include that in board?
 
Abuse of language via 'really', 'just' and 'basically' basically really annoys me, sorry.
 
@Crowz it's not that simple
uh
I am too tired
 
user142019
10:22 PM
namespace graphics :v
 
also classes at 7:30 AM
 
@Xeo Time for tossing some more terms at you! Tuples are isomorphic to structs with members of the same types.
 
user142019
@BartekBanachewicz dat pun.
 
@Zoidberg fucking singleton in disguise
 
@R.MartinhoFernandes Oh yeah, he really doesn't like that.
 
user142019
10:22 PM
@BartekBanachewicz no.
 
@BartekBanachewicz high level yo. Just would it be a more conventional way to implement it?
 
@LucDanton Couldn't find a spot for "just"?
 
user142019
Stateless namespace.
 
stateless graphics ftw.
you still need a context, no?
 
user142019
You pass state to each function.
 
10:23 PM
ya
 
oh right.
 
user142019
Or you have a context class with member functions.
 
oh right
and basically you have a class.
 
user142019
But hey
 
user142019
at least it's not called userInterface.
 
Ell
10:24 PM
@BartekBanachewicz well I think I have a sufficient amount of c++
 
user142019
(Seriously the question is weird.)
 
heh, right :)
 
Ell
c++03 anyway xD
 
@BartekBanachewicz Oooh, environment monads.
 
@Ell said no one ever
 
user142019
10:24 PM
> graphical stuff
 
I am going to sleep and design for a while
@R.MartinhoFernandes monads :/
 
Xeo
Erm, question: Are Rust's traits the same thing as Haskell's type classes? It almost seems like that.
 
Ell
Nighty night
 
@Xeo Yes, quite similar.
Which is awesome, btw.
 
Ah, it appears they don't have a record system or structural typing. So more of a clarification in terminology than anything else.
 
10:27 PM
@LucDanton IIRC tuples are structural types.
 
goodnight losers
 
Oh, nevermind, my memories confused me.
 
Would Lightness mind if I announced my plonking him?
 
user142019
Nah, he didn't mind me plonking him either.
 
user142019
(AFAIK, I couldn't quite tell since his messages are to me invisible.)
 
10:32 PM
@sehe are you still fighting?
 
@JohanLarsson No?
 
why plonk then?
 
I found it slightly amusing the way he decided to greet the loungers just there
Whether or not I actually plonk people should be largely irrelevant.
 
Today, this person displayed a rather large abundance of disrespect, yet he self righteously judges left and right.
I just proposed the mental exercise that I could consider returning the favour. That would make a bit more sense to me
(maybe rudeness/indifference would be more apt rather than 'disrespect'; however, I couldn't find the word... and there was disrespect)
 
10:38 PM
Dammit, cannot find an overlay with Rust 0.6.
 
I have read ~2% of todays transcript so no idea
 
I guess it's time to figure out how to set up my own.
 
We need to stop using the term “patent troll”, it evokes a prankster rather than a mobster. It’s a serious crime, not a joke.
True dat.
 
user142019
lol
 
user142019
Some guy I'm chatting with is trying to get Torshamer (DoS tool) to work.
 
Ell
10:40 PM
Ahh I think I remember why I didn't use unique_ptr
 
user142019
He can't get it to work since he doesn't know how to open Python. :pacefalm:
 
@JohanLarsson You measure that - lol
 
user142019
Oh today's.
 
estimate
 
user142019
Ik loop mijn strot vol te stouwen met chips.
 
user142019
10:42 PM
I feel bad for doing it. :(
 
een vlotte strop
 
user142019
People in Africa are starving.
 
@Zoidberg That's not the reason, right
 
user142019
@sehe it's the reason I feel bad.
 
Ell
/home/elliot/Programming/ZoidbergSucks/include/Shader.hpp:8:55: error: ‘__glewDeleteShader’ is not a valid template argument for type ‘void (*)(unsigned int)’
/home/elliot/Programming/ZoidbergSucks/include/Shader.hpp:8:55: error: it must be the address of a function with external linkage
 - does that mean I can't use a function pointer?
 
user142019
10:43 PM
@Ell lol "it"
 
@Zoidberg ow. hmm. how conscientious
@Ell No. It means you can only pass the address of a function named with external linkage
 
Ell
Also, you like the name? :3
 
user142019
To be honest… no. :v
 
Ell
Aww cmon. It's a clever pun.
 
user142019
xd
 
user142019
10:45 PM
That's right.
 
user142019
I was working on voxx.
 
user142019
I had the planet name generator complete.
 
Ell
gl + elliot = jellyot!
 
That makes zero sense
 
Ell
anywho. I'm wondering why it won't work :(
I mean, I don't really undersand what external linkage means
 
user142019
10:48 PM
Linkage that is external!
 
Ell
but what is that? :'(
if you can use a function in the same file, it is hardly intuitive to understand :3
 
External linkage means the one entity is visible, and can be referred to, across the whole program.
 
Ell
Hmm
 
user142019
Good Scott.
 
Ell
I don't know why this isn't visible
 
user142019
10:54 PM
Scott's learning Haskell.
 
user142019
Hurray for Scott.
 
Ell
I think I might favour inheritence over composition :3
 
user142019
What are you trying to do?
 
Ell
I want to not to have to keep track of GLuints
 
user142019
You want to encapsulate OpenGL objects, right? Such as buffers, shaders, programs…
 
Ell
11:00 PM
deadmg suggested unique_ptr with a value deleter, and bartek suggested his own gl_id raii class which essentially does the same thing
That is correct
 
user142019
I would do the latter.
 
user142019
std::unique_ptr without pointers is a lot of hassle and very annoying to get to work. It also feels weird, IMO. You'll have to deal with nullptr. :puke:
 
Ell
but I can't figure out how to use bartek or deadmgs suggestions because functions such as glDeleteShader can't be used because they apparently don't have external linkage
Yeah it does feel weird. I get confused because I start thinking things are pointers when they aren't :3
 
user142019
Uh, gimme a sec.
 
Ell
okay. while you're doing whatever Ima fetch myself some cereal
 
user142019
11:03 PM
template<typename Deleter>
class gl_object {
public:
    gl_object(GLuint handle_, Deleter deleter_) : handle{handle_}, deleter(deleter_) { }
    // delete copy ctor and implement move ctor
    ~gl_object() { deleter(); }

    GLuint handle;

private:
    Deleter deleter;
};
 
@Ell They can be used.
 
Ell
Okay I'm back
 
You can't use them as a template argument. That doesn't mean you can't use them ever.
 
Ell
Ahh I did something silly. I did that^
template <typename Deleter, Deleter d>...
 
(Disregarding the fact that C++11 relaxed the requirement on linkage.)
 
Ell
11:05 PM
Thank you very muchly!
 
user142019
Uh, by the way…
 
Ell
uh oh xD
go on
 
user142019
Once you have such a gl_object class, you can implement buffer and shader and program types on top of it using composition.
 
user142019
Just an idea.
 
Ell
Yeah that's what I was going to do :3
 
user142019
11:06 PM
Ok. Good idea.
 
Ell
Man. I've started replacing :L with :3
 
user142019
Maybe you should rename yourself to Threeee.
 
user142019
And Threeeeiot.
 
Ell
haha yeah
 
1 hour ago, by Zoidberg
@sehe dat name.
 
user142019
11:08 PM
..
¬
 
user142019
@sehe idIOTA.
 
user142019
Be sure to delete copy ctor and assignment and implement move ctor and assignment in gl_object or else FAIL.
 
Ell
yeah
I can't have a default ctor can I?
 
user142019
(GLuint will just copy when you try to move it, you need some dummy value or an extra Boolean meaning "don't delete this" which you set to true after moving from.)
 
Ell
meh no.
 
user142019
11:12 PM
bool skip_deletion;
gl_object(gl_object&& other) : handle{other.handle} { other.skip_deletion = true; }
gl_object& operator=(gl_object&& other) { swap(*this, other); }
~gl_object() { if (!skip_deletion) deleter(handle); }
friend void swap(gl_object& a, gl_object& b) { /* you get the point */ }
 
user142019
At least, this is how I always do it. :v
 
Ell
Yeah
glDeleteShader(0) doesn't do anything anyway so I can set the other thing's handle to 0
 
user142019
Ah okay.
 
user142019
Then you don't need the flag.
 
Ell
Right
I ought to buy everyone in the lounge a pint for helping me ever since I started here :p
3
 
11:15 PM
@Zoidberg Your op= does not destroy its the existing value NAO but at some point in the future.
 
user142019
@R.MartinhoFernandes Oh it should do that immediately? :v
 
user142019
Oh right.
 
@Ell Noted.
 
Move the argument to a local variable or take the argument by value.
 
Ell
Heh
 
11:15 PM
@Zoidberg Not required, but I think it's a good idea.
 
@Zoidberg Isn't there a missing return in operator=?
 
user142019
@EtiennedeMartel dammit I ALWAYS forget that. :)
 
@Zoidberg If I write x = std::move(some_static); I don't want the old value of x to stay around forever.
 
user142019
But I trust Ell in that he enables warnings (or he will have his bones ground… to dust).
 
user142019
11:17 PM
@R.MartinhoFernandes right.
 
Ell
I do indeed :3
 
user142019
@Ell see robot's ramblings about move assignment.
 
user142019
Ignore me now. I'm a noob at C++.
 
@Xeo, lol did you accept the robot's answer so he can't delete it later?
 
Xeo
Shhh...!
 
11:22 PM
You bastard.
 
aahahahahahahaaaa
 
user142019
Once happened to me.
 
user142019
I posted a terrible answer and OP accepted it.
 
user142019
I just flagged it with explanation and a friendly mod deleted it for me.
 
user142019
It even got two (IIRC) upvotes blah.
 
Ell
11:24 PM
hm this one is new to me: error: expression list treated as compound expression in mem-initializer
 
user142019
Line and code.
 
Trailing semicolon.
 
Ell
Shader::Shader(ShaderType type, std::string source) :
	glHandle(glCreateShader(static_cast<GLenum>(type)), glDeleteShader)
	{
    ...
 
Ell
glHandle is what zoidberg posted earlier. or something like it
let me upload
 
11:26 PM
An attempt at trolling the haskell IRC channel goes horribly... right? https://gist.github.com/quchen/5280339
 
user142019
Nice namespace name.
 
@R.MartinhoFernandes *Fammit
 
Ell
@Zoidberg Thank you, I thought you'd like it
 
user142019
@Ell GlId(deleter_t d) : glHandle(0), deleter(d) { Y U NO explicit
 
Ell
I'm confused, why do I need explicit? :O
 
user142019
11:28 PM
@Ell what is the declaration of glHandle?
 
Ell
GlId<decltype(glDeleteShader)>& glHandle;
 
user142019
@Ell you don't want implicit conversion of deleter to handle I suppose.
 
user142019
@Ell don't make it a reference. :v
 
Ell
oops. I modified wrong thing to be reference :L
 
user142019
:pacefalm:
 
user142019
11:29 PM
lol
 
Ell
heh yay it worketh now
thank you!
 
user142019
Note that this will make your shader uncopyable.
 
user142019
Though you probably want that anyway.
 
Ell
Yeah
 
user142019
So it's a good thing!
 
11:30 PM
> 13:21 < Iceland_jack> xQuasar: We are cooperating with you, you're just not aware that your goal is learning Haskell
 
Ell
I don't think it's possible to copy a shader o.O
 
user142019
No and it makes no sense either.
 
user142019
You can create a new one with the same source, though.
 
Ell
Yeah
 
user142019
But supporting that through a copy ctor is just silly.
 
user142019
11:31 PM
Nobody is going to copy a shader ever.
 
Ell
exactly
Do you think it would be bad to make a GlObject class to save me from having to keep writing GetHandle over and over?
or is that a bad design?
 
user142019
You could have implicit conversion to GLuint. :L
 
user142019
But I'm not sure if that's good in this situation.
 
user142019
Implicit conversions are generally bad.
 
user1182183
well installed all the needed shit on my new laptop and the free space went from 720 gb to 300 gb ;>
 
11:39 PM
What is the needed stuff?
 
user142019
0
Q: How to call any vegetable in Python?

DogI have the following class: Help on class A in module a: class A(__builtin__.object) | Methods defined here: | | any vegetable(self) | TODO document this | | getHeight(self) | uses the chicken to measure it Calling any vegetable doesn't work: >>> a.A().any vegetable()...

 
user142019
LOL
 
user1182183
games, vs12, some other programs
 
user1182183
xd
 
user1182183
no, no porn...
 
user142019
11:42 PM
lol too localized
 
user1182183
well windows 8 isn't that bad after all, I mean after you download shitloads of programs to turn it into windows 7
 
Ell
I'm not sure what the Program class should accept as input to link shaders together
iterators? It needs the shader objects, but can't copy them obviously
 
How many games? :\
 
user1182183
42
 
user1182183
+ a few more downloading
 
11:44 PM
How many do you actively use?
 
Alright, so, let it be said that "New Junk City" has one of the best basslines of the fourth generation.
 
user1182183
actively , friday ~2-3, saturday ~ 5 more and sunday some other ~5
 
(With the best bassline being, of course, "Dancing Mad")
 
user1182183
175 gb of games ; o
 
user142019
@Dog: find the authors of this code. Hit them repeatedly with a foam-based cluebat. Repeat as necessary. — DSM 19 secs ago
 
user142019
11:50 PM
Genius.
 
Ell
wtf. This was just posted on facebook: i.imgur.com/3ZFDa.gif [NSFW]
 
user142019
LOL
 
user142019
Most Vexing Used Cunt
 
Has anybody here made and sold a game?
 

« first day (900 days earlier)      last day (4055 days later) »