« first day (28 days earlier)      last day (4903 days later) » 

sbi
10:00 PM
@FredOverflow I'm still gaining on you. :)
 
@sbi I don't like to think about the 23k rep I've missed out on because of the rep cap...
 
sbi
How do you know?
 
I think the rep cap is set too low.
Or even stupid. It makes me wait till tomorrow to ask another great question, because I can't get rep for it today.
 
sbi
@Fred Jon would have hit 1 million rep by now if it was any higher.
 
Why can't we have a rep cap per question or something.
Jon Skeet?
So what if he had a million? Isn't he worth a million?
 
sbi
10:04 PM
@FredOverflow I dunno. The few C# answers I got from him weren't wrong, but weren't real revelations either.
 
Does anyone here have "The D Programming Language" by Alexandrescu? Is it worth a read?
Is it "the best" D book around?
 
i think if rep calc would be gone, c++ answerers won't have any change anymore to catch up with all the c# guys.
 
You mean "chance", right?
hm, that's a solid argument
 
@sbi The total number of upvotes you've received is at the top of the /reputation report. Mine is 7,917 and I have no more than 53 downvotes (I searched for "(-").
@FredOverflow I have a copy and have skimmed over a few chapters. It looks like it's worth reading.
@FredOverflow I've never actually read many of his answers on SO. His book was good though.
 
@JamesMcNellis I am looking to broaden my view and was thinking of getting one D book and one C# book. Think I'll settle for Alexandrescu and Skeet. (I already have 10 C++ books, that's enough :) Although maybe I'll get the 2003 standard in dead tree form just for hun.)
 
10:18 PM
@FredOverflow I think Andrei's book is the only book on D, isn't it :-P
 
@JamesMcNellis I don't know :) But then by definition, it must be the best around. Awesome.
 
@FredOverflow Wait off on getting C# in Depth; there's a second ed. about to be published. If you buy the book directly from Manning you can get a PDF copy immediately and they'll ship you the hardcopy when it goes to print.
 
@JamesMcNellis Thanks, good to know
 
I went to a presentation Walter Bright gave a couple of months ago on the many paradigms of D. It was interesting, but I wasn't impressed enough to really take the time to learn it.
 
10:21 PM
@FredOverflow Oh, so it is. 28. Oktober 2010. Well, I guess I'm at least 16 days behind in my keeping track of "when every computer book is published." :-P
 
It's 28th of october in germany and 8th of November in the USA, apparently. But it's currently not available in germany. And it has not been released yet in UK.
 
@FredOverflow Does Germany still use old style dates? :-D
 
@JamesMcNellis I dunno, what would the new style look like? :)
 
Old Style (or O.S.) and New Style (or N.S.) are used in English language historical studies either to indicate that the start of the Julian year has been adjusted to start on 1 January (N.S.) even though contemporary documents use a different start of year (O.S.); or to indicate that a date conforms to the Julian calendar (O.S.), formerly in use in many countries, rather than the Gregorian calendar (N.S.). The internationally used Latin cognates of O.S. are stili veteris or stilo vetere, abbreviated st.v. and translating as "(of) old style", and the respective cognates of N.S. are sti...
(It was a joke)
 
Oh:)
 
10:24 PM
hi
 
sbi
@ahmednadar Yup, the ebook's out, and the hard copy should be coming off the printer any time now.
 
If you actually want to learn C# though it's probably not the best book for that. It's more like what Effective C++ is for C++: it doesn't teach C#, it gives best practices.
 
sbi
Hi Rafael!
 
I found Programming C# to be a good introduction to C# book, though I only skimmed through it.
 
@JamesMcNellis So what would you suggest?
 
