« first day (96 days earlier)      last day (4867 days later) » 
00:00 - 21:0021:00 - 00:00

9:01 PM
I smell meta-sloppiness.
 
both lvalues and function designators are defined very clearly in the C spec and there should be no doubt
 
I guess that's why pirates don't like to program in C: there are no rrrrrrrrrvalues.
2
 
lol
 
9:04 PM
I joined ACCU over the summer so I could get Overload and CVu. Overload in particular has had some excellent articles. (Also, it's fun to get mail from another country :-D)
 
ohh
does it contain comma operator abuses?
my only international mail i got so far was my SO stickers and SO t-shirt xD
 
Stickers?!
 
do you guys think any C++ user will become moderator?
 
9:07 PM
@James yeah they sent stickers for free
 
@peoro Honestly, I don't care.
 
25
Q: Stickers for Stackers (i.e. post your sticker shots!)

Kyle CroninUPDATE: For those feeling left out of the sticker party, details on how to obtain stickers are now on the blog! Look what arrived in the mail yesterday - stickers! Thanks Jeff! First, I put a StackOverflow on my black 2007 MacBook, my primary computer and the one I use to code and check Stac...

 
My lappy would love to have a Stack Overflow sticker on it.
 
my favourites are that ninja jingy guy and george stocker
 
@JohannesSchaublitb Oh nice. Now I have to go find an envelope or two. Thanks for the link.
@peoro Probably not, but there is only one high-rep [c++] contributor running for moderator (at the moment at least).
 
DeadMG can't be moderator, he would never find enough time to finish his compiler!
 
@JamesMcNellis yup, I noticed (and am wondering why others didn't apply, but I think it's not polite to ask :P)
 
By the way, how do Chinese people distinguish moderator elections from moderator erections? Aren't both called "modelatol elections" in China? ;-)
 
lol, this chat is a lot less serious than I used to think
 
@peoro C++ has an operator for "a lot less", it is called <<. But it's also used for bit-shifting and output on streams.
 
9:16 PM
@FredOverflow this was << funny than the previous jokes :-P
 
(goes off to define a numeric type with operator << overloaded as meaning "a lot less"...)
@peoro I can't do it on command :-/
 
@FredOverflow then do it WITH a command: fortune!
 
@peoro xD
 
@peoro I'm too much of an ass to be a moderator.
 
hey
0
A: pass smart_pointer to constructor vs raw pointer

DeadMGIf your class totally owns the object passed to it, then you are best to make that explicit via the use of auto_ptr in all applicable cases. Having to construct the auto_ptr explicitly is the best case because it enforces that the API user knows that you own that object and reduces the likelyhood...

it's not that I disbelieve you, James
more that I find such a hole to be so unbelievably staggering, I can't quite accept that it's true
the last time I checked, a compiler had complete freedom to evaluate the expressions in whatever order it liked, but had no choice about completely evaluating one before another
and that partially evaluating one, and then another, was definitely illegal
 
9:28 PM
@JamesMcNellis a self-critical ass is not a bad thing ;-)
well, I'm leaving. Have a nice night (or day, according to your timezone), bye!
 
@DeadMG Did you read the linked GOTW?
 
yeah
 
So...
 
but considering that the link says that the most recent solution was posted before 2002, I'm definitely fine to put it down as outdated
since there was a new Standard since then
 
@DeadMG: Even N3225 contains the non-normative note "The evaluations of the postfix [function-call] expression and of the argument expressions are all unsequenced
relative to one another." (5.2.2/8)
 
9:35 PM
relative to one another, not relative to parts of themselves
if I call function(expr1, expr2), the compiler is not within it's rights to stop evaluating expr1 half way through and decide to go evaluate expr2 now
 
Yes, it is. The expressions are evaluated "unsequenced relative to one another"
It can evaluate them however it likes, so long is at the end (if no exception is thrown), the result is correct.
 
that quote only states that the compiler can evaluate expr1 or expr2 first
it doesn't state that it can jump between them like a rabbit
 
