- Feature Articles
- CodeSOD
- Error'd
- Forums
-
Other Articles
- Random Article
- Other Series
- Alex's Soapbox
- Announcements
- Best of…
- Best of Email
- Best of the Sidebar
- Bring Your Own Code
- Coded Smorgasbord
- Mandatory Fun Day
- Off Topic
- Representative Line
- News Roundup
- Editor's Soapbox
- Software on the Rocks
- Souvenir Potpourri
- Sponsor Post
- Tales from the Interview
- The Daily WTF: Live
- Virtudyne
Admin
Admin
Sorry... I better grab a coffee
Admin
The red hand is seconds. The white hand at about 5:50 is the alarm.
Admin
What are these "hands" of which you speak, and if they touch me, is it naughty?
Admin
Public Transport is cheaper than using your car because the powers that be understand it is inconvenient (and often unreliable) - so they need some incentive for you to use it. If you don't like it, either pay to use your car or walk...
There was a similar system locally at one stage that tried to estimate the next bus (I think the buses had GPS, and then the system would try to estimate how long it would take to get to a stop based on the running time of previous services). I was always amused to see the driver have to argue with nimrods who complained "But that sign still says you're 20 minutes away". One driver responded to such a comment with "And you are free to wait 20 minutes to see if another bus arrives."
Admin
Admin
Whoa! Tuesday
Admin
Programmers are lazy and don't program properly for errors to occur. Sometimes you are lucky if they handle them at all.
That most wonderful C++ library, the best one ever written by the most expert of programmers, so much so that everybody uses it... yes, I am referring to boost... is fairly guilty of that too.
The primary example of this I am referring to is lexical_cast, so much so that I made a conscious decision not to use it. It is intended to convert a string to a typed value. This is done through the iostream library so they create an istringstream then read in the string and see if it converts correctly. If the stream is in a "fail" state or if there are any surplus characters, this is deemed a failure.
The big issue is how it is handled if it fails. It simply throws an error "bad_cast". So you are parsing your big text file and somewhere or other you get "bad_cast".
Of course C++ exceptions don't come with any call-stack either so you can't see where you were in your code where it failed, never mind where you were in the text file you were parsing.
I found it no major issue to write my own that displayed a more meaningful message (using std::invalid_argument as the exception type) which gave a message such as
"error converting <whatever isn't a number> to an integer".
Admin
If you think that is bad, you have never worked with the ffmpeg/libav C API.
That one doesn't have self-documenting code, it has self-obfuscating code. And the error messages range between "I just crash now, bye" and "too verbose! stfu!".
Admin
Heh, now going on my fourth cup.
Admin
Ha! It's a catch-22, I'll need the design suite to get that house designed.
Admin
Putting the original due date on a bill printed after the due date is pretty common, and in fact proper as to not confuse the payer.
Admin
NaN NaN NaN NaN NaN NaN NaN NaN NaN NaN Batmaaaaan
Admin
FTFY. Everyone should be using ISO dates. American notation (month first, then day, then year) is just weird. Date components should be ordered by weight/significance, not by some weird artefact of the language it's pronounced in.
Admin
Admin
Admin
Icosober!! Get your conjugations right. God!