« first day (322 days earlier)      last day (4619 days later) » 

lol
0
Q: Why is there an endianness problem here?

Tony The TigerI was reading up on this thread on pointer aliasing rules, and one answer gives the following example, which mentions a potential problem with endianness, I wanted to know if anyone could give me what the endianness problem is in the following code? struct Msg { unsigned int a; unsigned in...

ok, I posted a question now, so if anyone knows the answer, please answer!
heh
 
1:21 PM
the future has arrived ?
 
3 hours ago, by R. Martinho Fernandes
The C++11 standard has been published. Rejoice!
 
nope
only the entry has been published
 
i liked the funnest room on chat and sanity was never a requirement
 
the target (i.e the spec) will be published at 2012-02-28
 
@IntermediateHacker We keep changing it.
@JohannesSchaublitb What do you mean? It's at stage 60.60, and I can buy it.
 
1:23 PM
Yay! C++ 11 ! Finally, I have been dying to try out variadic templates
 
@IntermediateHacker GCC had them for a while now.
 
for a while?
 
@JohannesSchaublitb Does that mean C++11 should really be C++12?
 
"It's been a while since GCC has them." Maybe this is more correct.
@StackedCrooked No. Look at the standard number: ISO/IEC 14882:2011.
 
Oh. sorry. which version of minGw?
 
1:25 PM
@R. no it says "target publication date" is 2012
 
GCC 4.5 or 4.6 is the best target for C++11 code.
 
@JohannesSchaublitb That's when they expected it to be published. That target publication data has been there since FDIS.
 
hi i don't understand it
"ISO/IEC 14882:2011 specifies requirements for implementations of the C++ programming language. The first such requirement is that they implement the language, and so ISO/IEC 14882:2011 also defines C++"
 
just a quick question: how does one debug thing "elevated" in visual c++ express (or visual c++ studio), without running the IDE itself elevated, and without creating special helper program to run a program elevated?
 
what is the difference between "C++ programming language" and "C++" which they also define ?
 
1:26 PM
You need to elevate the debugger.
No workarounds.
 
yes but i find no setting for that
 
wow I see now!
 
i guess i can run the IDE elevated
perhaps
 
anyway, how is managed code supposed to be "theoretically" faster than unmanaged c++?
 
It's tightly integrated into the IDE AFAIK. You could always run windbg or cdbg.
 
1:27 PM
it's a very peculiar notion of security...
 
what is the logic for this theory?
 
it has 1338 pages...
 
I've always found unmanaged code to be faster
 
JIT compiler has more context to work with than static compiler.
 
@IntermediateHacker Managed code has different optimizations available.
@IntermediateHacker It can be faster.
 
1:28 PM
@IntermediateHacker for example, perhaps it can detect and skip "dead code"
 
like what optimizations?
 
"dead code"?
 
There's an SO question on this. Let me see if I find it.
 
Code that can never be reached.
 
1:29 PM
It can be faster?
 
Or the VM could skip code that has no effect.
 
tracing jits can do that
 
Though static compilers are pretty good at dead code pruning, anyway.
 
i'm lost
 
101
A: How much faster is C++ than C#?

Martin ProbstThere is no strict reason why a bytecode based language like C# or Java that has a JIT cannot be as fast as C++ code. However C++ code used to be significantly faster for a long time, and also today still is in many cases. This is mainly due to the more advanced JIT optimizations being complicate...

 
1:29 PM
I think it is purely theoretical or very minor on spcial code.
IMHO, no evidence, C++ still comes out ahead on average.
 
ok, but the performance penalty of the vm itself is a lot more than that gained by skipping dead code right?
 
Usually
 
JITed code doesn't go through VM.
 
@IntermediateHacker Measure.
It highly depends on the code.
 
Runtime might be slower, but still no reason it has to be slower.
 
1:31 PM
And the compilers involved.
 
So, if a person writes good C# code and optimizes it well, it can equal or even be faster than c++ code?
 
E.g. PyPy JITed code easily outperforms optimised C code for contextual things like string formatting.
 
It all depends.
But the possibility is there.
 
The thing is both "managed code is faster" and "managed code is slower" are wrong assertions.
 
1:33 PM
If you do a manual job repeatedly for hundreds of times you start to become more efficient at it. Intelligent runtimes work in similar ways. At least that's the idea.
 
You cannot make generalisations about performance.
 
Besides, performance is a complex beast, and the raw performance of the executed opcodes is not the only thing you need to consider.
 
I just did.
 
Nice. So according to the answer @RMartinhoFernandes Pointed out, C# may even someday be faster than C++?!
 
Languages don't have speed.
 
1:35 PM
may even be more efficient than c++?
 
@IntermediateHacker You're missing the point.
It's implementations that have speeds.
 
It's already more efficient, if you consider programmer efficiency.
 
I like @Konrad's answer better. "It's five oranges faster."
 
I prefer bananas.
 
1:36 PM
@RMartinhoFernandes i think one can safely say that with infinite programmer resources, assembly will be faster than c++, and c++ will be faster than c# or java. the problem lies in the time to produce the code. when one starts to insist on equal programming effort, then it gets pretty difficult to say anything definite.
 
With infinite monkeys and infinite tape, you can program Turing machine.
 
You don't need the infinite monkeys.
 
You always need infinite monkeys.
Who'll eat the bananas, otherwise.
 
@CatPlusPlus Lol
 
A single monkey can eat five bananas.
Hell, I can eat five bananas.
 
1:39 PM
Five bananas a day keep the doctor away.
 
Anyway, bye bye. I gotta take out C# 4.0 - the complete reference back from the cupboard
 
But can you defend yourself against a banana?
 
im giving managed code another try
 
You could actually kill someone with a banana. As long the other party doesn't offer any resistance.
 
1:40 PM
I'm now eating the banana!
 
@RMartinhoFernandes he he i'm stealing that for facebook
"what if someone comes at you with a banana and you haven't got a gun?"
just if anyone's interested, it did not work to insert call to DebugBreak (Windows just thought the program had crashed, instead of starting Just In Time debugging), but it did work to run Visual C++ Express "elevated". this in Windows 7.
 
@AlfPSteinbach I think you should post an SO question. This should get a quick answer there.
 
1:56 PM
DebugBreak basically calls int 3, which is invalid when there is no debugger attached.
 
well yes, but at least in the old times, when program crashed you got option of JIT debugging: it would then invoke and attach debugger
this seems to not be there with Visual C++ Express 2010
 
Maybe VC++ Express doesn't register a debugger?
The Professional (or Premium or whatever) version certainly does.
 
Als
What did i miss?
okay fcuk 2 downvotes
 
is that still the guy who downvoted you systematically?
 
Als
2:11 PM
I don't know @AlfPSteinbach, maybe not or maybe he wizened up because now i see a few unusual downvotes daily.
Like this one...I don't see any reason whatsoever for downvoting this.
maybe downvotes one or two answers off daily, so that evades the fraud detection.
@AlfPSteinbach: Did you get rid of your stalker?
 
@Als huh, it's a long time since i been stalked
 
Als
Is it? I remember we had a conversation not too many days ago.
where you said and posted a few answers of yours which were downvoted
Or was that too long ago?
 
i think a few downvotes now and then, that's just normal
it's different when suddenly a lot of downvotes, on very old answers or even questions
 
Als
@AlfPSteinbach: Yes, a few are understandable, but you can always make out a genuine downvote from an jealousy downvote.
 
Why the last one?
 
because it says "The most comprehensive matrix for compiler support of C++0x features can be found here (if you dare to check for the features yourself)."
 
Oh, where is it then?
 
it's not useful if it's from stone age so that you need to "check for the features yourself". it could aswell list an empty table and say "since we don't update this table, you should check the features of the following compilers yourself"
 
The list was last updated one month ago.
It's hardly the stone age.
 
2:51 PM
so while it might be correct "it is the most comprehensive modulo the list of features" it's almost not useful because the whole point of such a matrix is to inform about features the compilers support
 
I think the "check for the features yourself" thing is about "if you're not using Boost.Config".
 
well all I know is that the table is outdated very much
 
Ah, I see. At least the Clang column is not up to date.
 
which one is hard to work with in C++ according to you guyz? -> Overload resolution or Templates
 
2:59 PM
frankly I only looked at the clang column
and was upset
 
GCC and MSVC seems correct. I have no idea about others.
 
can you do ordinary windows program with clang?
 
at the boost developer meeting they claimed that clang supports almost no c++0x features
such a shame. i bet they just looked at that apache matrix
 
Als
@x4d33746153706c306974: Both are needed in distinctively different scenarios, So should be used appropriately.
 
It still lacks a bunch, but it supports some of the major ones.
It has template aliases, which I'm sorely missing in GCC.
 
3:02 PM
@Als but which one is hard if asked ?
 
Als
@x4d33746153706c306974: Hard in terms of?
 
The inappropriate one? :P
 
they paused implementing constexpr because it is unimplementable, and are waiting for the outcome of an issue list they sent to the committee for the bloomington meeting
lol @RMartinhoFernandes
 
@JohannesSchaublitb Unimplementable? Well, it's a bit late now :(
 
understanding and troubleshooting
 
3:04 PM
@RMartinhoFernandes they will meet 3 times a year and produce defect reports so it's not too bad
 
Als
@x4d33746153706c306974: Templates are not peculiarly easy while sorting out compilation errors or debugging so I will say templates.
 
for beginners like me , they're huge pain in ass
 
I don't know. I do templates, but I don't do overload resolution (the compiler does it for me). However, when I do templates, overload resolution matters.
 
overload resolution was easy in c++03. c++0x added some complications but it's still all a logical unit. except that the FDIS has some defects, but they are being sorted out
 
can you guyz link me to some project done in of C++ templates (even yours) , so that i can understand them more precisely ( not big one please) ?
 
3:08 PM
@x4d33746153706c306974 I think to understand templates you need to read a good book on templates
 
@TonyTheTiger : i am reading them from a website tutorial
but without exercises they are hard to get grip
 
The canonical recommendation is C++ Templates: The Complete Guide.
Wrong link.
 
that book is really costly)
 
