Reputation
3,928
Next privilege 5,000 Rep.
Approve tag wiki edits
Badges
9 22
Impact
~124k people reached

  • 0 posts edited
  • 5 helpful flags
  • 104 votes cast
Feb
8
awarded  Nice Answer
Jan
22
comment Exception handling in a program that needs to run 24/7
If the application needs to run 24/7 there's an infinite loop somewhere and this infinite loop had better be wrapped around some construct that catches all unhandled exceptions. If that's not the case, an unhandled exception will percolate to the already existing catch-all handler that's outside of main, and kaboom! the 24/7 application terminates.
Jan
21
answered When do rounding problems become a real problem? Is the least significant digit being one off really a big deal?
Jan
19
answered What is dispatch? Does it imply dynamic resolution?
Jan
19
comment What is dispatch? Does it imply dynamic resolution?
@miraculixx - C++ does not have multiple dispatch. You have to fake it with some design pattern such as the Visitor Pattern.
Jan
17
comment Extracting data from log files
Why are you worrying about performance first? The first thing to worry about is solving the problem. Only then should you worry about performance, and only if needed. You didn't give us near enough info to help you solve the problem. As far as Python not being parallelizable, see wiki.python.org/moin/ParallelProcessing .
Oct
14
comment What should and what shouldn't be in a header file?
A bit belated, but +1 for documentation. Why does this class exist? The code does not speak for itself. What does this function do? RTFC (read the fine .cpp file) is an obscene four letter acronym. One should never have to RTFC for understanding. The prototype in the header should summarize, in some extractable comment (e.g., doxygen), what the arguments are and what the function does. Why does this data member exist, what does it contain, and is the value in meters, feet, or furlongs? That too is another subject for (extractable) comments exist.
Oct
7
comment What code lays behind C++ exception?
-1. There are a number of things wrong with this answer. The biggest is that very few (if any!) implementations use the execution stack for exception handling. Exceptions are supposed to be exceptional -- i.e., they are presumably rare. Adding all that exception handling baggage to the stack would slow down every call, every return, and for very little gain. Most implementations use a completely distinct area than the stack for throwing and catching exceptions.
Oct
5
answered What code lays behind C++ exception?
Oct
4
comment Why doesn't Python just establish a format for declaring tab widths?
Set up your editor / IDE so it accepts your tabs as input but immediately converts them to the right number of spaces.
Oct
1
comment Can compilers check whether certain axioms hold for a user defined type?
@ScarletAmaranth - Re is it possible to perform such checks in all scenarios? No. It's an undecidable problem, the en.wikipedia.org/wiki/Entscheidungsproblem .
Sep
27
answered Can compilers check whether certain axioms hold for a user defined type?
Sep
9
comment Interview question “What is virtual function”
@ThiagoSilva - I would call what you are doing an "error", not "overriding". It is an illegal error in my world. Code that doesn't compile clean with a boatload of warnings options enabled needs a project waiver. Overriding a non-virtual function gets a compiler warning for hiding the parent class method, and that warning is not going to get a waiver any time soon.
May
31
awarded  Yearling
May
17
answered Ensuring that headers are explicitly included in CPP file
Feb
13
answered Detecting misusage of delete[] vs. delete at compile time
Jan
25
answered Branch vs decision coverage question
Jan
12
answered What are the pros and cons of Inter process communication done via sockets vs shared memory?
Dec
17
comment Should developers be responsible for tests other than unit tests, if so which ones are the most common?
It is your responsibility to deliver defect-free code. I disagree. Not strongly enough to deserve a down-vote, but I do disagree. This is an unattainable goal for a project of any reasonable size. In a big project (millions of lines of code), there will always be bugs. Some of these will be known but accepted bugs, but there are always undetected bugs lurking about in the code base. A software defect rate of 0.01 errors/KSLOC is absolutely stellar and is incredibly expensive to attain.
Dec
7
comment Separating merged array of arithmetic and geometric series
This question also is at stackoverflow.com : stackoverflow.com/questions/13758977/… .