« first day (629 days earlier)      last day (4318 days later) » 

1:00 PM
Np. Found it here‌​.
 
@sbi Isn't it boring nowadays, just looking for the right API method :(
 
sbi
@ManofOneWay It's not only that. Every time you learn a new language, you feel like a babbling idiot, struggling to do the simplest things.
Oh please. Does this really have to be oneboxed here?
 
Thor akbar
 
sbi
@Cicada Which one of those is you? :)
 
22
Q: Why doesn't C# let you declare multiple variables using var?

DJTripleThreatGiven the following: // not a problem int i = 2, j = 3; so it surprises me that this: // compiler error: Implicitly-typed local variables cannot have multiple declarators var i = 2, j = 3; doesn't compile. Maybe there is something I don't understand about this (which is why I'm asking this)...

C# is even more restrictive
 
sbi
1:04 PM
@Cicada Well, so you have a goal to reach today.
 
I don't have twitter, not even a fake account.
@sbi I don't see why I would need one.
 
sbi
@Cicada To read the tweets in your timeline, of course!
 
Well I can already read them, right?
 
sbi
@Cicada Nope, you cannot read your timeline when you don't have a Twitter account, because a timeline is where you read the tweets of whom you follow, and you can only follow tweeters when you have an account... It's actually quite simple.
 
@FredOverflow C# is awesome. (No big news)
 
sbi
1:09 PM
> In C# I feel like Anders is holding my hand all the time, nudging me to go the ways he paved, preventing me to stray from the true path. — sbi
I like this tweet about the current god particle/atheist failure at Twitter.
 
1:28 PM
@sbi But I don't follow anyone in particular! I just stumble upon tweets randomly on the internets
@sbi The more I use C# the more I appreciate its clean and precise design.
 
0
Q: Are comparisons between iterator and const_iterator inefficient?

FredOverflowVariant a: const auto end = whatever.end(); for (auto it = whatever.begin(); it != end; ++it) { // ... } Variant b: const auto end = whatever.cend(); // note the call to cend insteand of end here for (auto it = whatever.begin(); it != end; ++it) { // ... } Is there any reason to bel...

 
@FredOverflow Good question
 
@FredOverflow seems to me like the unanswerable question. I'd suggest when compiling with optimizations, it might not make much of a difference. It will depend on your compiler and library implementation though
 
1:46 PM
@FredOverflow libstdc++ special cases it: gcc.gnu.org/onlinedocs/libstdc++/libstdc++-html-USERS-4.3/…
 
@Cicada I feel compelled to pay you a complement. Take it however you wish; I don't care. I just thought I'd say, if that is you in your gravatar, that you are very pretty.
 
I have an announcement to make.
 
...?
 
It's Friday!
 
meh.. we know
 
1:50 PM
Yeah, you guys are sharp.
@LucDanton Oh, what is that? I can't be wrong on the Internet!
 
uhm... maybe it's because of time zone, it's almost 18 hours as it's Friday here
 
@Abyx I just started Friday. Nearly 9am.
 
sbi
@Cicada I perfectly understood that limitation of yours. That's exactly why I suggested you take this to a new level. :)
 
Oh, god.
@LucDanton I shall curl up and die in shame now.
 
@RMartinhoFernandes Party tonight?
 
1:55 PM
@ManofOneWay Why?
 
@RMartinhoFernandes Because it's Friday!
 
sbi
2 mins ago, by R. Martinho Fernandes
@LucDanton I shall curl up and die in shame now.
@Cicada Oh, C# is a very neat and clean little language, and I like it for that. But.
Compared to C++, C# comes across like a sweet and innocent little girl facing a battle-hardened soldier. If things get rough, I know who I'd rather have at my side, no matter how hard to deal with at times.
 
@RMartinhoFernandes C++ party then?
 
@sbi So you prefer battle-hardened soldiers to innocent little girls? :)
 
sbi
1:59 PM
@Cicada "If things get rough..."
 
sheepish grin
Yes, "to get rough" has multiple meanings
 
No cowish breasts?
 
@RMartinhoFernandes Not today.
 
I am alive.
 
> Nature is overrated and wears out too soon.
 
sbi
2:01 PM
@Cicada I am not into BDSM, if that was what you didn't dare to ask.
@EtiennedeMartel Shit happens.
 
Life happens too. Therefore life = shit.
 
sbi
@CatPlusPlus You happen to be here, too. Therefore Cat is here == shit.
 
I never happen, I always am.
 
sbi
@RMartinhoFernandes I liked the one before yesterday better.
 
@LucDanton Fixed. Thank you.
 