I know. But it's good.
 
Als
@x4d33746153706c306974: First of all I will recommend, You get rid of that big ass display name of yours, its a bit of a pain to my eyes.
 
3:13 PM
any exercises will be good than book i think)
 
Als
@x4d33746153706c306974: you could get the e-book of Nicolai Josutils book somewhere on the internet
 
@Als : ok i will soon since you can only change your nick after period of one month from last edit
 
@x4d33746153706c306974 Have a look at the STL source code?
 
Als
@StackedCrooked: That would scare someone too much!
 
Boost is scarier imo.
 
3:15 PM
@Als I had tried once but they were like horror movies
 
STL is quite readable.
 
@StackedCrooked If you can look over the underscores, that is.
:)
 
Als
Book is better, and once one has a grip of things, then you can play as much as you want.
 
I'd probably use a code formatter and perhaps a refactoring tool to rename the identifiers before seriously starting to read the STL code.
 
Omg so can anyone link me to some c++ templates exercises ?
 
Als
3:16 PM
@x4d33746153706c306974: You finished the Josutils book?
 
You don't need to finish that book before attempting a C++ excercise with templates.
 
@Als : told you already i don't have any book except one from which i had started learning c++
 
Als
@StackedCrooked: how are you going to do exercises without knowing anything about templates?
 