I don't see how a complete lack of sequencing requirements somehow requires some sequencing.
 
the quote doesn't give a complete lack of sequencing requirements inside the expressions
only between them
 
Only the result of the expression matters. Consider a simpler example: (a * b * c) + (d * e * f). The compiler is free to evaluate t1 = a * b then t2 = d * e then t3 = t1 * c then t4 = t2 * f then t3 + t4. The same is true for the function call expression. In your example above, expr1 and expr2 are just subexpressions of the full function call expression.
(Sorry; I fixed the expression evaluations; I had my tn names mixed up at one point.)
 
9:45 PM
@JamesMcNellis Yup. Makes more sense if you realize that () is an operator :)
 
wow
and I thought that I understood most of the ridiculous things I've read in the Standard
 
@DeadMG There are always more.
 
especially for C++0x
did nobody decide that this is insane and to change the wording?
 
@DeadMG To something more insane? Of course!
 
how could you possibly come up with something more insane?
 
9:48 PM
@CharlesBailey xD
 
How about, "the expressions are unsequenced in relation to one another, but each expression is evaluated in full before beginning evaluation of the next one."
problem solved
 
That's not "unsequenced", that's "indeterminately sequenced" or something.
 
@DeadMG What do you mean by "next"?
Seriously that's how these discussions go.
 
that's the upside of improving wording like this
it really doesn't matter
even if you defined next as the next one on the right or on the left or in the order of evaluation or whatever
it's still a big improvement
 
Defining "next" as "next in the order of evaluation" doesn't tell us anything.
 
9:53 PM
you're missing the point
sigh
ok
wait a minute
how does it not tell you anything?
that sentence says, 1. The expression order is undefined. 2. Each expression is evaluated fully before the next in the order.
it's not supposed to define the evaluation order, and it doesn't
 
@DeadMG Oh, I thought you were suggesting that as an improvement. I really did miss the point.
 
how is it worse?
 
Without defining what "next" means, it's simply meaningless.
 
uh
 
what?
 
9:59 PM
I don't know what definition of "next" you have, but to me, when dealing with an order, say, of expression evaluation, it normally means that it's the one that is going to be evaluated after the one I just evaluated
 
So you are saying that after evaluating some expression, the next expression is going to be evaluated? How does that tell me anything? How do I know what the "next" expression is by looking at the source code?
 
you don't, it's undefined, just like it is now
 
Exactly. And at first I didn't realize that that was your point. (It was, right?)
 
what do you mean?
 
I think we should stop now :)
 
10:04 PM
the point of the change is not to define the order of evaluation for function arguments, it's to prevent compilers from partially evaluating them in pieces and destroying reasonable expectations of exception safety
 
Can you give a good example where the current evaluation scheme breaks your expectations?
 
the question that I linked before this started?
or did you miss that
 
lol sequence points ?
 
I didn't read it. Reading now...
 
function(std::auto_ptr<T1>(new T1), std::auto_ptr<T2>(new T2));
oh wait, it's not exception safe because the compiler might go new T1, new T2, std::auto_ptr<T1>(T1*), std::auto_ptr<T2>(T2*), function
so even though I passed ownership of my dynamic resource to a class that will properly own and release them, it's not exception safe
because if T2 throws, T1 gets leaked
 
10:08 PM
there is no sequence point in between evaluating the first and second argument
if there would, both would be indeterminately sequenced
 
the point isn't that they're not sequenced relative to each other
but apparently, that the compiler can lololol all over the sequencing you would expect within each argument
and go and half-evaluate the first and then half-evaluate the second and then go back to the first again for fun
 
an idea that I find to be so staggeringly ridiculous
I mean, even if the Standard allowed it, what implementer in his right mind would actually do such a thing?
 
if there would be a sequence point after evaluating the first and before evaluating the second one, then such would not be possible anymore
 
hey, our code can run a tiny bit faster, hope you didn't want any form of correctness
 
