|
It's easy. I can make better bugs in my code than you can. Sort of like the universe enhances fools every time I manage to program something foolproof.
CQ de W5ALT
Walt Fair, Jr., P. E.
Comport Computing
Specializing in Technical Engineering Software
|
|
|
|
|
Of course, variables changed, methods renamed, and parameters omitted to protect the (not so) innocent.
if (condition_a)
{
if (condition_b)
{
if (AlertBox("Something wrong here. You wanna continue?"))
{
CheckAvailability();
}
}
else if (condition_c)
{
if (AlertBox("Some other thing wrong here. You wanna continue?"))
{
CheckAvailability();
}
}
else
{
CheckAvailability();
}
CheckAvailability();
}
else
{
CheckAvailability();
}
modified 3-Mar-13 11:32am.
|
|
|
|
|
i like the path in which the availability gets checked twice
|
|
|
|
|
Looks like CheckAvailabilty() is void, and has to throw an Exception in case of non-availability.
Consequently, that call has to be wrapped:
try
{
CheckAvailability();
}
catch(Exception ex)
{
if (AlertBox("Some other thing wrong here. You wanna continue?"))
{
CheckAvailability();
}
}
You are right, that guy does not know how to do things correctly!
|
|
|
|
|
That just makes me angry..
|
|
|
|
|
REMOVED
Bob Dole The internet is a great way to get on the net.
2.0.82.7292 SP6a
modified 13-Mar-13 9:30am.
|
|
|
|
|
Of course it works.
|
|
|
|
|
I think it works be cause the constructor and initialization sections both return a reference to the newly constructed object. But trying to call another function at the end will not work since the show function does not return a reference to the object.
|
|
|
|
|
Do you get paycheck deductions every time you use a semicolon?
Epic misuse, IMHO.
"Bastards encourage idiots to use Oracle Forms, Web Forms, Access and a number of other dinky web publishing tolls.", Mycroft Holmes[ ^]
|
|
|
|
|
|
In that case, it works does not mean you should use it. This is totally unreadable at first. In the professional World, when any day you can be out of project(read job, as worst case) and some other poor sod has to maintain it, this is one of the things that leads to rants and posts in this very forum.
"Bastards encourage idiots to use Oracle Forms, Web Forms, Access and a number of other dinky web publishing tolls.", Mycroft Holmes[ ^]
|
|
|
|
|
I've just seen this wonderful comment in the "Other suggestions" section of one of our beautiful CPP-headers:
|
|
|
|
|
Oy vey. My monitor is only 1680x1050, whatever will I do?
Perhaps whoever wrote that doesn't know that we can choose the size of our text?
And I suspect he hasn't learned from the past.
|
|
|
|
|
PIEBALDconsult wrote: Oy vey. My monitor is only 1680x1050, whatever will I do?
Nothing. May I should have mentioned that the program runs on a closed environment with a fixed screen size? Which makes the comment just more useless
|
|
|
|
|
Marco Bertschi wrote: runs on a closed environment
What does that matter when we're talking about the code?
|
|
|
|
|
With closed environment like I mean: Even the screen size is predefined because the customer receives the medical diagnostic instrument with a built-in computer and a built-in screen which already has been defined in the requirements before a single line of code was written...
So it is not just logically a closed environemtn: It is physically close too.
|
|
|
|
|
|
Collin Jasnoch wrote: Until the customer requests a different screen size and your BD say "Sure no problem!"
They do not. This is medical business, changing something even if it is just a change at the monitor size does need a validation of the whole system and would cost millions.
But this restriction will fall down anyways with the next SW version. The app will finally become screen size-innocent.
|
|
|
|
|
I thought the original comment was about the source code. Meaning you (yes, you the programmer, not the customer) would not be able to see the entire line of code in your IDE if you were using a lower screen resolution.
Soren Madsen
"When you don't know what you're doing it's best to do it quickly" - Jase #DuckDynasty
|
|
|
|
|
But the specifics of output device have nothing to do with the format of the source code.
|
|
|
|
|
Wow, an update from 80x24 to 1920x1200, that's great!
Obviously, you had to give up MUMPS. Does your C++ code still resemble the original MUMPS code?
|
|
|
|
|
No. And it is not just C++ code. It once was pure C code
|
|
|
|
|
The guy's got a point, though. I'm looking at my code here (which is written according to received standards), and the rightmost 2/3 of my IDE's code editor is pure black, because the text is just in a tiny strip down the left.
|
|
|
|
|
Yeah! The stone age is over. However, non-superhumans get very confused when lines contain more than 60 characters.
|
|
|
|
|
this is so yesterday!
the new 1920x1200 is 1366x768
|
|
|
|