« first day (740 days earlier)      last day (4206 days later) » 

user142019
12:00 AM
It was a joke. :P
 
Oct 6 '11 at 9:00, by Luc Danton
Standards are srs bsns.
 
user142019
Serious business is a joke.
 
If you agree with me that int succ(boost::any i) { return boost::any_cast<int>(i) + 1; } is a sillier version of int succ(int i) { return i + 1; }, would you agree void foo(std::function<void()> f); is a sillier version of template<typename F> void foo(F f);?
 
wait: stackoverflow.com/questions/13059337/c-char-array-concatenation. The question marked as the answer doesn't actually answer the question.
 
user142019
MyString *result = new MyString("");
 
user142019
12:05 AM
What a fool.
 
@LucDanton void foo(std::function<void()> f); prevents foo("APPLE") from compiling, second doesn't (though presumably the body would find an unreadable error)
 
user142019
And operator+ does return by value.
 
@MooingDuck As you point out yourself, the two result in error.
 
user142019
And operator+ should be implemented in terms of operator+=.
 
@LucDanton one provides "overload not found" and the other is a unreadable template error as it attempts to instantiate.
 
12:07 AM
@MooingDuck "Overload not found" is an extension. There is no requirement on what the error should look like. In a naive implementation, it will point to something deep within the bowels of std::function.
 
user142019
@MooingDuck If you call a function with a string parameter while that function doesn’t expect a string parameter, one or more of the following statements are true:
 
user142019
1) You’re a moron.
2) You didn’t read the manual, in which case you’re a moron.
 
Because the constructor for std::function<Sig> is, in fact, described as template<typename F> function(F f);...
 
user142019
So use templates, not std::function, for parameters.
 
user142019
Common sense and documentation > stupid restrictive interfaces.
 
12:09 AM
@LucDanton fair enough then
 
user142019
Duck typing all the way.
 
@WTP'-- I actually intend to address the point of self-documenting code.
 
user142019
Who said I didn’t?
 
user142019
Self-docementing code is also documentation.
 
Right, but template<typename F> void foo(F f); is not self-documenting.
void foo(std::function<void()> f); arguably is, so I must in all fairness address that.
 
user142019
12:11 AM
@LucDanton It is.
 
user142019
F and f mean function by convention.
 
Yeah, but what kind? How many parameters? Of which type? What return type?
 
user142019
The function name foo should make that clear enough, and otherwise —> comment or other documentation.
 
SFINAE?
 
user142019
static_assert? :P
 
12:13 AM
tl;dr template<typename F, Requires<is_callable<F, void()>>...> void foo(F f);
 
user142019
You know, I always use static_assert as poor-man’s concepts.
 
Requires can be substituted with EnableIf if you so desire. Different semantics though.
@WTP'-- Not self-documenting when definition is separated from declaration.
 
user142019
@LucDanton lol
 
user142019
You get a decent compile error when you use the function.
 
user142019
Anyway, I’m apathetic and my user stories are getting funny.
 
12:14 AM
Yeah that's documenting the errors, not the signature. Because it's not in the signature.
Meanwhile, void foo(std::function<void()> f); is a signature.
 
user142019
static_assert(is_callable<F, void()>::value, "The correct signature of the function is void().");
 
user142019
Also. What’s wrong with std::function parameters? Compilers can optimize out the std::function if they want.
 
Mmmh, why did I name my trait is_callable when I intend to distinguish Callable from Invokable. Not smart.
@WTP'-- WIP.
@WTP'-- lol! show me one instance of such an optimization.
 
user142019
I don’t say they do.
 
user142019
But they could inline everything and replace the std::function with whatever type is passed.
 
12:18 AM
Then that's not an argument, because compilers could optimize anything. Not relevant to std::function.
 
user142019
Also
 
user142019
If passing a callback is your bottleneck, you’re doing it wrong.
 
user142019
Scrum is so funny.
 
FTR you're the one that mentioned performance. I purposefully avoided the microbenchmark to avoid that kind of argument.
 
user142019
If it’s not about performance, I can’t think of any other issues.
 
user142019
12:20 AM
Non-copyable functors, perhaps? Nah.
 