sbi
10:25 PM
And since we had have a few new faces here:
7 hours ago, by sbi
BTW, *some advice for newcomers* here:
You can edit your messages for 2mins. Try the `v` arrow to the left of it. You can edit your last messages using `cursor up`, `escape` cancels this.
Markdown sort of works here, but we've come to rename it as Letdown, because it's pretty buggy.
Links to a few sites (all SE site, Wikipedia, Twitter etc.) will inline an excerpt of the page linked to, when they are the only text in a message.
Reply to others using the familiar @syntax. Reply to specific messages by clicking on the little down-right arrow appearing at its very right when you hover over it.
@FredOverflow I learned C+ from O'Reilly's Pocket reference book, SO, and bothering my fellow-workers.
 
thanks sbi!
 
@sbi What is C+?
 
i mean @sbi
 
@RafaelPĂ©rez Hi.
 
@james hi james
 
10:27 PM
@RafaelPĂ©rez Hi.
 
sbi
@Fred That's what you might get when you miss # on a German keyboard. :-x
 
How hard is it to learn C# if you already know Java and C++ and Haskell? Is there anything completely mind-blowing that isn't in any of those three languages?
 
sbi
Coming from C++, it was quite easy.
 
i found learning C# very easy coming from JAVA
 
sbi
10:30 PM
What I first found hard, but now like more and more, is LINQ.
 
I guess an "Effective C#" (aka C# in depth) would suffice for my needs. I know about LINQ from several videos and articles.
 
sbi
And lambdas, but those you have to learn anyway.
 
i used the wrox book, it's quite readable and complete.
 
@sbi Lambdas are most natural in Haskell (and C++0x)
 
sbi
@FredOverflow Is that the one by Bill Wagner?
 
10:31 PM
@FredOverflow I've found the language easy to pick up. The hardest part for me thus far was figuring out IDisposable. It's so unnatural.
 
i'm learning C atm
 
@sbi Damn, there actually is a book called "Effective C#"? LOL. I meant "C# in depth" because James said it was like "Effective C++" for C#.
 
sbi
@FredOverflow It's not that I didn't grasp the concept. But they have several levels of abbreviating syntax...
 
ms software development delves into the unnatural frequently (:
 
@sbi It appears learning new languages mostly comes down to learning new syntax, not new concepts... :-( I was so excited about C++0x "concepts" and now they are removed :-( BTW how can you name a concept "concept", that's just asking for trouble and confusion :-)
 
sbi
10:33 PM
@FredOverflow Yes, there is. It's in Scott Meyers' Effective ... series. Scott's goal with EC++ was to write the best second C++ book money can buy, and I'm pretty sure that stretches to the other books in the series. I wouldn't have learned easily from EC#.
 
@sbi So is "C# in depth" like "Effective C#" or not?
 
@FredOverflow There are two books: Effective C# and C# In Depth, both basically trying to fulfill the role of Effective C++, but for C#.
 
@JamesMcNellis Well, what alternatives are there to IDisposable if you don't have destructors? The using statement is tied to that interface, isn't it?
 
sbi
Ok folks, the grumpy old man has been chatting away most of the day. He'll now grab his (non-computer) book and retreat.
Have a nice one everyone!
 
@sbi You too.
 
10:38 PM
@JerryCoffin Hmmm... maybe I'll just get both, can't hurt to read two books :) Unless Schildt wrote a book about C# ;)
@sbi ciao
 
sbi
@FredOverflow Splutter!
 
@sbi Please curse in german ;) I don't know what splutter means.
 
@FredOverflow Given how mediocre (and lousy) authors chase the latest trends, it would be almost surprising if he hadn't.
 
@JerryCoffin oh god he did, it's called "c# 4.0 the complete reference"
 
10:41 PM
according to a review, it's "Arguably the best C# 4.0 book around" LOL
@sbi I still don't get that Splutter post.
 
@FredOverflow "Professional C#" from Wrox is the one I used.
 
herb > scott -.-
 
@FredOverflow I think he was referring to your point about a book by Schildt.
 
@JerryCoffin okay but what exactly did he mean?
 
@FredOverflow I suspect that he meant he found it a bit humorous...
 
10:44 PM
@JerryCoffin so did he burp or something? :)
 
dunno about that schildt guy. never read any book of him
 
@FredOverflow Or something -- like laughed hard enough to splatter coffee (or whatever he was drinking) on the keyboard.
 
@JerryCoffin okay now i get it. i thought "splutter" meant "stutter"
@JohannesSchaublitb Stay away as far as possible from "C++ The Complete Reference", that guy doesn't even get a simple copy assignment operator right.
 
@JohannesSchaublitb Oh, you should at least look at one some time. Once you know enough not to take it seriously, some of it can be pretty funny. The best was his "Annotated C Standard", which contained literally hundreds of mistakes varying from stupid to downright silly in a few places. It starts with main returning void, and goes downhill from there.
 
@JerryCoffin Just LOLing at your brilliant summary :)
Doesn't he also say that a byte is always 8 bits or something?
 
