1,184 reputation
815
bio website
location
age
visits member for 3 years, 9 months
seen Oct 13 at 21:33

Jan
2
comment What's the reasoning behind the “I” prefix naming convention for interfaces in .NET?
@ScottWhitlock: For me, IAnimal is much more readable than AnimalInterface. Verbose names are preferable except in cases when a simple short convention can be used for something occurring frequently enough. And interfaces are such a case.
Dec
31
comment Having error codes option in C++ library for performance
@Shao Voon Wong: No. Because of "Subsequent calls do nothing if they determine an earlier call resulted in an error" there are no error chains.
Dec
31
accepted Hash function classification interview question
Dec
31
comment Hash function classification interview question
Thanks, that's it - the link seems to be the source of this ***. It still makes no sense as they're mixing many things together: 1. computing the hashCode from a key (e.g., fold and add), 2. improving (=smearing) the hash (e.g., mid-square), 3. mapping the hash to the index (e.g., modulus, "&").
Dec
30
asked Hash function classification interview question
Dec
20
comment How can I tell whether my computer is Harvard or von Neumann architecture?
This surely depends on the definition. If you replace the rather obsolete dichotomy by a trichotomy, most current general purpose computers are Modified Harvard Architecture.
Dec
12
answered How can I tell whether my computer is Harvard or von Neumann architecture?
Dec
3
comment What should I use for a package name if I don't have a domain?
@FrustratedWithFormsDesigner: The life is full of risks and I took this one. For some time I'd do nothing and when needed I'd switch everything to a new domain. That's surely no easy task and would cost me quite some time, but the only alternative is to buy the domain immediately. It's not expensive, but the probability of somebody buying "my" domain is very low.
Dec
3
answered What should I use for a package name if I don't have a domain?
Nov
13
comment Is use of finally clause for doing work after return bad style/dangerous?
@Martijn Verburg: AFAIK, a try-catch-finallt block is essentially free as long as there's no actual exception thrown. Here, javac doesn't try and doesn't need to optimize anything as JIT will take care of it.
Nov
13
comment Do you use i-->0 for backward loops?
@barrem23: Your loop is more explicit, but it's wrong (in the sense it does something else than mine). And that's exactly the problem: I can either make it nice or error-proof, not both.
Nov
13
answered How to structure git repositories for project?
Oct
6
comment When to use identity comparison instead of equals?
@FredOverflow: I was never claiming that it makes sense to always override equals. Using virtual operator== directly corresponds with Java, as it's equals is always virtual; if it makes sense in C++ is a different story.
Oct
5
comment When to use identity comparison instead of equals?
@Mike Baranczak: What Java does to Strings doesn't matter in the context of my question as I meant it (which doesn't match well what I wrote). In C++ virtual operator== gets used in place of java's equals and pointer comparison gets used in place of java's ==, so I see there more or less 1:1 correspondence. But feel free to add the tag if you're confident it belongs there.
Oct
5
comment When to use identity comparison instead of equals?
I see that my question isn't very clear (and I still don't know how to make it better). Your first two cases are just optimizations; I could have left other==this out and I could have used equals for the class comparison (as it's actually the same). The serialization case is an important one. But when would you inside equals compare two fields of an object via == for a reason other than performance?
Oct
5
comment When to use identity comparison instead of equals?
@tugs: To me it looks now like C# has two things roughly equivalent to Java's equals, whereby one of the doesn't really work (due to missing overloading). My question is primarily about identity (pointer) comparison vs. content comparison, so it's not that Java specific. I know virtually nothing about C#, but I'm pretty sure the question applies to C++ as well.
Oct
5
revised When to use identity comparison instead of equals?
added 45 characters in body
Oct
5
asked When to use identity comparison instead of equals?
Oct
2
comment Is it possible for a good programmer to have never used version control?
@vartec: What's beyond trivial is git init. The page linked could make me run away as it feels quite complicated.
Sep
18
awarded  Popular Question