2,365 reputation
11428
bio website
location
age
visits member for 3 years, 6 months
seen 4 hours ago

Dec
20
asked Maintenance wise, is `else while` without intervening braces considered safe?
Dec
12
awarded  Popular Question
Sep
4
awarded  Good Answer
Aug
28
comment How do you name your personal libraries?
@dasblinkenlight: lol.
Aug
28
asked How do you name your personal libraries?
Aug
27
comment Does C# give you “less rope to hang yourself” than C++?
@CharlesSalvia: Uh, how exactly does "C++ make it easier to take advantage of the CPU cache" than C#? And what kind of control does C++ give you over memory that you cannot have in C#?
Aug
26
comment Does C# give you “less rope to hang yourself” than C++?
kevin: Uh, your answer makes no sense. It's not C#'s fault that you're doing it wrong. You do NOT depend on finalizers in properly written C# code. If you have a field that has a Dispose method, you must implement IDisposable (the 'proper' way). If your class does that (which is the equivalent of implementing RAII for your class in C++), and you use using (which is like the smart pointers in C++), it all works perfectly. The finalizer is mostly meant to prevent accidents -- Dispose is responsible for correctness, and if you're not using it, well, that's your fault, not C#'s.
Aug
26
comment Does C# give you “less rope to hang yourself” than C++?
@gbjbaanb: Like DeadMG said -- signed integer overflow is undefined. It's not implementation-defined. Those phrases have specific meanings in the C++ standard, and they aren't the same thing. Don't make that mistake.
Aug
26
awarded  Nice Answer
Aug
25
revised Does C# give you “less rope to hang yourself” than C++?
added 376 characters in body
Aug
25
answered Does C# give you “less rope to hang yourself” than C++?
Aug
13
accepted Should I put newlines before or after binary operators?
Aug
13
comment Should I put newlines before or after binary operators?
+1 this is a really convincing way of putting it.
Aug
12
comment Should I put newlines before or after binary operators?
@delnan: Oh, you're definitely right about that -- there isn't any 'error' with your reasoning, it's just a bit short-sighted. :-) You're assuming that (1) there is only supposed to be a single mistake that leads to errors, or that (2) people make predictable mistakes when writing code. (For example, you're completely ignoring the use of regexes in a text editor -- I use them often, and every once in a while they cause errors like this.) The bottom line is that this is more error-prone in general (at least for me, maybe not for you), not that it's just one step away from correct code.
Aug
12
comment Should I put newlines before or after binary operators?
@delnan: I'm not kidding when I say it's easy to make the mistake. It's happened to me. Just set your editor to 8 spaces per tab, with tab-based indentation, and open a 4-space-indented file it. If (for whatever reason) it doesn't detect things correctly, and you try un-indenting a block of code and "fixing" it by re-indenting, you'll see this sort of code will get messed up upon un-indenting. It really slips by me quite easily, but if you or your colleagues never run into problems like this, more power to you I guess.
Aug
12
comment Should I put newlines before or after binary operators?
@delnan: It's actually very easy to accidentally screw up the indentation with your text editor, e.g. when bulk-editing or doing rectangular selection. And if/when that happens during maintenance, you won't get an error in the first case and it will silently slip by you, but you'll get a nice error in the second case.
Aug
12
comment Should I put newlines before or after binary operators?
@delnan: I (very carefully) never said it causes a line continuation. I'm aware you still need enclosing grouping characters. I said it helps prevent mistakes with your line ending prematurely, which it does, by giving you an error.
Aug
12
asked Should I put newlines before or after binary operators?
Jul
19
comment Why all classes in .NET globally inherits from Object class?
@dasblinkenlight: FYI, Java is the one presently copying C#, with lambdas, LINQ functions, etc...
Jul
19
awarded  Popular Question