sbi
2:03 PM
@CatPlusPlus Read again. I wrote, you happen to be, and cat is here.
 
@sbi "The Agincourt Gambit" is genius!
 
sbi
@RMartinhoFernandes As so often with XKCD, I seem to fail to catch the reference.
 
It's a reference to the battle of Agincourt.
 
meh
decisions decisions, meh
 
Englishmen armed with longbows beating the shit out of the French knights.
 
2:05 PM
@sbi Definitely.
 
it was too difficult to move around in whole body armour, especially in moors (is that the word?). so frenchmen lost. iirc.
 
sbi
@RMartinhoFernandes Yeah, I have just looked it up.
However, jokes explained are jokes not laughed about.
 
Your loss :P
 
ah, "marshes"
 
Where's ze puppy?
 
2:16 PM
Probably playing with the puppy's puppy.
 
@sbi unless the joke is designed to be explained with a second-level joke :-)
 
2
Q: Do invocations of std constructors need to be qualified?

FredOverflowDo invocations of std constructors need to be qualified with std::? class whatever : public std::runtime_error { public: explicit whatever(const std::string& what) : runtime_error(what) {} }; // ^ do I need std:: here? It works on my compiler ...

 
argh, i'm so frustrated. helping a festival here with adding content to their web pages. and now the designer (self-educated) has been in there messing up the design. i will probably get the blame, because it will be there until next i get to talk to people, on tuesday.
 
life sucks, get over it
 
Isn't getting over life dying?
If so, that's really bad advice.
 
2:20 PM
donno, never thought of the philosophical implications of that statement
 
sbi
@RMartinhoFernandes Thought exactly the same.
 
and I take no responsibility for how you interpret it
@RMartinhoFernandes it's getting over the fact that life sucks, not life itself
 
sbi
@TonyTheLion No need for you to take that responsibility. We just throw it onto you the moment Alf is dead.
 
@sbi oh god, why did I come here?
 
Tomorrow in the news: "Advice lion kills dude"
 
2:22 PM
lol
 
sbi
@TonyTheLion I dunno. To drive people into suicide?
 
Afternoon, people. I see, fascinating discussions here, as always. :Đ
 
no
@sbi thanks for brightening up my day sarcasm
an already shitty day was just made shittier
 
sbi
@TonyTheLion If he finds it fascinating, who are you to say "no"?
 
@sbi He's the guy trying to drive people to suicide.
 
2:23 PM
you troll
 
sbi
@TonyTheLion And if you come here by night, I can also brighten up your night sarcasm.
 
sbi
@TonyTheLion High time you realized that.
:b
 
how do you always manage to troll me so easily, and how do I with my stupid fucking head always fall for it??
I mean, honestly, I must be stupid!
6
I await the stars!
 
And stars you get!
 
sbi
2:24 PM
@TonyTheLion It's getting night, the stars are already twinkling.
 
wasn't hard to predict
fuck stars
 
@TonyTheLion Yeah, like the Higgs boson, comes right off the Lounge mechanism. :Đ
 
fucking god particle can suck my dick
 
goddamn particle* :P
 
2:26 PM
Leon Lederman gave in to his publisher. :Đ
 
@TonyTheLion Now, now, there, don't say that, I'm sure you have lots of other qualities.
 
@EtiennedeMartel yea, like bashing Java or PHP!
 
@DomagojPandža Too late. It's the god particle now. There's no going back.
 
sbi
@TonyTheLion Uh, googling images for "fuck stars" is NSFW. Who'd have thought?
 
The djinn is out of the bottle, and those bastards don't like going back in.
@sbi It seems quite obvious to me.
 
2:27 PM
@sbi well, yea, stars probably means "porn stars" to google when the word Fuck is in front of it
 
sbi
Oh, I am glad you explained it to me. I'd never...
 