Get a good C++ introduction like Accelerated C++. It contains exercises for templates.
 
@Als : i am reading them from website )
 
Als
3:18 PM
@x4d33746153706c306974: You could get an e-book on the internet.
 
@Als Those are pretty much as expensive as the dead tree books.
 
You can download the books via torrent sites if you really don't have the money.
 
Als
@RMartinhoFernandes: Darn I am repeating this for the n th time now, Those are there on the internet, you need to be able to use google
and since we already had the morality talk before i care two hoes if you are going to say thats not legal
 
@Als Ah, so you are... "promoting" illegal copying of those. Ok.
 
3:20 PM
@RMartinhoFernandes : why would you can those good books (Nicolai's) are dead tree books?
 
Als
@RMartinhoFernandes: All is fair in love, war, sex and capitalism.
 
All is fair as long as you don't get caught :)
 
@x4d33746153706c306974 Sorry, I can't parse that.
 
Als
@RMartinhoFernandes: I am not going to ask someone to buy a book for learning when it can be obtained for free just so you can stop passing your curt quotes.
 
@Als : suppose that i got those books and read them , where do i get excercises?
sorry to pester you all
 
3:23 PM
@x4d33746153706c306974 why not invent your own exercise? that's what many of us do.
 
Als
@x4d33746153706c306974: I do not know about the exercises, but there should be a thread already here in SO, asking that, you can search for it perhaps.
 
i am fed up of coding algo's and small games
 
write your own implementation of a vector class. as an extra challenge: make sure it doesn't require the elements to have a default constructor.
 
@x4d33746153706c306974 Dead tree books are books made of dead trees (aka paper) :)
 
tree paper comes from tree plantations. it doesn't require deforestation, if that is what you are worried about.
 
Als
3:26 PM
here we go drifting in worthless pedantic detail
 