As I've said, WIP. Can't talk about it and write it at the same time!
@WTP'-- Yes. But I won't mention it.
 
user142019
Only problem I’ve ever encountered was that templates work with blocks, std::function doesn’t. And that’s the reason I always use templates instead of std::function.
 
Xeo
22
A: Isn't the template argument (the signature) of std::function part of its type?

XeoThe problem is that both function<int()> and function<int(int)> are constructible from the same function. This is what the constructor declaration of std::function looks like in VS2010: template<class _Fx> function(_Fx _Func, typename _Not_integral<!_Is_integral<_Fx>::...

I think I'll just dump this here /cc @MooingDuck
What were you discussing anyways? Not taking std::function as a parameter?
 
user142019
@Xeo Yes.
 
Xeo
I'm with that opinion too.
 
user142019
12:24 AM
Me too. I never care about interfaces.
 
@Xeo I'm half-writing that essay and half talking about it. Good way to make sure I'm making a good case.
 
@melak47 I don't use CDT.
 
user142019
I’d love to make everything public, too, but that’s unconventional.
 
Xeo
It also makes those damned "why doesn't the compiler deduce function<R(T)> from my lambda argument?!" a non-issue
 
So no idea
 
12:24 AM
@CatPlusPlus well, I guess notepad it is then :)
 
user142019
Use Sublime Text 2 and a terminal. Who needs an IDE.
 
I didn't mean literally notepad.exe
 
Xeo
@WTP'-- Use just Sublime Text 2, you can make a buildscript in there. :P
 
@melak47 Did you set C:\MinGW\bin to your Path?
 
user142019
@melak47 yeah.
 
user142019
12:26 AM
Use pen, paper and OCR.
 
@Rapptz yeah. as I said, it has no trouble detecting mingw32, sets up all the include paths itself, and who knows what other options. I tried to set the include paths for mingw64 myself, but still didn't help.
 
user142019
@TheForestAndtheTrees do you live in the forest?
 
user142019
inb4 hi
 
@WTP'-- ...hi?
 
Well, you could use Sublime Text and compile via command line.
 
user142019
12:28 AM
I use TextMate and Z shell and I call that my Unintegrated Development Environment.
 
0
A: g++ Fatal Error when using Sublime Text 2 to Build C++ Code

RapptzWhat's your .sublime-build file like? I use this one and it works just fine. { "cmd": ["g++", "-Wall","-time","-g", "-std=c++11", "${file}", "-o", "${file_path}/${file_base_name}"], "file_regex": "^(..[^:]*):([0-9]+):?([0-9]+)?:? (.*)$", "working_dir": "${file_path}", "selector"...

I use that as my build config.
 
I don't need to build with sublime. I don't even really want to
 
Ah. Well, the option is always there.
 
already building with scons
making sublime run scons seems silly when I don't even use sublime :p
 
user142019
Here, my IDE:
 
user142019
12:30 AM
 
user142019
NEEDS MOAR JPEG.
 
user142019
Who needs Scons when you have Cabal.
 
I didn't pick scons :p
 
user142019
Make Cabal invoke Scons! xD
 
i found the problem with Windows move command: it doesn't like to move something across a symlink.
 
12:36 AM
@WTP'-- Is that Sublime Text?
 
user142019
@Borgleader No.
 
user142019
It’s TextMate.
 
user142019
As you can tell from the icon. :P
 
I don't have a mac, don't use textmate so no I can't tell
 
user142019
But I can invoke Cabal from TextMate if I want.
 
user142019
12:44 AM
I’ve never tried Sublime Text on OS X.
 
user142019
It rocks on Windows though.
 
user142019
I’ll try it right now.
 
user142019
Aarrrggg my eyes.
 
user142019
Why is that icon so fugly.
 
user142019
Wow. Sublime Text 2 is really ugly in OS X.
 
user142019
12:48 AM
Looks like it renders the text itself or something.
 
user142019
Really terrible.
 
Eh? I just googled screenshots of it. It looks exactly the same.
 
user142019
Wat.
 
user142019
I quit Sublime Text, first kernel panic ever.
 
