Reputation
11,583
Top tag
Next privilege 15,000 Rep.
Protect questions
Badges
4 41 65
Newest
 Guru
Impact
~421k people reached

Jul
31
answered Immutable class with behavior
Jul
27
comment Should HTML or CSS files count toward a “lines of code” metric?
4 lines of CSS for 10,423 lines of HTML? You are clearly far more awesome at CSS then I am.
Jul
26
awarded  Guru
Jul
13
awarded  Revival
Jul
12
comment Banning zero-argument functions — what problems could it cause in a hypothetical language?
what is your function call syntax?
Jul
12
comment Why does Python need both a compiler and an interpreter?
Answers that spend most of their time being pedantic instead of answering the question make me sad.
Jul
11
answered Why does Python need both a compiler and an interpreter?
Jul
5
comment Where should PDOExceptions be dealt with?
Yes, that's exactly how it should work.
Jul
4
answered Clean Code: can private methods rely on member variables set by other private methods?
Jul
4
answered Creating two-way object references and keeping data integrity
Jul
4
comment Where should PDOExceptions be dealt with?
you don't need to add special handling for your PDOException in order to do that. All you need is to have a catch-all error handler that will catch the error, log the relevant information, and then send an error response to the client. In the case of an AJAX request, it should return some sort of error code in the http response, and the client side code show show a generic error.
Jul
3
answered How do I make this functional DSL written in an imperative language more efficient?
Jul
3
comment Creating two-way object references and keeping data integrity
Is this just in-memory, or are you storing this in a database?
Jul
3
answered Where should PDOExceptions be dealt with?
Jul
3
comment Where should PDOExceptions be dealt with?
In what circumstances will the PDOException be thrown?
Jul
1
awarded  Great Question
Jun
30
comment How do I make this functional DSL written in an imperative language more efficient?
Do you have conditionals?
Jun
29
comment How do I make this functional DSL written in an imperative language more efficient?
In the example you've given, you could "recompile" it down to a constant, but I'm guessing you've got parts of the system you aren't showing us?
Jun
29
comment How do I make this functional DSL written in an imperative language more efficient?
Are you concerned about optimizing just the run time, or are you also concerned about "compile" time?
Jun
25
comment How to avoid calling String.Replace() in a loop?
@Alexus, yes it'll end up being basically the same algorithm. The reason I'd consider this is just because it doesn't require you to manually write the logic he's describing.