@Als It annoys me when someone that accuses the ISO of promoting this kind of thing is openly suggesting it to someone else a few hours later. It's @x4d33 ...'s decision to make, in any case.
@StackedCrooked It comes from dead trees from tree plantations.
 
The tree lives on as a book!
 
Trees are people too.
 
When I die I want to become a book.
 
Als
@RMartinhoFernandes: It annoys me when someone who justified ISO in acting as non moral based organization turn over and lecture me on morals a few hours later.
 
3:29 PM
I assumed you are an individual, and not a standards organization.
 
Als
Why You assumed I am more moralistic than ISO?
I am a free and self confessed advocate of open source. And well Let us not get in to the murky details of morality for at some point of time everyone of us has/had obtained something which we didn't pay for from the internet when we were supposed to pay for it.
 
What does open source have to do with copyright violation?
 
Als
Remove that out of context since that just adds an new dimension which is not what we are discussing.
 
@Als : what's your age?
 
Als
@x4d33746153706c306974: Why?
 
3:33 PM
@Als : please
 
I'll leave it at: ISO has technical obligations, not moral obligations. But people usually have moral obligations.
 
Als
@x4d33746153706c306974: Why? What makes you asks that?
 
@Als : just out of curiosity
 
Besides, copyright violation is a legal issue.
 
Als
@RMartinhoFernandes: Do you mean, You never downloaded any piece of book, any music, any movie or anything that was available on the internet and you didn't pay for it?
Are you talking of that kind of morality?
 
3:35 PM
 
Als
@RMartinhoFernandes: Darn robot, look you make me look bad, he know wants to know my age!
:P
 
@Als I don's see how you inferred that from my messages.
 
Als
@RMartinhoFernandes: I am asking
 
@Als i am asking your age man
 
The anwer is "no". Does it make my point any less valid?
 
Als
3:37 PM
@x4d33746153706c306974: Geez, you are making me nervous.
 
@RMartinhoFernandes : can you please wait till Als answers my question
 
validityOf(pointOf(identityOf(@Als))) != validityOf(pointOf(identityOf(@RMartinhoFernandes)))
 
children children, stop arguing please
 
@x4d33746153706c306974 Some people don't like to share this kind of details on the Internet. It's rude of you to continuously ask for it.
 
Als
@RMartinhoFernandes: So what is your point? I should say you go buy the book from a bookshop, while in our own basements, we would get it for free?
 
3:38 PM
@RMartinhoFernandes : i don't mind telling it , just wanted to know ( i am 22)
 
Als
@RMartinhoFernandes: How moral would that be? That has an morality sense too
 
you both masturbated when you were 14 years old so you are both immoral.
 
@x4d33746153706c306974 that's fine if you don't mind, but other people do mind, so stop asking
@StackedCrooked lol
 
@x4d33746153706c306974 If you ask again, I'm going to flag you.
 
what are you guyz , females?
 
Als
3:39 PM
@TonyTheTiger: Do i seem to be too illogical, that he wants to know my age?
lol
 
ok
i will not
@Als : not at all
 
@Als donno
 
@Als No, you should not do that. You should not have it for free in your basement in the first place. But just because you did something you shouldn't it doesn't mean you should suggest it to others.
 
Als
@x4d33746153706c306974: I do not mean to offend you, but this is just internet, and we are a few regulars here and still we don't know each other in real world. You will stay here long enough you would know what you are asking for sure.
 
3:41 PM
@Als ok i will not ask , sorry
 
Als
@x4d33746153706c306974: just if it helps I am older than you and I am male.
@TonyTheTiger: Just in case someone doesn't get wrong ideas ;P
@RMartinhoFernandes: Is Suggesting a crime?
Legal or moral?
 
I believe that leading others to do something wrong is immoral. If you believe otherwise, we have found our point of disagreement.
Aug 4 at 17:05, by Tony The Tiger
@Als oh I've turned female now... kewl :)
 
Als
@RMartinhoFernandes: That depends on perception of right or wrong
 
meh, disagreemnts
 
Just leaving this here.
 
3:43 PM
thx robot
 
@RMartinhoFernandes : can you unflag me ?
 
@x4d33746153706c306974 I didn't flag you!
 
Als
@RMartinhoFernandes: Yes, sure we can agree to disagree. And no hard feelings I hope the same from you.
lol @x4d33746153706c306974, dont worry you were not flagged.
We would know if you were.
 
this is the internet, there is NO feelings. :P
 