10:48 PM
ohh no!
 
The best part is the format: one page from the standard with his page of annotations directly across from it, apparently to make his mistakes as easy to find as possible.
 
does he comment all the standard?
 
"The American National Standards Institute sells ISO 9899:1990 (the C language standard) for around $130. Schildt's annotated version sells for about $30-40. The price difference reflects the value of the annotations. At no time do the annotations clarify, enhance, or supplement the standard. The difficult or obscure points are often ignored; occasionally, "clarifying" text is added which flatly contradicts the meaning of the text."
Despite (in at least one edition) a missing page of the standard, a few missing punctuation marks, and a few other botches, this does contain the text of the standard as it stood in 1990.
The rating would (and should) be 10 (best). However, there are the unfortunate annotations from Herb Schildt. These "helpful notes" are brimming with errors, half-truths, untruths and sheer fantasy.
 
oh
i better read the C rationale document xD
 
@JohannesSchaublitb We want a portable assembly language for UNIX. Isn't that enough rationale? ;)
 
@JamesMcNellis Oh wait, one thing blew my mind: the new async and await keywords to support asynchronous programming in C# 5.
@Johannes: BTW, watched the STL videos yet?
 
haven't watched them yet :)
 
@JohannesSchaublitb The typeface in that document does not look very professional.
Like the C++ standard better in that respect.
@JohannesSchaublitb I think Stephan is a brilliant lecturer. And his initials are S.T.L. how cool is that?
 
@FredOverflow I watched the first one. I haven't had a chance to watch the others.
@FredOverflow I'm not 100% sure that they are substantially more useful than what can be built using async and future and their friends in C++0x.
 
@JamesMcNellis Well, then you will probably already have decided whether you want to watch the rest or not, right? :)
 
10:58 PM
lol
 
@JamesMcNellis I don't know about async and future in C++0x, have to brush up on that.
 
The sad part of it is that the standards (both C and C++) could really benefit from decent annotations. There are hundreds of details like which reference tell you what important points that really are hard to find -- but he didn't even try to cover anything like that.
 
@FredOverflow Since I'm no longer programming in C++ aside from a few hobby projects, I'm having a hard time justifying taking the time to watch the rest of the STL videos.
 
@JamesMcNellis I just love to see that S.T.L. guy teach :)
 
He is an excellent presenter.
 
11:01 PM
Did you notice he has only one eye?
 
To answer your previous question about IDisposable, I just have a hard time understanding why you'd want automatic management of memory but manual management of every other resource (which is how it works in C#) when you can have automatic management of every resource (e.g. C++ with RAII)...
@FredOverflow I wasn't really paying that close attention to him, lol
 
@JamesMcNellis Yes, I don't understand that either. It seems lots of people aren't even aware of the fact that a garbage collector only handles the memory "problem".
 
@JamesMcNellis You don't, really. The problem is that Sun (among others) has done a good enough job of selling people (PHBs) on the idea that memory management is terribly difficult that they probably have no choice but to include GC. That, in turn, makes it almost impossible to do anything else well at all.
 
@JerryCoffin Right.
 
Although I must say I love the idea of GC for immutable value objects with structural sharing. That is not "possible" (at least not idiomatically) in C++.
 