@RMartinhoFernandes :( Bah, my mother said: "See, even your science people agree god exists". I wanted to harm her.
 
and anyone long on the internet should know that, it's rule 34
 
And then harm everyone in the media.
 
@DomagojPandža In the future I will be in the past and consider fixing that mistake.
 
2:28 PM
but really, this "God Particle", seems a load of codswallop to me
 
Dude. There's "God" in it. What more proof do you need?
 
just because some scientist says it exists, does not mean the world has to bow
 
@TonyTheLion Don't worry, it's mostly harmless.
 
sbi
Meh. Googling for "rule 34" isn't exactly SFW either.
 
@EtiennedeMartel that God exists
@sbi aren't you at work?
 
2:29 PM
@sbi No shit, Sherlock.
 
sbi
@TonyTheLion Yes, I am.
 
The "god particle" is a load of bullshit. Higgs boson and the higgs field, awesome. I would've loved if the Standard model had crashed, in order for new physics to emerge, but its pending confirmation is also nice.
 
@TonyTheLion Eh. Science is not a religion.
 
@sbi NSFW means Not Safe For Work
@EtiennedeMartel never said it was
 
sbi
@TonyTheLion Yeah, I know. I have been using it in the correct context before, remember?
 
2:30 PM
Well, with your age and all, it's hard to know. You might have forgotten.
 
@sbi yea well, who the heck Google's "rule 34" at work?
 
@EtiennedeMartel Ow.
That was mean.
@TonyTheLion There's a book by that name.
 
I'm sure he can handle it.
 
sbi
@TonyTheLion See here.
 
@EtiennedeMartel dafuq does my age have to do with differentiating between Science and Religion?
 
2:31 PM
@TonyTheLion That was directed at @sbi.
 
sbi
ROTFL!
 
They let you roll on the floor at work?
 
sbi
@EtiennedeMartel That's what you get for not properly referencing in your replies: an angry lion!
 
@EtiennedeMartel meh, was ambiguous
 
Don't touch physics and we're okay. I don't care if you like to suck Satan's dick, but don't touch physics.
 
sbi
2:32 PM
@RMartinhoFernandes Of the two guys I share the room with, one is on vacation and the other is sick.
 
OH HAI !
 
@DomagojPandža not sure if sucking Satan's dick is a good move either :P
 
Besides, any argument directed at physics in a negative manner is rendered void by the fact it was sent off a computer.
 
@sbi An angsty lion.
 
2:32 PM
lol
so the guys I interviewed with in Oxford don't want me, they probably read the transcript for this chat :(
 
Saying that physics are bullshit on a computer is like using a manifestation of Jesus to tell people God doesn't exist.
 
since I gave them my SO profile to look at
 
@DomagojPandža Some physics are bullshit.
 
@RMartinhoFernandes String theory is bullshit because it is bad as religion. As Pauli used to say, it's not even wrong.
 
they said they liked me, but I lack experience
 
But I don't consider that physics, that's just wanking around.
 
but how do I get experience, if they don't give me a job
 
That list is hilarious.
 
Wank wank.
 
@TonyTheLion "It's not you, it's us."
 
Hi all.
 
2:37 PM
@Foxinsocks You broke the combo :(
 
Sorry
 
How to catch errors in c?
 
I'm starting an insurance company, and I'll offer illegal savings to my clients.
 
2:37 PM
@Foxinsocks C is an error.
 
@Foxinsocks Why ask about C in a C++ room that's notorious for being hostile to C?
 
meh C
 
angry lion
 
sbi
@Foxinsocks You don't.
 
2:40 PM
@ecatmur Hmm, drive by linking, now?
 
@EtiennedeMartel He's not new here.
 
@RMartinhoFernandes I'm not?
 
@sbi I know. I want to know how to prevent entering long string.
 
You're doubting my memory? Blasphemy.
 
thought it'd be a distraction from ragging on C developers, anyway
 
2:41 PM
His new was years ago, he's probably waiting for delete.
 
GM everyone :)
 
General Motors?
 
sbi
@Foxinsocks That's OS-specific. When your program gets its hands on the string, the OS has typically already accepted it. All you can do is to bite bigger or smaller chunks out of it. If you don't want that, you need to employ OS-specific methods.
 
Game Master Everyone, can I meet him? :P
 
2:42 PM
@StackedCrooked Good Morning* :)
 
@RMartinhoFernandes that's just one week!
 
You were allocated in June, so Robot wins.
 
@ecatmur But it's from last month!
 
sbi
@ecatmur Well, since you seem to beg for it...
 
2:43 PM
@RMartinhoFernandes I know, but he's not exactly a regular, hmm?
 
sbi
1 message moved to bin
 
@sbi hmm, thanks.
 
Anyway, you've been chatting around for a week now. I personally wouldn't call that drive-by linking.
 
sbi
Happy now?
 
@sbi yup, thanks :)
 
2:44 PM
sbi moving drive-bys to the bin like a baus.
 
If it is drive-by linking, he's been driving-by very very slowly.
3
 
sbi
@Foxinsocks However, I very much suppose that you did not ask the question you wanted to ask. So you might want to lean back for a moment, think about what you actually want to do, and ask that question.
 
@RMartinhoFernandes Crawl-by linking.
3
 
@EtiennedeMartel One planck length per second, baby.
 
That's not really crawling.
That's more like... standing still.
Basically, if a starving snail on dry pavement is faster than you, you're not crawling.
 
2:47 PM
Hi guys
 