@Als What @Tony said, but with correct grammar.
 
Als
3:45 PM
@TonyTheTiger: Tiger, darn we are better off talking about booze and dames, and leave these talks for the brainy peeps here
 
@RMartinhoFernandes you grammar Nazi!!!
 
@Als hahah, let's talk about boobs then
:P
 
Als
@TonyTheTiger: he ain't even British and yet he is pretending of being a grammar nazi
 
3:46 PM
@TonyTheTiger Didn't we already do that yesterday?
Mammography is the process of using low-energy-X-rays (usually around 30 kVp) to examine the human breast and is used as a diagnostic and a screening tool. The goal of mammography is the early detection of breast cancer, typically through detection of characteristic masses and/or microcalcifications. Mammography is believed to reduce mortality from breast cancer. Remaining aware of breast changes and physician examination are considered essential parts of regular breast care. In many countries routine mammography of older women is encouraged as a screening method to diagnose early breast ...
 
@Als he's a bot, merely executing instructions
 
Als
@TonyTheTiger: wOOt about them -------> ( * )( * )?
 
@FredOverflow dude that's mammography, I know it involves boobs, but I want boobs
 
@Als I think you got those upside down.
Aug 4 at 17:05, by Tony The Tiger
@MartinhoFernandes I LOOOOVVVVEEEEE my titties :P
 
Als
@RMartinhoFernandes: haha
 
3:47 PM
:)
 
:This article is about the human breast. For other animals, see Udder and Mammary gland. "Boobs" redirects here. For other uses, see Boob (disambiguation). For other uses, see Breast (disambiguation) The breast is the upper ventral region of the torso of a primate, in left and right sides, which in a female contains the mammary gland that secretes milk used to feed infants. Both men and women develop breasts from the same embryological tissues. However, at puberty, female sex hormones, mainly estrogen, promote breast development which does not occur in men due to the higher level of test...
 
@TonyTheTiger Type 5318008 into a calculator and turn it upside-down.
 
damn it won't inline the link :(
is this shit filtered or something?
 
@TonyTheTiger You have posted the link twice in the same message...
 
@RMartinhoFernandes oh I must have been drunk writing that
damn, it used the wrong pic
I hate this chat sometimes
meh
 
3:49 PM
@TonyTheTiger It always uses the wrong pic.
One day we should file a bug report on meta.
 
Als
@TonyTheTiger: Those(in the pic) don't look too good do they? :P
 
no
that's what I was sayin
 
I was gonna post something more explicit, but I thought I better not
 
Als
@FredOverflow: Whats that? A dude on a boob?
 
3:50 PM
@FredOverflow It's a nipple
 
Als
lol
 
I didn't even see the dude
 
Als
oh perhaps its a noob on a boob
4
 
my perv mind got fixated on the nipple
 
3:51 PM
you perv
 
Als
is that by any chance @FredOverflow?
lol
 
A new sport was invented, boob climbing :P
 
Als
haha
 
@FredOverflow : holy fuck
 
3:52 PM
@FredOverflow that's damn cute :P
 
so lucky kitty
 
Als
@TonyTheTiger: Who is cute? @FredOverflow, or the @CatPlusPlus or the Boob?
 
Pussy in a bra.
 
@Als Well excluding @FredOverflow (no offence) the combination of the kitty and the boob.
 
3:54 PM
(Though I can't see a bra.)
 
she was braless that day, for the comfort of the pussy
 
Als
@RMartinhoFernandes: There is none......gives his expert nod
 
@Als : can you tell what is the paygrade to c++ developers for beginners?
 
Als
@x4d33746153706c306974: Depends on the location and varies depending on the domain AFAIK
 
@Als make a guess according to your location
 
Als
3:57 PM
@x4d33746153706c306974: Are you in same location as what I am at?
 
@x4d33746153706c306974 and not having a degree (like me) also makes a difference, definitely if you don't have any professional experience yet
 
I've a degree
yes i have no experience
 
Without any work experience, and a degree, here you'll probably get something like 800€ a month. But location matters a lot.
 
@Als just asking , i am from pakistan
lol
 
@RMartinhoFernandes I got more then that on my first job, is that beginner devs get where you're at?
 
3:59 PM
i am not from Pakistan
 
@TonyTheTiger Made it more explicit.
 
Als
@x4d33746153706c306974: I am not sure, Location does matter a lot. And it shouldn't be too difficult for you to find out the semantics based on your location.
 

« first day (322 days earlier)      last day (4619 days later) »