« first day (750 days earlier)      last day (4188 days later) » 

12:00 AM
@Cheersandhth.-Alf missing/wrong include paths?
It compiles fine with gcc 4.6.2
 
user142019
A friend of mine makes music and he releases everything under a CC license.
 
Says here GCC has partial support for concurrency.
 
@Rapptz concurrency != <thread>
 
@DeadMG seams you right about that. argh, will ahve to fix!
 
Well, if you want to be pedantic, sure.
 
user142019
12:01 AM
If you need concurrency, use Erlang or Elixir.
 
@Rapptz Wut. atomics are pretty darn essential to lock free programming
 
Anyway it still has partial support for <mutex> and <thread>
 
#define CPPX_WITH( initializer )                    \
    if( bool cppx_with_finished = false ) {}        \
    else for(                                       \
        auto const& cppx_with_object = initializer;  \
        !cppx_with_finished;                        \
        cppx_with_finished = true )
 
@Rapptz Ok. That's clearer
 
user142019
12:02 AM
Clang has atomics implemented, IIRC.
 
@sehe no it finds the header, but protests.
[D:\dev\test]
> gnuc foo.cpp
foo.cpp: In function 'int main()':
foo.cpp:6:5: error: 'mutex' was not declared in this scope
foo.cpp:6:11: error: expected ';' before 'm'

[D:\dev\test]
>
 
user142019
> The recruiters-who-use-grep, by the way, are ridiculed here, and for good reason. I have never met anyone who can do Scheme, Haskell, and C pointers who can't pick up Java in two days, and create better Java code than people with five years of experience in Java, but try explaining that to the average HR drone.
 
user142019
I want that on a T-shirt which I’ll wear during the first Java lessons.
 
@Zoidberg'-- right. matches my own experience. but library is different matter!
 
user142019
@Cheersandhth.-Alf Use Clojure or Scala!
 
12:09 AM
the library is simply too large to assimilate in any reasonable time span
 
user142019
Oh in that way.
 
user142019
Well if they’d teach the students to use documentation it shouldn’t be a problem.
 
user142019
If I were a teacher I would subtract points for code with inconsistent coding style.
 
ah, should avoid warning about variable not being used...
#define CPPX_WITH( initializer )                        \
    if( bool cppx_with_finished = false ) {}            \
    else for(                                           \
        auto const& cppx_with_object = initializer;     \
        ((void) cppx_with_object, !cppx_with_finished); \
        cppx_with_finished = true )
@Zoidberg'-- what is "coding style"?
 
user142019
@Cheersandhth.-Alf naming, indentation, brace placement and whatnot.
 
user142019
12:13 AM
It must be consistent or your code is terrible.
 
user142019
Or “code style” or however it’s called.
 
@Cheersandhth.-Alf MinGW?
 
oh, you mean formatting
@R.MartinhoFernandes yes, the one from STL
 
user142019
@Cheersandhth.-Alf among naming, filenames, order of arguments for similar functions, typos/spelling/grammar, and comments.
 
well i would not place consistency highest
 
12:19 AM
@Cheersandhth.-Alf I think there's some issues with the threading stuff in MinGW. I didn't investigate much, so I don't know any details.
 
for example, it is not unusual to see code with elepannt used consistently instead of elephant
due to automation in editor/IDE
consistent but horrible!
 
user142019
Not the highest, but it would certainly weight.
 
user142019
Of course the most important is that it works.
 
@Xeo What?
Blasphemy!
Next thing you're going to tell me they make for nice dice rollers too.
 
user142019
int meh() {

}

void Foo() // ugh -1
{ // ugh -1

}
 
12:22 AM
the first ugh should of course be on int meh() {
:-)
 
user142019
I think I’d go for something like up to -2 for formatting/style because I’m a good guy.
 
user142019
@Cheersandhth.-Alf it was about the inconsistent capitalization of function names.
 
@Zoidberg'-- does that mean you deliberately write code that scores -2?
 
user142019
Of course, if Foo is a pronoun, it’s fine.
 
@Zoidberg'-- oh, i noted the inconsistent braces first
 