I've always wondered how does a snail go on dry sharp wood.
 
sbi
Well, I have another Powershell question. What is better to work with in PS, a space-separated string, or XML? Background: SVN can emit properties as plain text or as XML. I need to get at those substrings. In plain text they are space-separated, in XML they are their own node.
 
@sbi I'm trying to write simple console app. Which waits from user some string data. And data should be short(about 5 symbols). hastebin.com/wejihupota.vala
 
@RMartinhoFernandes I think I'm beginning to appreciate the accuracy of the planck constant
 
@sbi If a couple string.Splits can do the job, I'd use that.
 
2:49 PM
I want a turtle.
 
sbi
@Foxinsocks In a simple console app you cannot prevent users from entering longer strings. O suppose that you can, however, limit the number of characters you accept. Likely that's some funky format string for scanf(), but I wouldn't know that much C.
 
But if there are escaping issues involved (like, can property names have spaces in them? I don't remember), the XML APIs are probably less of a hassle.
 
sbi
@RMartinhoFernandes Thanks. How do I employ that?
@RMartinhoFernandes They can, essentially, be binary, although that's unlikely for svn:external. Paths can contain spaces, though.
 
@sbi $the_string.Split(" ", 2) splits it in at most two parts.
 
sbi
@RMartinhoFernandes Ah, that's .NET string handling then, isn't it?
 
2:52 PM
Yes.
 
sbi
Ok.
 
@sbi so ok. Thank you very much.
 
sbi
But with spaces, you think XML would be better, @RMartinho?
 
Hmm, can you use LINQ to XML in PS?
 
I don't know how the System.Xml.Linq APIs look in PowerShell (i.e., I don't know how extension methods work there), but they're really neat in C#.
 
sbi
2:55 PM
According to O'Reilly's PS pocket ref, accessing nodes in XML seems to be very simple.
 
@sbi It's easier to get a guarantee that you won't run into escaping corner cases.
(Modulo generator or parser bugs)
@EtiennedeMartel Oh, there's builtin XML handling, which seems even easier.
 
sbi
@RMartinhoFernandes The generator is SVN, and the parser consists of $xml_var.node.subnode.subsubnode.
 
So, go for it :)
 
Don't forget that XML is like violence.
 
sbi
3:03 PM
Uh oh. I only now have closely looked at what that XML stuff actually contains. The smallest granularity is what the plain-text option gives me, too. They just wrapped it in some talkative XML: :-/
Well, back to plain-text then...
 
@sbi ERm. Wow. Way to go SVN.
<lines>
    <line>This is a line.</line>
    <line>This is another line.</line>
    <line>I can turn anything into worthless XML</line>
    <line>Isn't that awesome?</line>
</lines>
 
sbi
It's worse, though.
<?xml version="1.0" encoding="UTF-8"?>
<properties>
  <target path="C:/dev/blahblah/SVN/...">
    <property name="svn:externals">
      svn.blahblah.com/svn/blubbblubb1/trunk foo
      svn.blahblah.com/svn/blubbblubb2/trunk bar
    </property>
  </target>
</properties>
Whereas this is what I get as plain text:
 
Heh. Yeah, definitely go with plain text.
 
What a bunch of tools.
 
sbi
Ok. So I have that list of lines, each consisting of a path and a name. How do I split the list into lines? And how do I split each line at the last space?
 
3:08 PM
The True Problem with PHP seems quite similar to the true problem with C++.
@sbi I think splitting by lines comes for free with piping.
 
sbi
@RMartinhoFernandes Ah, yeah. That peculiarity with PS.
 
@RMartinhoFernandes Part of the problem there is that there hasn't been a good, authoritative tutorial repository for PHP. Yep, that's kind of a problem with C++ as well.
 
I like cppreference, but that not really a tutorial.
 
sbi
Oh look, it's emitting spaces as %20. Well, one thing less to worry about.
 
@sbi In paths? Oh right, SVN uses URLs everywhere so it makes sense to URL-escape spaces.
@EtiennedeMartel Do we need a cfoolsfools.com?
 
I've edited your question for you. Also, voted to move to Super User. Welcome to Stack Overflowsehe 9 secs ago
 
sbi
@sehe It seems Bruce brought the server down. The link times out for me.
 
@StackedCrooked yeah, but the examples are really good
 
sbi
@StackedCrooked It's actually worse for C++. 75% of all books you can buy for C++ are crap, and probably 99% of all online tutorial are, too.
 
3:15 PM
@sbi Here too. Good thing I linked to Bruce's blog
 
@StackedCrooked I like it primarily because I can fix it.
 
