« first day (475 days earlier)      last day (4466 days later) » 

8:00 PM
@RMartinhoFernandes I was memefying
ohhh C++ now
 
I dunno - I had a 50kloc app on top of POSIX threads that ran fine for me - std::thread makes life easier, but it's all the same if you have sufficient discipline in coding
 
Less code, better code.
 
agreed
 
std::thread?
Rule #1 of threading in C++11: don't use std::thread.
 
replace with?
 
8:01 PM
That's not the good threading support bits.
 
Tasks. async, futures.
 
not here yet, unfortunately
vaporware for me
in general, threading isn't the problem for my app (in terms of time spent)
integration of parts is usually the time sink
 
Threading in general sucks.
 
nah - it's easy if your design is clean
understand it at the lowest level and be extremely careful
and test judiciously with drd/helgrind
 
when I tune out slightly, I can easily convince myself I'm hearing a TV evangelist preach. This is not in Toronto, is it
 
8:04 PM
Threading in declarative model is much better.
 
some people are scared of threading like they're scared of pointers
no need to be scared
 
return std::move(b ? local : non_local); Ugh. Who the heck would write this?
 
scares him too!
 
Xeo
@RMartinhoFernandes It's not global. It's a member.
 
8:05 PM
@RMartinhoFernandes moving from a local is fine right?
but the non_local is a problem
 
Maybe, maybe not. It's ugly as heck.
 
f(S().n)
meh
ugly
 
Fear not, I have returned.
 
Auto-generated constexpr ctors are neat. But S().n being a null pointer constant sucks.
 
Implied: GCC has sucky codebase and unfriendly community.
 
8:07 PM
I don't get it :(
 
I like his shirt.
 
@TonyTheLion The auto-generated ctor for S is constexpr.
 
was that Bjarne asking a question?
 
@CatPlusPlus Ha.
 
Xeo
@TonyTheLion Yes
 
8:08 PM
I have never used Clang. Is it any good?
 
Oh, he's explaining.
 
Xeo
@Maxpm Awesome.
 
Bjarne asked him to explain.
 
@Maxpm It's lambdas away from awesome.
 
Xeo
@RMartinhoFernandes And init lists
 
8:09 PM
@Xeo Well, it's one release away from awesome.
And that's awesome.
 
Xeo
The guys with the numbers are nice.
 
Bug in the standard!
 
meh a bug in the standard
 
@Xeo What do they do?
 
Xeo
@Maxpm Point who's asking the next question.
 
8:10 PM
Neat.
 
sbi
 
Who's presenting now?
 
yay modules!
 
twice as fast as GCC
 
Modules again.
 
8:11 PM
I feel like you guys are a little behind me.
 
@MichaelMyers Chandler Carruth, from Clang.
 
Chandler Carruth from Clang team.
 
I won one!
 
Ah.
Though technically I shouldn't be watching, since my day job does not involve C++ at all.
 
@DeadMG your favourite subject is addressed? A llvm native linker. Turns out they don't want to go there yet because they want to innovate the archaic object file formats :)
 
8:13 PM
Huh.
 
People make null pointer constants out of non-0s?
 
People are silly.
 
What was the "correct" code that fired the warning?
 
VC++ is not a good compiler, boo.
We want Clang, boo.
 
8:14 PM
Boo, Micro$oft lackeys. Booooooo.
Boo everyone.
Boo Linux.
 
more reason to go use Linux more
 
@Maxpm Your "S" key is broken.
 
Minix all the way.
 
Switch to Linux @CatPlusPlus
 
I don't want to.
 
8:15 PM
@RMartinhoFernandes I was being satirical. :P
At least, I think that's satire.
 
Eggcelent.
 
The point is, I was poking fun at die-hard Linux fanboys.
 
Someone wants to have R# for C++11 (convert to range based for? use free-function std::begin() instead of member function)
 
$atire?
 
Eggcelent.
And the end.
 
Xeo
8:17 PM
1h lunch now
 
Next one in an hour.
 
Which time zone is this in?
 
good. imma do some dishes...
 
wow that was a great talk
 
8:18 PM
Spotted any SO shirts in the audience yet?
 
ESP?
 
@sehe Yeah, I'm not sure I want that in my compiler. I don't mind it in a separate tool, but in the compiler?
 
@Maxpm USA ( UTC - 8 )
 
They're in 'murica.
There are UTC times on the stream page.
 
@RMartinhoFernandes +1
 
8:18 PM
Nah, not yet @MichaelMyers
 
@TonyTheLion Ah. I was wondering why everyone was going to lunch at 3:18.
 
because 3:17 would be a bit early
 
It's noon there.
 
It's some kind of a cult that takes a launch at 3:20, man.
Carruth wasn't bad at all, he explained some things very well.
 
8:22 PM
I liked the RMS jab at the start.
 
Yeah, he got it right.
 
haha - that was funny
 
I mean, RMS cannot be a good person, right? The guy wrote emacs.
 
RMS says some crazy #(*! but I'd rather have him on the side of freedom rather than gov't/big corporations
 
@kfmfe04 Define "freedom".
 
8:24 PM
emacs==kitchen_sink
 
@kfmfe04 freedom?
 
@EtiennedeMartel anything anti-corporate/gov't
 
you are some radical here? :D
 
nah - I write proprietary software myself
 
Freedom! Anarchy! Overthrow the government! Declare global variables!
 
8:25 PM
Anyone find a link to yesterday's videos? I still haven't found a way to access them
 
@kfmfe04 send me all yours project
 
I don't fear RMS, but I do fear gov't/corps
 
on stackover@hotmail.com
 