user142019
So, help me pick a disease I’ll wish the Sublime Text developers:
 
user142019
12:57 AM
Dutch profanity can be divided into several categories. Often, the words used in profanity are based around various names for diseases. In many cases, these words have evolved into slang, and many euphemisms for diseases are in common use. Additionally, a substantial number of curse words in the Dutch language are references to sexual acts, genitalia, or bodily functions. Religious curse words also make up a considerable part of the Dutch profanity vocabulary. Aside from these categories, the Dutch language has many words that are only used to describe animals; these words are insulting w...
 
user142019
@Rapptz The text rendering is different from that of other applications.
 
user142019
And it ain’t be particularly pleasing to me eye.
 
user142019
Well, it looked better than Eclipse, but that doesn’t say much.
 
someone should invent a perfect text editor
 
user142019
@Cheersandhth.-Alf Allan Odgaard already did. And Richard Stallman.
 
1:01 AM
but it's payware?
 
user142019
TextMate is open-source.
 
TextMate is perfect? Lol
The perfect text editor requires a link to your brain
along with it being AI complete
 
user142019
@Pubby Emacs?
 
And coding without typing.
 
user142019
@Pubby Emacs?
 
user142019
1:02 AM
EMACS DOES ALL THE THINGS :D
 
Emacs gives you RSI
And emacs lisp looks like a shitty version of scheme
 
user142019
I always use TextMate and it’s the best editor I’ve ever used.
 
That's not saying much.
 
user142019
Except for C#, for which I use MonoDevelop for the sole reason of C# requiring too much boilerplate.
 
I'm going to say the best editor I've seen is Vim except it still is a shitty editor
 
user142019
1:04 AM
I use TextMate for everything.
 
user142019
I have export EDITOR='mate -w' in my .zshrc.
 
user142019
Because OS X defaults to vi, which is a hardlink to vim. xD
 
user142019
But I still need to pick a language in which I’ll write my pawn site in.
 
user142019
I could do it in Python, Ruby, C, C++, Haskell or PHP, but they all suck for web development since web development sucks.
 
1:21 AM
u might use google apps with python 2.7
 
user142019
Google Apps for a pawn site? Don’t think they’ll appreciate it.
 
oh don't do such silly stuff
if you want to hack people, just set up an ftp server, make people click on links, collect their IP addresses
 
user142019
Why do I want to hack people?
 
user142019
I just want to kill my spare time.
 
why not spare your kill time?
 
user142019
1:24 AM
PSY is so funny.
 
user142019
 
@WTP'-- Do we know for sure that is Psy?
 
user142019
@Borgleader Yes. He verified via Twitter.
 
user142019
join me for reddit q&a. starts in 5 minutes!! http://www.reddit.com/r/IAmA/comments/120oqd/i_am_south_korean_singer_rapper_composer_dancer/ http://t.co/Go8J3cGQ
 
1:28 AM
i think i dislike that gang---whatever style video
 
gangnam
 
user142019
Gangnam Style FTW
 
he he
what is it, really
 
user142019
The video is funny and the music is good enough not to be terrible.
 
user142019
inb4 onebox
 
user142019
1:29 AM
 
531 000 000 views, you gotta hand it to him
in about 100 days
 
user142019
Still not as much views as the number of active Facebook users, so it’s nothing.
 
user142019
Oh in 100 days. :P
 
>Active facebook users
That 900 million number is number of accounts.
Including dummy accounts.
 
user142019
No.
 
1:30 AM
Yes.
 
user142019
Number of accounts that sign in at least once per month.
 
His video has more likes than most videos have views
xD
 
user142019
> The world's biggest social network says it now has over a billion active monthly users.
 
584 million average per day.
Once per month is a retarded thing to go by.
That includes accounts that are made just for that month.
 
user142019
1:33 AM
Facebook sucks. It’s full of morons.
 
NO U
 
user142019
It’s like 9GAG. People post things that are completely not funny and reposted a thousand times.
 
@WTP'-- I wonder how many people in the world even have access to computers?
 
user142019
@Mysticial way too many.
 
The people who hate on 9gag are no better than the 9gaggers
 