user142019
12:23 AM
@Cheersandhth.-Alf no, but if a student would make 10 inconsistencies I’m not going to subtract 10 points, only 2.
 
user142019
Also our next project will most certainly be a video game. :<
 
user142019
If you want to make video games, go to the Game Academy. ಠ_ಠ
 
well, here's my take on it: intelligent decision making can not be captured in simple mechanical rules
the best code is clear
 
user142019
My school is terrible and I’m going to quit ASAP.
 
one may start with simple rules, but like art, the important thing is to know when to break 'em
for example, i regularly write namespace blah { because with nested namespace that gives less clutter and more clarity than following the braces convention I use elsewhere
it may seem arbitrary at first glance
 
user142019
12:27 AM
If you do that for all namespaces, it’s still consistent. :)
 
well i do
:D
 
user142019
namespace foo {
    void bar()
    {

    }
}

namespace foo {
    void moo()
    {

    }
}
 
user142019
^ consistent.
 
:(
There goes my bounty.
7
A: What encoding does c32rtomb convert to?

bames53For the assertion to be guaranteed to hold true it's necessary that the multibyte encoding used by c32rtomb() be the same as the encoding used for string literals, at least as far as the characters actually used in the string. C99 7.11.1.1/2 specifies that setlocale() with the category LC_CTYPE ...

:(
 
@Rapptz Steam is probably the only DRM I haven't had trouble with. Its probably why I own 160 games on that platform too
 
12:28 AM
Steam's DRM went to shit the last agreement.
 
user142019
Of course, if I were a teacher and you’d use GNU brace style you’d get -10 instantly. :P
 
@Rapptz What do you mean?
 
user142019
 
You no longer own the games, you own a license to play the games and your subscription to play the games can be terminated at any time should you disagree to any of our future changes to the agreement itself.
 
user142019
I ate the most delicious chicken in my life today.
 
12:30 AM
Though yeah, I guess lesser evil or something.
I like Steam though, don't get me wrong.
 
user142019
If I buy something I want to own it, not a license.
 
@Zoidberg'-- what do you answer when a female on the net ask, early on, if you like to eat chicken?
that happened
 
user142019
@Cheersandhth.-Alf “Yes, unless it’s the kind of terrible dry chicken without any fat.”
 
Yes.
 
Is that a metaphor?
 
12:31 AM
ok
 
user142019
Meat without fat or without much fat is always disgusting.
 
user142019
It’s like the Burger King squared.
 
user142019
 
@Zoidberg'-- Yes, if you buy the license you own it.
 
user142019
I don’t want to buy the license.
 
Xeo
12:34 AM
@R.MartinhoFernandes Forgot to assign it or no assign-worthy answer?
 
@Zoidberg'-- Then don't.
 
user142019
I want to buy a copy of the game itself. Pedant.
 
@Xeo Latter.
I'll ask on the mailing list now.
 
user142019
bar() ->
    receive
        foo -> io:format("bar!~n"), bar();
        _   -> io:format("haha sucker!~n"), bar()
    end.
 
user142019
Erlang is so fucking awesome.
 
12:36 AM
That guy's answer is close to being a community wiki
 
Xeo
@Zoidberg'-- ~n o_ô
 
user142019
@Xeo newline.
 
Xeo
But... why ~?
 
because fuck consistency.
 
How sophisticated a program can one make with pure C++? By pure C++ I mean, no secondary libraries, no SDK, no engines, just straight out of the box.
 
Xeo
12:38 AM
@DiscreteGenius However sophisticated you want.
 
@DiscreteGenius As sophisticated as you want to. It'll just take longer.
 
What does sophisticated mean?
 
bloated
 
Xeo
complex
 
^this
 
12:40 AM
^that?
 
Xeo
because, you know, engines, sdks, libraries etc you use are also written in C++.
 
I was aggreeing with Xeo
 
Xeo
you just need to rewrite those.
 
@Xeo Sometimes people forget that.
 
user142019
@Xeo that’s only for io:format. You can also use \n in string literals.
 
Xeo
12:41 AM
Aha
 
user142019
I have no idea why io:format has ~n, by the way.
 
user142019
\n would work fine.
 
user142019
I think it’s because looks more consistent in io:format with other sequences, such as ~s.
 
user142019
io:format("Hello, ~s~n", ["world!"])
 
Xeo
mhm
 
user142019
12:51 AM
0
Q: Why does `io:format` support `~n` when `\n` does the same thing?

Zoidberg'--These two give identical output: 1> io:format("Hello, world!~n"). Hello, world! ok 2> io:format("Hello, world!\n"). Hello, world! ok Why does io:format support ~n when \n does the same thing? Are there any differences?

 
user142019
Stupid onebox y u no update title.
 
Xeo
Heh
 
I feel like I'm in a rut with C++. I've read books and tutorials on the language but I still can't manage to produce anything worth while.
 
Xeo
The onebox is rendered once.
 
For the same reason it doesn't update the question's upvote/downvote total
 
user142019
12:54 AM
 
Uhmm yeah you do, you totally do.
 
user142019
Not “simply”.
 
user142019
It takes time and effort.
 
Something something ninja wizards
 
@Zoidberg'-- Elaborate please.
 
user142019
12:55 AM
@DiscreteGenius C++ is very complex so it takes time and effort to learn.
 
user142019
And it does some things implicitly and some things not. And then you have template meta-programming and ADL and whatnot.
 
user142019
Just try to write some programs.
 
user142019
And experiment with things.
 
@Zoidberg'-- ~n indicates carriage return + line feed while \n is line feed only.
 
@DiscreteGenius Like most things, if you just try to learn C++ abstractly, without applying it, you're unlikely to really learn a lot. A lot of techniques won't really stick until you write some code with them -- and in a lot of cases, many of us really have to learn the hard way, by writing some ugly code, then wishing it wasn't so ugly, and go looking for techniques that let us do that job more easily, before we really learn things.
 
user142019
1:01 AM
@Rapptz on all platforms?
 
user142019
The documentation just says “writes a new line”.
 
It's what I got from Googling, I ended up here erlang.org/doc/reference_manual/data_types.html
 
I find it's better to attempt to write code and then try to learn how to better it rather than the other way around.
 
Which I also found here
 
@Zoidberg'-- @JerryCoffin That really helps. Thank you.
Has anyone heard of LeadWerks?
 
1:03 AM
Something I always thought was ugly were sorting algorithms.
 
user142019
@Rapptz It only seems to support ~n, equivalent to carriage return+line feed pair ('\n' in C).
 
user142019
But even in C, \n is not CRLF, it’s just LF.
 
@Rapptz Well, at least the library can save you from having to rewrite them for the gazillionth time.
 
Ell
would you say you need to know template metamagic to know c++?
 
user142019
Whether it gets translated to CRLF or not before output depends on the OS.
 
1:05 AM
Yeah but I figured in Erland \n would be just LF due to the way the thing was worded.
 
@Ell Well you need to be able to use templates proficiently
 
@Ell Yes and no. I'm pretty sure quite a few people write C++ for entire careers without ever doing any metaprogramming. Other people (especially those doing libraries) can barely go a day without it. Question is what sorts of things you really want to write.
 
I just have to say, you guys & gals, and this chat room are one of the greatest contributions toward C++. Thank you!
2
 
user142019
Right shoulder y u bleed.
 
Ell
she's on her period
 
1:08 AM
I can't believe Mitt Romney is 65. He looks like he's in his early 50s.
 
user142019
@Rapptz Make-up.
 
@Rapptz Money
 
user142019
Rapers gonna rape.
 
what's the purpose of std::negate(a) when I can just do -a
 
user142019
@Rapptz you can use it with std::bind and templates and stuff.
 
Ell
1:14 AM
templates?
oh okay
 
user142019
Same goes for std::plus and friends.
 
user142019
Erlang is awesome;
You really should use it now;
It is fucking great.
 
Xeo
@Rapptz It's std::negate<some_type>()(a), btw.
GCC, Y U NO ERROR ON PRIVATE DTOR?
 
user142019
GCC, Y U NO NOT SUCK?
 
@Zoidberg'-- @Zoidberg'-- Y U NO FUNNY
 
user142019
1:20 AM
@Borgleader @Borgleader Y U NO SENSE OF HUMOR
 
Xeo
Gah, I forgot that VC10 checks for a copy-ctor when eliding moves...
 
user142019
 
user142019
Me gusta.
 
Ugh, tomatoes.
 
@Zoidberg'-- "Me Gusta is a rage comic face that is typically used to express one’s approval of an awkward or perverse situation." Since when are sandwiches awkward or perverse? (knowyourmeme.com/memes/me-gusta)
 
1:27 AM
@R.MartinhoFernandes You don't like tomatoes? Not even on sandwichs?
 
user142019
@Borgleader “Me gusta.” is a normal Spanish sentence, you fool.
 
user142019
Yesterday I ate a sandwich with ham and butter. It was so fucking tasty. I didn’t know I liked bread so much.
 
user142019
It was the first time in a year I ate a sandwich.
 
@Zoidberg'-- Sandwiches are not magical. They don't make tomatoes edible just because you put them in them.
 
@Zoidberg'-- Irrelevant, it has now transcended to the level of meme.
 
user142019
1:29 AM
I like tomatoes. Unless they are rotten.
 
The only way to make tomatoes edible is to turn them into tomato sauce.
Sorry, I have no explanation for this phenonemon.
 
Put salt and pepper on them
Or maybe it's just pepper
 
I don't understand the hate for tomatoes.
Tomatoes are delicious. Especially in sauce form.
 
I think you mean Yummatoes :P
 
You guys are disgusting. I'm going to sleep.
 
1:31 AM
Hope you dream about tomatoes.
 
user142019
I want an edible punchcard.
 
Ell
night
you have mentioned that punchcard thing. won't a cracker do?
 
ah, norton AV warned me that the performance of Visual Studio is ungood
:D
 
@Cheersandhth.-Alf I don't see why you're happy about this.
 
Because Norton AV is crazy.
 
user142019
1:35 AM
An AV program should not warn about anything but malware.
 
AVG does the same thing.
 
user142019
But Norton has always been terrible.
 
user142019
I have seen Norton AV’s source code and even that is terrible.
 
user142019
C with Classes, pointers everywhere. Morons.
 
Norton is proprietary and closed source isn't it
 
user142019
1:36 AM
Yup.
 
Of course, or else it'd be easier to bypass :P
 
user142019
But it got leaked. You can find the source code in the porn section of The Pirate Bay.
 
So you didn't get the source code.
 
Does anyone know exactly what kind of encoding Windows wide characters use?
 
I was once told there are some pretty hilarious comments in the Windows source code (for I believe XP, but it might be the case for any version)
 
1:38 AM
The last time I said UTF16 Either Robot or Cat told me it wasn't true.
 
user142019
@Rapptz Here is the Dutch news article that links to the source code: nu.nl/internet/2760209/….
 
user142019
@Borgleader Probably 2000, which got partially leaked.
 
@ThePhD UCS-2 I think
 
user142019
LOL
 
user142019
> Rage Against the Turing Machine
 
user142019
> IF YOU CHANGE TABS TO SPACES, YOU WILL BE KILLED
 
user142019
:D
 
lol I like how that comment is broken.
 
* CallProc32W is insane. It's a variadic function that uses
* the pascal calling convention. (It probably makes more sense
* when you're stoned.)
hmm
 
user142019
// <HACK>
goto EndHack;
// </HACK>
 
user142019
1:43 AM
I love that one.
 
how does one quote text in the chat?
 
user142019
> like this
 
> ishyggt
 
Turns out Windows internally is UTF16
 
1:44 AM
Yes how dyu do that...
 
So I'm gonna stick with using UTF16
 
> use le meme arrows
 
private\ntos\w32\ntuser\client\nt6\user.h:
* The magnitude of this hack compares favorably with that of the national debt.
 
"or use italics"
or use code
 
> private\ntos\w32\ntuser\client\nt6\user.h: * The magnitude of this hack compares favorably with that of the national debt.
 
1:44 AM
I know Ctrl-K is for code
@Rapptz A bit late :P
 
Ctrl+k is for code?
... Neato.
 
I hate Chrome so much. T_T
 
user142019
@Rapptz use Safari.
 
Firefox <3
 
Fuck Safari. It's even worse than IE, which should be impossible but somehow it happened
 
1:46 AM
Use Opera
 
user142019
I never have problems with Safari.
 
user142019
I use it all the time.
 
user142019
It’s the only browser I’ve used that actually starts up instantly.
 
Chrome starts up instantly for me.
FIrefox takes 100000 years.
 
Same here.
 
1:47 AM
Opera takes some time, but it's faster than firefox.
 
user142019
Chrome takes over three seconds for me. :<
 
Safari is shit unless you're on a Mac.
@Zoidberg'-- Update that shit, man.
 
Because Apple products are all so fucking bad except when used with their proprietary software. Even Microsoft products such as Office run decent in Mac OS X.
 
user142019
@ThePhD I already have 22.0.1229.94.
 
user142019
@Rapptz except Office for Mac stores its preferences in the fucking Documents folder.
 
1:48 AM
@Rapptz Wasn't always like that. Some Microsoft products on mac ate the shit before they realized they could make sweet money off the Mac users.
 
user142019
Which is most vexing.
 
Then suddenly the latest office for Mac was ultra-cleaned-up.
 
user142019
I use iWork and it works fine.
 
Office 2003 ran decent in Mac OS X.
 
user142019
Or actually, most of the time I use LaTeX.
 
1:49 AM
LaTeX makes things so pretty
But it's so painful to use. :c
 
Do you enjoy torturing yourself? How can you stand writing things in pure LaTeX?
 
Xeo
Crap. 24 (votes Kerrek needs) vs 11 (answers I need)...
 
@Borgleader it's just a low-key joke. not big ha ha, but more like, a little smile. and, it actually did. :-)
 
I've been using asciidoc, much easier to use than LaTeX
 
I wrote like, a single school report on Embedded Development in LaTeX. After 24 pages, I vowed to never use it again.
 
user142019
1:50 AM
inb4 hot chick wearing latex clothes onebox
 
@Pubby Probably not for scientific and mathematical fields.
 
user142019
I write all reports for school in LaTeX.
 
@Rapptz You can embed LaTeX formulas in it apparently
 
I will murder anyone who makes me do that.
I will rage against tehmachine.
I will take the 20% grade cut, damnit. Never again.
Neeveeeeeeeeerrrrrrrrr.
 
I use LaTeX daily, it's annoying as fuck.
 
user142019
1:52 AM
11 mins ago, by Zoidberg'--
> Rage Against the Turing Machine
 
user142019
LaTeX is not annoying, IMO.
 
user142019
It works great.
 
No it doesn't. If you've used it extensively you've know how annoying it is to write.
 
I wish the entire world just spoke 7bit ascii with a monospace font
 
What just irks me is that I have to compile - and then print - my papers.
I have to compile my papers. ... WHY?!
 
1:53 AM
It's repetitive and painful, diagrams end up being in a different location than you intend, there are so many annoying things about LaTeX.
 
user142019
We never have to print anything.
 
Lucky you, people want hard and electronic copies - which baffles me. Just... take one, or the other, please?
Pretty please? :c
For da twees? :c
 
ASCIIDoc looks cool.
 
Understanding how to position floats in latex was the most annoying thing ever.
I had to use all kinds of arbitrary positioning and margins what would've taken me a drap-and-drop, maybe a second click, in a regular Word Processor.
 
If you can embed LaTeX in this, suck as equations, it'd be lovely.
 
1:55 AM
We need more Cowbell!
Gotta have more cowbell baby!
 
we need that in higher resolution!
 
Yep!
I have a cowbell and drumstick with a matching T-Shirt.... Good stuff.
 
@Chimera That is the shittiest video player I have ever seen, I'm trying to move the change the volume or move the video cursor and it drags the entire player...
 
@Borgleader LOL...
 
Someone has never watched Anime. I swear anime streaming sites have the worst video players I've ever seen in my life.
 

« first day (750 days earlier)      last day (4188 days later) »