« first day (712 days earlier)      last day (4237 days later) » 

11:00 PM
I've been the victim of many sarcasm attacks upon my person.
You all suck!
 
sbi
For heaven's sake! That language is called Brainfuck! There, I said it. Just spell it out. It's a programming language, not a brothel. I bet you all say "Fuck" at least twice a day. Don't you know how to spell it? — sbi Nov 18 '10 at 23:31
 
Ell
Its called "brainfudge"
 
fuck fuck fuck fuck fuck
 
what the heck? bonsaikitten.com now redirects to www.thinkgeek.com/geektoys/plush/?
 
Ell
11:01 PM
Fudge fudge fudge fudgee
 
@TonyTheLion You sir have some stamina
@Ell eeeeee
 
Yo momma's so fat, there's a strong chance of her developing type 2 diabetes.
 
Jul 27 '11 at 20:43, by sbi
@MartinhoFernandes Yeah! That's it! Henceforth I will refer to it as Bra*nfuck! You're a genius.
Sigh.
 
Ell
Tginkgeek is so overpriced for plushies delivered to UK. Like $70 for a plushy
 
sbi
11:02 PM
@R.MartinhoFernandes I was just pointing out that I had been commenting on the same non-C++ language!
 
@Ell sarcasm markdown that when used doesn't actually work?
 
Ell
What are your opinions on jokes about diseases? Okay? Not okay?
 
sbi
@Ell Have you tried ThinkGeek?
 
Ell
:3
 
11:03 PM
@Ell this sarcasm mark؟
 
sbi
@Ell It's fine for you to joke about the diseases you have.
 
Funny jokes are ok.
 
Ell
German jokes not?
 
sbi
Damn. I have another 50GB of mp3 and jpg files, and it seems I'm gonna run out of disk space.
 
11:07 PM
@Ell How can they be funny if I don't understand them?
 
Ell
:P as in jokes where the lack of funny punchline makes them funny
I think that diabetes one would be classed as a German joke
Ahh my face is leaking
I'm gonna try and sleep now. Nighty night all
 
@R.MartinhoFernandes OTOH our sun is not as harsh as that one.
 
@Ell or this one¿
 
That's not how you use the Spanish inverted question mark.
 
11:11 PM
¿How do you use the Spanish inverted question mark?
 
^ Repost, just for @sbi
he he
 
sbi
@Cheersandhth.-Alf Did you post that before? Like many months ago? Because ISTR it.
 
alright, I'm off, be back married
 
@MooingDuck congratulations!
 
11:18 PM
@MooingDuck Have fun!
 
Xeo
@MooingDuck Have fun, don't faint!
@R.MartinhoFernandes Why do they even have that? To make you read the sentence with the right intonation from the beginning?
 
Don't worry about what this means, it's a programming assignment.
std::pair<int, int> FileReader::GetNextDoco()
{
static int next = -1;
return next++, data.docos.at(next);
}
Is this legal?
 
@MooingDuck Good luck!
 
11:24 PM
@Cheersandhth.-Alf Does it do what I think it does?
 
Xeo
@Drise wh...*whyyyyy?!* Other than that, no, there is no i :P
 
hm, applying ESP circuit...
well, i dunno
 
@Drise Probably not, who knows? next is useless here.
 
@Xeo Should be next, but yea, compiler already complained.
 
Xeo
If that i is a next, why not do .at(++next)
 
11:25 PM
@Drise This is not fine.
 
@Xeo Oooo, good idea.
 
@LucDanton why?
 
Don't comma expressions evaluate to their last expression? Shouldn't that rather be return { next++, data.docos.at(next) };?
 
@Cheersandhth.-Alf Unusual and cruel treatment to the maintenance programmer is a serious problem!
 
Xeo
So, I opened Saya no Uta to play before going to sleep, and I only have it open in the background and I'm getting the creeps already from the BGM alone
 
11:26 PM
did that code change just now?
 
@R.MartinhoFernandes See, that's the shit I hate about reddit
 
i saw onluy one next use in the return statement
 
@Cheersandhth.-Alf It's been changed for some time now
 
@Chimera Hey, that's in r/circlejerk. It's a joke.
 
Xeo
@NikiC docos is prob a vector<pair<int,int>>
 