@sbi I can't get to it either. Here's Google's cached version
 
@EtiennedeMartel although most (all?) said there is literally correct, it's nit-picking of the worst sort, and i think from an adversarial source. many of the criticisms seem like quotes taken out of context, in particular when statements that apply to HTML 4.x and earlier are compared to HTML 5. which no browser yet supports fully (and perhaps never will).
 
sbi
@Prætorian Haha! "We tried to call Barclays’ security expert R0b Ste!nway for a comment, but he was not available for 24 hours, having answered his phone incorrectly three times in succession."
 
3:19 PM
@CheersandhthAlf Well, they want to prove that W3Schools contains incorrect or misleading information.
 
sbi
@Cicada Great! Is that real, or is it 'shopped?
 
Anyway, W3Schools is crap. Ugly, outdated crap.
 
i think i agree, at least if it's true that their pages are table-in-table designs!
 
The bestest CAPTCHA ever.
 
3:21 PM
Recommending W3Schools to a Web dev is like recommending cplusplus.com to a C++ dev.
It's not as bad as getting stabbed in the face, but still.
 
or œsnmt?
 
@CheersandhthAlf Supposedly, there are two words in there. (Hint: look to the right)
I solved it with "oesnmt something".
 
sbi
@RMartinhoFernandes I fail to see what's noticeable about it. (That it is unreadable is not noticeable.)
 
@sbi The right half is a supposed to be a word.
 
@sbi The image on the right.
ReCAPTCHA works by presenting two words.
 
sbi
3:22 PM
@RMartinhoFernandes Well, you should have explained that.
 
it's a picture of something?
 
sbi
@EtiennedeMartel Yeah, whereas this only presents one word.
 
@sbi And a picture.
That's a fail in my book.
 
It's a test to see if you are a robot
Obviously, they are hoping the robot explodes
 
Guess what, they failed terribly, because I solved it.
 
3:24 PM
@RMartinhoFernandes Well, the "known" word must have been that one on the left.
 
Yeah.
Does VS support explicit conversion operators?
 
i think so
should i check
 
0
Q: explicit operator bool error

NickI have the Compiler Error C2071 when I try to implement the explicit operator bool: class C { public: explicit operator bool() const { return !!*this; } }; Why? How can I solve this problem? I'm using Visual Studio 2012 RC.

@CheersandhthAlf It's for this question.
 
as of msvc 11.0 (beta), nope, sorry
 
Yeah, I thought so.
 
3:27 PM
@RMartinhoFernandes if it's returning bool, why would you need !!?
/nitpick
 
@ecatmur Dunno.
I suspect it's because it already has overloaded operator!.
Otherwise it will just overflow the stack.
 
the answer to any such question is to use a named conversion
explicit
but not explicit
explicit is good
implicit is bad
 
even when the implicit is explicit
 
oh yeah, nvm, got myself confused there
 
3:31 PM
Hello.
 
I fear someone might reply to me in the near future saying this can be null. I'm promising I won't even bother replying.
And there we go...
 
if (this > 0)
 
@R.MartinhoFernandes At least makes more sense than *this. Perhaps he's planning calling it for NULLs... — Agent_L 28 secs ago
 
@RMartinhoFernandes huh, re what?
 
I'm precognitive!
 
3:33 PM
@CatPlusPlus eeh, like nails on a blackboard
 
if ((int)this > 0)
 
You're making it worse! Stop!
 
not-pointers-into-the-same-array! not-pointers-into-the-same-array!
 
@ecatmur He made it an int now. No pointers harmed.
But assert((int)(void*)nullptr == 0) failorz in Hell++.
 
if ((int)reinterpret_cast<char*>(this) > 0)
 
3:35 PM
Failorz in Hell++.
 
Actually, in pre-ARM C++ setting this to 0 was the way to indicate failed initialization.
 
Modulo bugs, Hell++ is 100% compliant. It's the most compliant implementation available. Pity it's not actually available.
@CheersandhthAlf Was that before exceptions?
 
sbi
3:56 PM
Uh, another PS question: Now that I have a string "A B", how do I get $A to be "A" and $B to be "B"? Or, what I rather want to know: I need to turn "A B" into "A B'", where "B'" needs to be computed from "B". So I need to get at "B", manipulate that, and then need to replace ``"B"` by the manipulated value.
 
Xeo
@Xeo you're certainly wiser than I am. Please, teach me about compilers that are unable to cope with 0 in ECX. Or on the stack. — Agent_L 7 mins ago
sigh
 
loud sigh indeed
 
@Xeo Don't bother.
 
Xeo
Too late.
 

« first day (629 days earlier)      last day (4318 days later) »