11:06 PM
@FredOverflow It certainly has some good points, but at least IME, the problems it brings always outweigh the gains.
 
@JerryCoffin What problems? Complexity guarantees? Oh wait, you mean GC in general? I thought you meant shared immutable value objects.
 
@FredOverflow Yes, I meant GC in general. GC is a small gain, but deterministic destruction is a big loss. For the wrong situation, GC can cause other problems as well, but must of the time it's not really much to worry about (with a modern GC).
 
On an unrelated note, does D have something similar to rvalue references and move semantics?
 
@FredOverflow D has garbage collection. It also has deterministic destruction though. (I know that doesn't answer your question; I don't know the answer to your question...)
 
I was just wondering how "unique" the idea of move semantics is to C++.
 
11:11 PM
@FredOverflow GC mostly obviates move semantics, since "copying" is (essentially) free.
 
@JerryCoffin You mean because only a pointer is copied?
 
There is a middle way between Java-like GC and pure C++ RAII, and that's deferred deallocation. That calls to operator delete() simply hand the memory over to a garbage collector. Which can do its stuff when app otherwise idling. Assumption being that deallocation is costly.
 
@FredOverflow Right.
@AlfPSteinbach ...which is mostly the same as lazy coalescing, since coalescing free blocks is the part of deallocation that's generally expensive.
 
hmm
conservative GC is also an option
 
@Jerry: thx. I have no experience with it, though.
 
11:14 PM
like you can scan memory for pointer patterns
 
BTW who is responsible for calling the allocation function operator new? That is just so stupid, people constantly confuse it with the new operator :)
 
@Alf what happened to your pointer tutorial?
14
A: delete vs delete[] operators in C++

Johannes Schaub - litbThe delete[] operator is used to delete arrays. The delete operator is used to delete non-array objects. It calls operator delete[] and operator delete function respectively to delete the memory that the array or non-array object occupied after (eventually) calling the destructors for the array's...

 
@Johannes: it moved around a bit. it's now on google docs. you can find link to it at my wordpress blog, alfps.wordpress.com.
 
@JohannesSchaublitb That does not answer my question, I know what operator new does :-)
 
@Alf ohh thanks
 
11:20 PM
@AlfPSteinbach "Basically, a pointer is a value [...] We also say that a variable [...] is a pointer". Finally someone gets this right, thank you!
 
@thecoshman uncovered where the tutorial is :)
@thecoshman it's at alfps.wordpress.com
 
@FredOverflow: Thanks, I'd like to think so. The first parts were extensively peer-reviewed. But I think it was Dave Abrahams disagreed with precisely that statement... ;-) Nothing engenders "discussion" in C++ as much as terminology.
 
@JohannesSchaublitb what tutorial
 
Wait a minute, 171 pages on pointers? Wow!
 
@thecoshman the one you asked the link for
 
11:23 PM
what's going on? I am confused panda
when? what link? wait... vague recolection of asking for something
 
@AlfPSteinbach Did you write that just for fun or is this a book?
 
8 hours ago, by thecoshman
@JohannesSchaublitb link plz
 
@FredOverflow: it started out as a continuation of a hopefully correct tutorial on C++, the one linked to from the FAQ. except it's nowhere on the net now.
 
@AlfPSteinbach I don't see a big difference from int or anything else -- there are pointer rvalues and pointer lvalues (and in C++0x prvalues, and xvalues and on and on...) "An int" can be either a variable or a value, and the same basic idea is true with pointers.
 
@Jerry yes
 
11:28 PM
@JerryCoffin By "and on and on" you mean "and glvalues", right? :)
 
oh yer right
 
glvalue = { lvalue, xvalue }
 
@FredOverflow I was thinking there were at least a couple more, but I'm like those African tribes that count "one", "two", "many" -- C++0x just has "many" types of values! :-)
 
I thing the "g" was meant to stand for "general", but what about "x" -- "extended"?
 
there really is only lvalue,xvalue and prvalue
the other two are groupings
 