1:34 AM
@WTP'-- I bet we'll all be surprised how many don't. Especially if you include rural areas of Asia and Africa.
 
Well there are what 8 billion of us?
Id say half of them dont have access
 
@Borgleader Yeah
 
user142019
@Mysticial “number of internet users” won’t differ very much from “number of computer users”, so let’s say ~2 billion.
 
I'm willing to guess that at least half don't have access to computers.
 
1:37 AM
@Borgleader You added a billion.
We're at ~6.9b not 8b.
 
Not that it matters much.
 
user142019
I wanna advertise on the moon so I’ll have ~7 billion viewers —> instacash.
 
It'll get to 8 billion in not too long.
 
user142019
I’d ask like a million dollars per hour at minimum.
 
@Mysticial If we keep going at 1.01% growth, we'll reach it by around 2023
 
1:39 AM
Unless war happens
 
Though I actually don't know what the growth is, I just estimated it to be around 1%
 
user142019
I don’t care how many people there are; as long as I can eat and live decently till I die it’s fine for me.
 
user142019
Man.
 
This article includes three lists of countries and self-governing dependent territories by population growth rate. The first list is based on the estimates taken from the 2006 edition of the United Nations World Population Prospects report. Figures are population growth rate estimates for the period 2005–2010 using the medium variant. The second list is based on CIA World Factbook estimates for year 2011. Dependent territories and not fully recognized states are not ranked. The third list is based on World Bank estimates for year 2009. Population is based on the de facto definit...
Damn... most of those are in Africa.
 
user142019
You all must be so unlucky for being alive at the same moment as a troll like me.
 
1:41 AM
What makes you such a special troll?
 
why not ask the mathematica site
 
@Mysticial Of course. They tend to reproduce more due to the higher infant mortality rate.
 
user142019
@Mysticial Of course, they don’t use condoms.
 
And they need people to help around.
@Cheersandhth.-Alf What for? Basic math?
 
Sooo. I have tried my hand at an unorthodox Spirit approach here: stackoverflow.com/questions/13056893/…
 
user142019
1:42 AM
@Rapptz And that mentality they take with them when they come to the Netherlands, so they breed like rabbits here. >.>
 
Why do I find Spirit so appealing. I must be slightly mad
 
It's hard not to upvote when it's as long as a novel.
 
user142019
@sehe Spirit slows down Xcode’s syntax highlighting and code completion. :P
 
It didn't answer what I asked, but interesting still
 
user142019
1:43 AM
Because Xcode uses libclang for those.
 
@Cheersandhth.-Alf That doesn't say when.
 
user142019
And it has to do a million template instantiations every time you enter a character in order to do the syntax highlighting.
 
@Mysticial The 'benefits list' ended up being impressive even in my own view. I just took the OP's code and made it slightly less wonky. In the end I thought I'd try to list the notable changes... Apparently those were quite a few.
 
Wait... wth? China has net population growth even through that 1-child policy thingy?
 
@Mysticial It's like an infinite series.
 
user142019
1:44 AM
@Mysticial Imagine China without the 1-child policy.
 
People still have more than 1 kid.
They just get put up for adoption.
 
@sehe I surprise myself at how easily I can navigate bind expressions these days. I suppose those are the hallmarks of EDSLs with a good expressive power.
 
@WTP'-- Well, ditch XCode. I specifically exclude headers from completion because I don't have any need for intellisense on generic C++ libraries like that.
 
user142019
Not that I like the 1-child policy, but it’s about the only possible way to keep people from dying of hunger.
 
There isn't really a food shortage. It's more like an efficiency problem, really.
Food is easy to mass produce.
 
1:45 AM
@Mysticial That policy is not country-wide. I hear it's mostly a urban thing, would be impractical to enforce in rural areas and not that useful either.
 
@LucDanton Do you mean strictly {boost,phoenix,lambda,std,str::tr1}::bind or any kind of lazy actors in general?
 
Also it's not just 'you can only have one child, ever'. There are provisions.
@sehe Nested bind expressions specifically, they're the same everywhere.
 
user142019
@sehe Xcode sucks anyway.
 
user142019
TextMate ftw.
 
user142019
Also, @sehe, don’t you have to work tomorrow? It’s almost 4 AM.
 