10:11 PM
i guess for the compiler there isn't really a "second" and "first" argument once it generated intermediary code for them
it's just all one soup
 
@DeadMG Well yeah, Effective C++ Item 17. But I don't see anything related to that in your question, to be honest.
 
it's not my question
it's someone else's question
 
and then James McNellis pointed it out
and then I found the need to discuss something so horrific
 
Oh, I read the question instead of your answer :)
But yeah, that is common C++ knowledge. Do you have Effective C++? If not, buy it. Will save you tons of trouble.
 
10:16 PM
hell, I'd rather not
thank the lord for my bubble, which it can please stay
 
ahem
which I can please keep
 
Why would anyone consciously want to live in an "Ineffective C++" bubble?
 
well
partly, I'm pretty sure that my implementation protects me from this specific nasty
but more importantly, because I'm a hobbyist/student developer and could get away with not calling destructors if I wanted to
 
You can always use a language with less pitfalls. Nobody is forcing you to use C++, right?
 
10:20 PM
pffft
only if I want to be crippled
I'm a perfectionist and extremely dislike the restrictions imposed by .NET or JVM programs
besides, fundamentally, I like C++ and agree with it's multi-purpose approach
I just think that the Standard has a thousand times too many WTFs
2
 
I like C++ because programmers who've used it for years tend to be rather smart, and discussing with them is quite interesting, and you always learn something new. Unfortunately, I know only one C++ programmer in real life :(
 
the kind of WTF where the guy that came up with them should be evicted from the committee
 
And no, it's not me ;-)
 
lol
I don't know any fellow C++ers in real life
if I did, I might finish DeadMG++ in a reasonable timeframe :P
what I need is a real UI design
my current one is, well, programmer art
 
@DeadMG When will the formal standardization process start, and how many years will it take? ;-)
 
10:27 PM
there will be no formal standardization
unless the committee is defined as me, myself, and I
 
@DeadMG So every feature will be accepted with 100% yes-votes? :)
 
every feature that I determine is a Good Idea™
 
When will you bootstrap the compiler?
 
good question
well
right now, I have a briefly written UI in WPF, and I also wrote a tokenizer
but much of the rest of the work is yet to go :P
 
Why would you need a UI for a compiler?
 
10:30 PM
actually, I was making fairly solid progress with a bootstrap in place in a few months, but I lost a couple of weeks of work
because I already had one lying around
and since then I've mostly been working on Dark Sky
I dunno, something strange has happened to me ever since I decided to name it that
like, I've been making actual progress, and the results are actually starting to look like they might be something someday
 
What is "Dark Sky", your game with lasorz?
 
this is a very unfamiliar feeling
yeah
 
@DeadMG on that q about ptr(int) a, b; being impossible.
 
you could decltyp eit
 
for example, #define ptr(T) typename identity<typename identity<T>::type*>::type is a reasonable implementation
 
10:34 PM
I never said that it was impossible
my personal recommendation would be using decltype
 
Ah i think it was @FredNurk
 
template<typename T> std::remove_reference<T>::type* ptr(T&& ref) {
    return nullptr;
}
decltype(ptr(int()) a, b;
I personally prefer syntax over keywords because it increases the range of valid identifiers
for example, I frequently use the identifier ptr for temporary pointers
 
10:51 PM
oh no
Visual Studio has encountered an error and needs to close
no, no, no, my source code!
cry
 
11:25 PM
@DeadMG Erm, Ctrl+S?
 
too late after the IDE has already died and Windows Error Reporting has taken over
 
0
Q: How can I change the language in chromium?

Johannes Schaub - litbI've installed chromium, but it deeply sucks that it uses my mother tongue (german) in its UI and for websites by default. I want the english back, like firefox did. I'm using archlinux's default packages. I looked into the settings dialogs, but I found nothing useful.

 
00:00 - 21:0021:00 - 00:00

« first day (96 days earlier)      last day (4867 days later) »