@DzekTrek I would have to kill you first
 
nevermind, I already got it. :D
what language is that, lol?
Chinese, Japanese, Korean?
Oh, Chinese traditional. Just checked
 
Xeo
8:29 PM
@MooingDuck I think they're not up yet
 
@Xeo hrm
 
Oh! The next speaker is a D co-designer!
:D
 
nice!
 
@MooingDuck tommorow will be set up
 
Is this the static if talk now?
 
8:30 PM
did D ever resolve their library wars? years back they had 2 that were incompatible with each other...
 
@kfmfe04 you live in Tainan city?
 
@kfmfe04 I think there's only one in D2.
 
nice
 
@kfmfe04 I'm not entirely sure. I've never had an issue with using just Phobos, the standard standard library.
 
@Maxpm iirc - the std one was more C-like and the other one was more java-like
 
8:32 PM
Do they have a standard for defining standard standard libraries?
 
Xeo
@RMartinhoFernandes Yes
 
C++ has a nonstandard standard library: Boost.
5
 
@RMartinhoFernandes deserves a star
 
@kfmfe04 That seems correct. Skimming this Wikipedia page, it was "resolved" in D2 by separating the standard library (Phobos) from the low-level runtime library (druntime). Apparently, though, Tango (the unofficial library) has yet to be ported to D2.
 
@Maxpm for a while, I thought of using D as an alternative to C++... ...these days, I may try Go instead - too bad that all force you to use a gc
 
8:38 PM
@kfmfe04 One does not have to use garbage collection in D.
 
Yeah, right.
They always say that.
You don't have to use smart pointers in C++.
 
@Maxpm - it's possible to turn off the gc and go fully IIRC in D?
 
There's a post on SO about going commando in D. Lemme dig it up.
 
@RMartinhoFernandes haha - I didn't know that - I'd be interested in having a look
 
I remember it going around the lines of "you can't totally get rid of the GC without issues, and the result is not interesting anyway".
 
8:41 PM
ic
 
12
Q: Turning off the D garbage collector

BigSandwichI'm a C++ programmer thats considering using D for a personal project I want to play around with. I was wondering if there's a way to completely disable the garbage collector, and what the risks are of doing so. I know I can manage my own memory by overriding new and delete to use malloc and ...

 
@RMartinhoFernandes ty
 
Standard library leaks like a bottomless pit if you disable GC.
Just like doing C++ without smart pointers: it's not interesting, and it leaks horribly.
But I don't see the GC as a big problem. I don't have latency-critical code to write.
What I don't like about D is the schizophrenic type system.
 
how different is it from C++'s type system?
 
Are you familiar with reference and value types in C#?
It's the same.
 
8:45 PM
ic
 
Oh, it's not that bad then.
 
That is the thing I hate the most about D.
I would love to know the motivation behind it.
 
@EtiennedeMartel Yeah, I think I misused "schizophrenic typing" here (i.e. hyperbole). I normally use it to mean Java's "real objects vs primitives".
 
user142019
Anyone here experienced with Boost.Test?
 
user142019
I'm getting this horrible output: /Users/.../DatabaseTest.cpp:32: error in "????d??[B??d?%?d??[B\Bp?d???d?": `
 
8:50 PM
Sounds like something went wrong.
2
Yeah, I'm being terribly helpful.
 
user142019
:P
 
user142019
More helpful at least than boost's error messages…
 
Xeo
@WTP Why? An error tells you that something went wrong.
 
user142019
The error is written in a language I don't speak. (see seven chat messages above)
 
Xeo
Yeah, but it says "error"
 
8:53 PM
@WTP fwiw, I've been quite happy with googletest if you decide to give up on Boost.Test...
 
user142019
Boost just thinks WTF after seeing my code. That's the story behind all the question marks.
 
is (data+rhs>data)==(rhs>0) a valid test for detecting overflow for both signed and unsigned, or is it more complicated?
 
Put the parens.
Signed overflow is UB.
And no, it doesn't work in your compiler.
 
@RMartinhoFernandes k. Well, I had it in an assert to tell me if I'm reaching that UB, instead of the compiler pretending silently.
 
Xeo
8:56 PM
93
Q: Best way to detect integer overflow in C/C++

Chris JohnsonI was writing a program in C++ to find all solutions of ab = c, where a, b and c together use all the digits 0-9 exactly once. The program looped over values of a and b, and ran a digit-counting routine each time on a, b and ab to check if the digits condition was satisfied. However, spurious so...

 
@MooingDuck If you want to detect signed overflow, do it in a way that doesn't cause it.
Because this is real UB (optimizations mess it up badly), not just standard pedanticism.
 
Xeo
25
Q: Detecting signed overflow in C/C++

Channel72At first glance, this question may seem like a duplicate of http://stackoverflow.com/questions/199333/best-way-to-detect-integer-overflow-in-c-c, however it is actually significantly different. I've found that while detecting an unsigned integer overflow is pretty trivial, detecting a signed ove...

 
@Xeo thanks Xeo
 
@RMartinhoFernandes How do optimizations mess it up?
 
11
Q: GCC Fail? Or Undefined Behavior?

MysticialThe following code goes into an infinite loop on GCC: #include <iostream> using namespace std; int main(){ int i = 0x10000000; int c = 0; do{ c++; i += i; cout << i << endl; }while (i > 0); cout << c << endl; ret...

@Maxpm They assume overflow won't occur (because you shouldn't write code that causes it, it's UB!) and optimize accordingly.
 
8:59 PM
@RMartinhoFernandes makes sense
 

« first day (475 days earlier)      last day (4466 days later) »