1:47 AM
@LucDanton You said that the other day, when I turned out to be able to use the Phoenix one substantially more elegantly than any other, right?
 
user142019
I know that sleeping is a waste of time, but still…
 
@WTP'-- You're right. I have work tomorrow
 
user142019
How long do you sleep?
 
user142019
Half an hour?
 
user142019
Aren’t you like a zombie at work? XD
 
1:47 AM
@WTP'-- That's a start. Well, 4-6 hours I wager
 
I sleep for two hours usually. 4 on a good day.
 
user142019
I sleep 8 to 12 hours a day.
 
@Rapptz That would be pathological, in my view
@WTP'-- I can too.
 
@sehe Ya. Some go an extra mile to provide protect and related, but those turn a bind expression into a dumb functor, so it's not too hard to reason about them. (One of those turn into a dumb functor but only across one level or some such so admittedly I wouldn't know what to make of it.)
 
I can sleep for 16 and be sleepy next day.
 
user142019
1:48 AM
So today I’ll wake up at like, 15:00.
 
@WTP'-- Same here. I don't like it either. But I can't think of a better way.
Not only hunger, but it wrecks havoc socially as well.
And on families.
 
user142019
@Mysticial China could buy Russia and send all people there, but that’s rather impractical.
 
@sehe Well, I have a very strong love-hate relationship with sleep.
 
@LucDanton I think I'll probably not try to get proficient with advanced bind expressions unless I'm forced to use c++03/tr1 on a job. Which I'd be happy to be :) (right now it's just C#)
 
One of my cousins passed away a few years ago. She was only a few years older than me - only child.
 