11:27 PM
well both updating and using in same full-expression is UB
 
Xeo
No, comma is sequenced
 
hm, yes it is. sry
 
@R.MartinhoFernandes Oh... :-)
 
@Xeo Ah, I see. I thought that @Drise wanted to return both index and data or something like that :)
 
Y WAS I STUPID
 
11:28 PM
@Chimera But I understand what you were talking about.
 
@Xeo Nice guess.
 
Xeo
Holy crap, this creepy BGM makes everything a thousand times worse.
 
I couldn't stand to let my roommate use this, so I wrote my own.
Critiques?
 
11:31 PM
@Drise Oh noes, it's arrowhead programming!
 
Xeo
@Drise Please burninate that code
 
@Drise he he, far too little indentation!
 
Xeo
@Drise Atleast std::move the string in the ctor to readFile
 
@NikiC member of type integer
 
Xeo
Or take reference-to-const
 
11:31 PM
@Drise m_i? :(
 
@Xeo Why? Also must be compilable with MSVC 2010
 
@Drise Yes, I got that. I just hate the notation :D
 
Xeo
@Drise VC10 has move semantics
 
@Drise Oh, gawd, so it's purely Hungarian metadata and no actual name?
 
@Xeo Does it?
 
11:32 PM
Yes.
 
Xeo
Also, you're copying the string needlessly if you don't
 
@R.MartinhoFernandes m_iWorldWidth = -1;
 
getNextLine(line, 127), yet line is declared as char[128] and line[127] is left uninitialized. Mmh...
 
Really, take a ref to const.
@LucDanton You're debugging the code that is to be replaced.
 
@R.MartinhoFernandes where?
 
11:34 PM
@Drise readFile and the ctor.
 
@LucDanton I'm just showing what I couldn't let my roommate use, so I wrote this new one, which seems to be like 3 times as short.
 
Xeo
@Drise everywhere!
infile >> line should be getline(infile, line) though
no wait, you want tags
 
@Drise Oh, I thought I clicked the link to the new version.
 
Xeo
Don't name your string line if you want tags!
 
Is that an XML parser?
 
11:35 PM
@Xeo Well, it's one tag/value per line
<DOCO_WORLD>
	<GRID_WIDTH>
		25
	</GRID_WIDTH>
	<GRID_HEIGHT>
		25
	</GRID_HEIGHT>
	<DOCOS>
		<DOCO>
			<XPOS>
				0
			</XPOS>
			<YPOS>
				0
			</YPOS>
		</DOCO>
 
Xeo
@R.MartinhoFernandes Some kind of restricted parser it seems, yeah
 
Some of the extraction operations are left unchecked.
 
Also provided by the professor
 
It will always return false.
 
Xeo
@Drise ew. Atleast use <XPOS value="0" /> for the single value stuff
 
11:36 PM
@Xeo Not my format
 
Oh wait, it will return true if the file doesn't close the initial tag.
 
@Xeo The entire file is like so.
 
In any case, I think the return is wrong.
 
Xeo
@Drise My condolences
 
@MooingDuck Best wishes! If you are both thinking of developing a new biological entity, please remember that it will have 10^11 adaptive-threshold logic gates and an unknown, massively-parallel OS. You have to write all the apps and maintain them for 15-18 years.
2
 
11:37 PM
@R.MartinhoFernandes How would I better indicate the file finished reading properly?
 
 
@MartinJames Did you come up with that on your own?
 
^ This is an interesting rep interaction due to the 'removed user' conundrum: if you lost more rep than you compensate for in accepts-only today, you won't be able to achieve >200 rep, even with the accepts.
 
@Drise If the loop exited by finding the last closing tag (i.e. infile && line == "</DOCO_WORLD>").
 
@R.MartinhoFernandes Hm.
Ok
 
Xeo
11:39 PM
@sehe bugshmug
 
@sehe Mwhaha, you were robbed!
 
It won't because I copy it first (into dump). The solution without pop-ing is the solution without a stack. If you need a random-access (general purpose) container, don't use the stack container adaptor. — sehe 45 secs ago
@R.MartinhoFernandes mildly
 
Otherwise, have I learned how to write a good c++ reader?
 
@Drise Yes.. the ultimate computer, for now..
 
And can you read into a std::pair like I did?
 
11:41 PM
Not all of us are born with Microsoft error codes wired into their brains. Could you please say what the actual errors are, and indicate their location in the code? — Kerrek SB 1 min ago
^ hehe
 
infile >> data.gridSize.first;
 
Xeo
Sure, why not
 
I dunno. Something I've never done/seen in code before.
 
Xeo
first and second are just another variable
 
11:41 PM
It was a gamble
so pair is like a template<class a, class b> struct pair{ a first; b second; /*some other bullshit here*/};
 
Xeo
yes
 
neat
 
Xeo
2
Q: Why is this code 100 times slower in debug?

PatI'm using MSVC 2010. I'm trying to remove duplicate (without keeping any of them) from a list Why is this code 100 times slower in debug mode? Is there any other way to remove all objects that are equivalent and make it faster in debug mode? It is to the point I can't use debug at the moment....

 
@sehe God! That is what our current college students are doing? They can't even google some fucking error codes and debug shit? Heaven help us.
 
Xeo
You know, it's called "debug" for a reason...
 
11:45 PM
I'm assuming a std::pair copy is trivial?
 
@Drise It's not.
 
It's a copy of each member.
 
Xeo
Man, this game is fucking scary.
 
Well, it's not specified to be.
 
@Xeo Amnesia?
 
11:46 PM
std::pair<int, int> FileReader::GetNextDoco()
 
Xeo
@R.MartinhoFernandes Saya no Uta
 
So how would I better return this?
 
pair(const pair&) = default; ooooh!
 
@R.MartinhoFernandes I couldn't play that game. Period.
@LucDanton uhhh
 
@Drise It's an improvement over C++03.
Not by much admittedly. Oh well.
 
11:48 PM
Remember, needs to be MSVC 2010 compliant
 
Xeo
@Drise "trivially copyable" has a different meaning from what you think, it seems
 
@Drise Wuss.
 
@Chimera I'm assuming you meant that in reply the the KerrekSB comment :)
@Xeo broken link (triple slash)
 
Xeo
@sehe Not for me
 
FileReader reader = FileReader("/home/drise/Desktop/DOCOData01.xml");
I know I'm doing something wrong/.
 
Xeo
11:50 PM
@Drise FileReader r(...);
 
Ok.
Right
 
@sehe Well yeah, I mean that question in general is pathetic. Really? That person couldn't google? Had the person done so the solution would be obvious?
I guess I just can't believe college level students can't seem to be able to debug code...
 
216 / 70 is...
Nearly 3 times as short
Professor version, my version
Does the exact same thing.
 
@R.MartinhoFernandes Hey, I took a close reading of the rules regarding uninitialized storage and pointers to such. As it turns out (and perhaps unsurprisingly), my optional and variant are broken.
 
11:55 PM
@Drise Oh yeah, I saw it before. Amazing that a professor would write such crap.
 
My debugger output
Which means it works
 
@LucDanton Why?
 
@Chimera You wouldn't even write that in C would you?
(since I know you're a C guy)
 
@Drise Um, no I'm sure it would be more readable and compact.
concise.
 
@R.MartinhoFernandes static_cast<T*>(static_cast<void*>(&storage)) is fine before a T object is placed in the storage (although it assumes that the lifetime of the previous object in the storage has ended), but once the storage is reused for a new object it's not so fine.
 
11:57 PM
Really, arrowhead code has no excuse.
 
@R.MartinhoFernandes What is arrowhead code?
@Drise Good job!
 
@Chimera You don't see the six levels of indentation in that?
@LucDanton Hmm.
 
So after storage_type storage; new (&storage) T; it's not cool to use storage, as in the name of the variable, not just the glvalue + lvalue-to-rvalue conversion and such.
 
@R.MartinhoFernandes Oh I thought that might have been what was meant, but I didn't want to assume.
 
I did have an insight while brushing my teeth though in that I think I can instead use this, can I not?
 
11:59 PM
I had never heard the term "arrowhead code"
 
FFS.
I was planning on writing a post on using raw storage for stuffs like optional, and now you tell me this.
 

« first day (712 days earlier)      last day (4237 days later) »