11:30 PM
@JohannesSchaublitb So would (int*&&)(p) be an xvalue?
 
@FredOverflow yes
 
@AlfPSteinbach x = expiring
@JohannesSchaublitb But it would be pointless, right? I mean, who wants to move from pointers?
 
i personally always thing about "crossing"
because it's got lvalue and rvalue properties :)
 
@Johannes: Any news on the "rvalue = temporary object" disaster in the C++0x draft?
 
@FredOverflow yeah looks like a pointless thing
 
11:34 PM
@JohannesSchaublitb Maybe important in generic code
 
and (int* &&) cannot be used on the left side of assignment
@FredOverflow dunno what the meeting did with that.
let's hope they fixed the wording a bit :)
 
@JohannesSchaublitb Oh cool, g++ incorporates the new expression taxonomy in its error messages:
error: using xvalue (rvalue reference) as lvalue
@JerryCoffin that's a nice screen cap :)
but what's the point
 
@FredOverflow neat :)
 
@JohannesSchaublitb I must say I was terribly confused the first time I heard that named rvalue references are lvalues and anonymous rvalue references are xvalues. But it all makes sense :)
 
11:40 PM
=)
 
@FredOverflow Unfotunately, it wouldn't let me put the text with the graphic. The point is there really are more than three, so my excuse for not remembering all of them remains intact (sort of, anyway).
 
Do you think we'll ever get a third kind of reference T&&&? :)
@JerryCoffin There are only three distinct ones.
 
An expression that is an rvalue is either a prvalue or an xvalue -- it can't be "just" an rvalue.
 
google chart api allows creating such diagrams easily
 
11:43 PM
@JohannesSchaublitb example please
 
11
Q: Please add support for tables in answers and questions.

Johannes Schaub - litbI would like to use tables in answers and questions. Without such support, I find myself using ASCII art tables with the code-text tool, but that takes too long, and isn't really maintainable. This could be used to illustrate memory cells, and of course to create "real tables" with information c...

ok that's a bit weird example..
chart.apis.google.com/chart?cht=gv&chl=digraph{expression-%3Eglvalue-%3Elvalue;glvalue-%3Exvalue;expression-%3Ervalue-%3Exvalue;rvalue-%3Eprvalue}
 
@JohannesSchaublitb Looks ugly compared to the graphic in the standard, but that's just my opinion :)
 
chart.apis.google.com/chart?cht=gv&chl=digraph%7Bexpression->glvalue->lvalue;glvalue->xvalue;expression->rvalue->xvalue;rvalue->prvalue%7D
hmm link doesn'T embed :)
@FredOverflow i think i agree
it should support anti aliasing imho would be much nicer
 
@JohannesSchaublitb +1 for AA
Stupid question, what is C++ ->* Lounge supposed to mean? is C a pointer to member? (I'm not too familiar with pointer to member syntax.)
 
struct D { D *operator++(int) { return this; } int x; } C; int D::*Lounge = &D::x; int main() { C++ ->* Lounge = 42; }  xD
 
11:54 PM
struct S
{
    int x;
};

int main()
{
    S* C = new S();
    int (S::*Lounge) = &S::x;
    C++ ->* Lounge;
}
Damn I'm slow :)
BTW "C++" in my program is well-defined as long as I don't dereference that pointer later, right? :) And yes I know, I have a memory leak there :)
 
Did you ever have a practical use for a pointer to a data member?
 
C++ creates a "one-past-the-end" pointer
 
@FredOverflow Yes, it's well defined -- you're basically pointing one past the end of an array of one element.
 
@JerryCoffin That's what I thought.
 
11:59 PM
@FredOverflow ...but Johannes beat me to the punch.
 
@JohannesSchaublitb You can read that in two ways, because the language C++ introduced the notion of ("created", so to speak) one-past-the-end pointers, right? :)
@JerryCoffin Yes, but you hit more keys on the keyboard.
 

« first day (28 days earlier)      last day (4903 days later) »