user142019
1:49 AM
I’m only child too, since two years. :(
 
@Rapptz I reckoned. I know a few people like that. I should ask my colleague whether the sleep training/research program he was in helped
 
And her parents (my second-aunt + uncle) obviously have never and will never recover from that loss.
They're too old to have another one.
 
@WTP'-- What?! Does that mean a sibling passed away?
 
I already did research on sleep for about 7 months. Not very interesting stuff if you ask me
 
user142019
@sehe My brother died, yes.
 
1:50 AM
what?
 
@WTP'-- Ow. I can't imagine what that's like. How old was he?
 
We won't ask.
 
user142019
But I don’t want to go into details in such a public place.
 
user142019
@sehe 23.
 
@WTP'-- No problem
 
1:51 AM
@Rapptz huh, i've researched sleep for much longer than that. it turns out that after a sufficiently long period awake, i fall asleep. then, after a sufficiently long period asleep, i wake up. in both cases the transition is usually undesired. so y happen?
 
@Cheersandhth.-Alf What do you mean by research?
 
@Cheersandhth.-Alf I have replicated your findings.
 
well, i've tried it out, systematically
 
I actually missed the joke in the post.
 
Eh I'm done writing for today.
 
1:53 AM
@WTP'-- Well. I'm stumped. I find it tough to see what random stuff people have to deal with. Though it is also encouraging to see the ability of people to adapt. I hope you agree, somewhat...
 
user142019
Well, I still miss him but not as much as two years ago.
 
user142019
The loss felt terrible, but you can’t go on like that for the rest of your life.
 
user142019
And yes, I agree.
 
I don't really know what to say. Sadly, I do really need to see my bed. So I'll just leave it at this. But I'll remember that life is full of surprises. Again. Cheers
 
user142019
Me neither.
 
user142019
1:56 AM
Also, später.
 
user142019
Think I’m gonna sort out my user stories.
 
user142019
2:12 AM
And I have still not sorted out my user stories.
 
user142019
-2
Q: What type of programming is good for create very simple application?

vinmanI have requirement to validate some information .txt file.That .txt file contains some numeric and alphabetic values.I have to code some constant values,if .txt file contains those constant value , that file is good, otherwise its having issue,kind of information. I looking for ideas to create t...

 
user142019
Sometimes I wished Torvalds was on Stack Overflow.
 
user142019
He’s good at belittling people.
 
Linus is an annoying douche.
 
user142019
Linus Trollvalds
 
user142019
2:17 AM
He’s annoying, but he’s proud of it and I like that.
 
user142019
He doesn’t give a fuck.
 
user142019
On Facebook he is, among DeadMG, one of the few people listed under “inspirational people” exactly for that reason.
 
user142019
 
He's an ass, but it's cool, because he's doing it intentionally.
That sounds to me like you expect to see coming out of an ass.
 
2:33 AM
@JerryCoffin I was expecting to see shit coming out of an ass.
 
user142019
 
user142019
^ what.
 
eryangbb?
 
user142019
No, the other word.
 
@WTP'-- One is real captcha, the other is fake. You can put eryangbb whatever.
 
2:35 AM
Mmh, there's a discussion on one of the Standard list that final isn't a terribly useful feature. Not the first such discussion apparently. Now I'm curious... I think I only ever want to use final for inheritance-based type-erasure, where the final type won't ever leak anyway. But I might as well ditch that when/if there's a C++11 Boost.TypeErasure.
 
user142019
@Rapptz I know. It is used for digitizing books so I always put swearwords there.
 
@CatPlusPlus, you still around? where do I specify libraries to be linked for scons?
 
user142019
I hate reCAPTCHA. They annoy me and make profit of it.
 
at most it's free labour.
not very good free labour but still it works.
 
user142019
I’d like it if they gave me money for it.
 
user142019
2:38 AM
Bitcoins or something.
 
user142019
Would be great.
 
user142019
Getting Bitcoins for helping reCAPTCHA digitize books.
 
You'd still have the problem of people lying but this time they'd get paid.
 
@Pubby Precisely.
 
user142019
@Rapptz Well, only pay them if at least ten other people enter the same thing for the same word.
 
2:39 AM
Wouldn't work on 4chan.
 
user142019
4chan isn’t the only reCAPTCHA user.
 
But they have "at least ten other people"
 
user142019
And if you find the CAPTCHA on 4chan annoying you’d buy 4chan Pass anyway.
 
You're missing the point.
 
user142019
@Rapptz It doesn’t have to be on the same site.
 
2:41 AM
If you get paid via a verification process of 10 or more people, a site can game it anyway by putting the same word for the fake one or doing some collective gaming.
 
user142019
You can have two users from 4chan, five from Stack Overflow and three from whatnot.
 
user142019
@Rapptz I mean that I, the one who solves the CAPTCHAs, get the money. Not the webmaster, that would be silly.
 
I didn't state otherwise.
A site has users, you know.
 
user142019
ohh
 
user142019
hmm
 
user142019
2:43 AM
What about a hundred people all on different days.
 
user142019
Like weeks in between.
 
user142019
The chance you get the same word ten times is very small then.
 
user142019
So you can’t cheat.
 
If you'd get paid for it, I think you should make it a job or something. Get paid on an income. It sounds easy enough
 
user142019
Solving CAPTCHAs for a living. Hehe.
 
user142019
2:44 AM
Would be awesome.
 
user142019
CAPTCHAs are terrible.
 
There are probably captcha solvers on mechanical turk
 
@R.MartinhoFernandes I always assumed the Rule of Zero would leave an object in a valid state if an exception was thrown during a copy assignment, but I just now realized that that's not necessarily the case, and in fact cannot be the case if more than one member has no move assignment, and a copy assignment that can throw exceptions.
so in many cases you still want a manual copy and swap as a copy assignment operator.
 
To be precise you want the strong guarantee, not just basic.
Because you do get basic with a run-off-the-mill implicit copy assignment implementation.
 
IIRC the basic garantee doesn't garantee much at all?
 
2:57 AM
@Borgleader It guarantees you have a program. It's actually a lot.
 
@MooingDuck it was non-smart to allow throwing moves
imho
 
@Cheersandhth.-Alf Wouldn't help for strong copy assignment.
 
because it's an optimization, and optimization shouldn't add new failure modes
 
@Cheersandhth.-Alf throwing moves are not relevant to this situation
@LucDanton I had assumed the rule of zero would give me that :<
 
I can't think of a case where a throwing move is necessary.
 
2:59 AM
oh, assignment
 

« first day (740 days earlier)      last day (4206 days later) »