Comment On The Interface

"I was (once again) re-assigned to another old project for upkeep 'n such," Johnny D writes, "and as it so happened, there was a bug. " [expand full text]
« PrevPage 1 | Page 2 | Page 3 | Page 4 | Page 5Next »

Re: The Interface

2011-02-23 10:39 • by Power Troll (unregistered)
338843 in reply to 338842
boog (imposting poster):
It looks like more work from this guy. But today's code appears to be a step up from the other method. That is, at least he's not using a case statement.

That we can see.

Duh, it's the same guy. That's why their both named Brian.

Re: The Interface

2011-02-23 10:40 • by boog
338844 in reply to 338822
boog (defective copy):
I'm pretty sure I would have strangled the penguin before I got to the 4th NULL.
You should tuck in your lack of creativity, my empty-headed emulator, before others see it.

Re: The Interface

2011-02-23 10:41 • by Olivier (unregistered)
I think my brain just turned itself inside out. Can anyone else see a possible justification for this? The only valid use I know of for arrays of func ptrs is a (fixed sized) list of callbacks.

Re: The Interface

2011-02-23 10:41 • by by (unregistered)
Everytime someone writes terrible code like this, a little kitty dies...

The code says it perfectly -> };

I would cry too.

Re: The Interface

2011-02-23 10:41 • by Grown Man with a Van (unregistered)
Hey, how come they don't do featured comments anymore?

Re: The Interface

2011-02-23 10:42 • by Bobbo (unregistered)
338848 in reply to 338811
Migala:
MadX:
Whoa, Nully.


+1. Was just listening to her (not that album, but still).


+2! Make that a Featured Comment please..

Re: The Interface

2011-02-23 10:42 • by by (unregistered)
338849 in reply to 338847
Grown Man with a Van:
Hey, how come they don't do featured comments anymore?


Because nobody writes anything funny anymore. That, or it's a big conspiracy.

Re: The Interface

2011-02-23 10:43 • by by by's sock puppet (unregistered)
338850 in reply to 338846
by:
Everytime someone writes terrible code like this, a little kitty dies...

The code says it perfectly -> };

I would cry too.

In that case, it would be an excellent app for the Animal Control Organizations of America.

Also a wonderful way to control a "catsplosion" in Dwarf Fortress

Re: The Interface

2011-02-23 10:46 • by Nagesh
338852 in reply to 338837
#TDWTFMafia #SOMafia:
Nagesh:
Shiva:
Nagesh:
boog:
I'm pretty sure I would have strangled the penguin before I got to the 4th NULL.


What is strangling the penguin? Is this a BATMAN reference?

Nagesh, dude, someone hacked your account yesterday.


Idiot,
Nobody has hacked my account. THere's one stalkher I have acquired, who insists on using my good name.




One? We are legion and the coolest!


Why???????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????

Please do not reply with "WHY NOT".

Re: The Interface

2011-02-23 10:46 • by boog
338853 in reply to 338847
Grown Man with a Van:
Hey, how come they don't do featured comments anymore?
So you're suggesting there have been comments worth featuring?

Interesting...

Re: The Interface

2011-02-23 10:48 • by by (unregistered)
338854 in reply to 338852
Nagesh:
#TDWTFMafia #SOMafia:
Nagesh:
Shiva:
Nagesh:
boog:
I'm pretty sure I would have strangled the penguin before I got to the 4th NULL.


What is strangling the penguin? Is this a BATMAN reference?

Nagesh, dude, someone hacked your account yesterday.


Idiot,
Nobody has hacked my account. THere's one stalkher I have acquired, who insists on using my good name.




One? We are legion and the coolest!


Why???????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????

Please do not reply with "WHY NOT".



What the hell are you guys talking about? TDWTF used to be funny, turned trolling, turned to whatever the hell this is...

I can't really complain though because I'm still here reading and commenting.

Re: The Interface

2011-02-23 10:49 • by Dr. Pepper (unregistered)
338855 in reply to 338845
Olivier:
I think my brain just turned itself inside out. Can anyone else see a possible justification for this? The only valid use I know of for arrays of func ptrs is a (fixed sized) list of callbacks.

I was just thinking about implementing something like this for a genetic programming project I'm doing. I'm thinking of putting binary operators/functions in a sparse matrix with the dimensions of the inputs vector. Instead of doing normal matrix x vector multiplication, I will chain the operations, using the result as an input to the next function. The result will be a vector which can be submitted to a fitting function. Of course my array will be dynamic and nulled by a loop, but I think that I could create an arbitrary means of creating genetic solutions in this fashion

Re: The Interface

2011-02-23 10:50 • by backForMore (unregistered)
Now I understand Toyota's sudden acceleration problem.

Re: The Interface

2011-02-23 10:53 • by by (unregistered)
338858 in reply to 338854
by:
Nagesh:
#TDWTFMafia #SOMafia:
Nagesh:
Shiva:
Nagesh:
boog:
I'm pretty sure I would have strangled the penguin before I got to the 4th NULL.


What is strangling the penguin? Is this a BATMAN reference?

Nagesh, dude, someone hacked your account yesterday.


Idiot,
Nobody has hacked my account. THere's one stalkher I have acquired, who insists on using my good name.




One? We are legion and the coolest!


Why???????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????

Please do not reply with "WHY NOT".



What the hell are you guys talking about? TDWTF used to be funny, turned trolling, turned to whatever the hell this is...

I can't really complain though because I'm still here reading and commenting.

Especially, considering you're a troll yourself, having hijacked my handle from a featured comment from months ago.

No, Askimet, a link back to the host site is not spam.

Re: The Interface

2011-02-23 10:57 • by HellKarnassus
338859 in reply to 338822
boog:
I'm pretty sure I would have strangled the penguin before I got to the 4th NULL.

I would have strangled it when I saw the first {

Re: The Interface

2011-02-23 11:05 • by NOT the original, ORIGINAL by (unregistered)
338861 in reply to 338858
by:
by:
Nagesh:
#TDWTFMafia #SOMafia:
Nagesh:
Shiva:
Nagesh:
boog:
I'm pretty sure I would have strangled the penguin before I got to the 4th NULL.


What is strangling the penguin? Is this a BATMAN reference?

Nagesh, dude, someone hacked your account yesterday.


Idiot,
Nobody has hacked my account. THere's one stalkher I have acquired, who insists on using my good name.




One? We are legion and the coolest!


Why???????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????

Please do not reply with "WHY NOT".



What the hell are you guys talking about? TDWTF used to be funny, turned trolling, turned to whatever the hell this is...

I can't really complain though because I'm still here reading and commenting.

Especially, considering you're a troll yourself, having hijacked my handle from a featured comment from months ago.

No, Askimet, a link back to the host site is not spam.


LOL, really? That's funny... No, sorry, you're not clever enough to emulate, though I'm sure you keep that featured comment badge close to your heart. I honestly just didn't realize.

Re: The Interface

2011-02-23 11:08 • by Jake (unregistered)
Obviously the new programmer just isn't as clever as the old programmer.

Whether clever programmers should be allowed to live... well that's a whole separate discussion.

Re: The Interface

2011-02-23 11:11 • by Silfax
338863 in reply to 338808
allen-poole.com:
Layers just makes me think of Shrek

An ogre is like an onion.
They stink?
Yes... NO!
Oh, they make you cry?
No!
Oh, you leave 'em out in the sun, they get all brown, start sproutin' little white hairs...
NO! Layers. Onions have layers. Ogres have layers. Onions have layers. You get it? We both have layers.


Well it is an ogre of a problem.

Re: The Interface

2011-02-23 11:11 • by History Major (unregistered)
338864 in reply to 338854
I think it all started back in August which, ironically, featured a troll. If we were to play hangman, I would hope you could fill in the blanks:

_ _ r t
_ _ _ _ _ t r _ _

(by the way, if you can't figure out who I'm referring to, you should go away and grow up ;)

[to be continued, based on Askimet censorship]

Re: The Interface

2011-02-23 11:12 • by History Major (unregistered)
338865 in reply to 338864
History Major:
I think it all started back in August which, ironically, featured a troll. If we were to play hangman, I would hope you could fill in the blanks:

_ _ r t
_ _ _ _ _ t r _ _

(by the way, if you can't figure out who I'm referring to, you should go away and grow up ;)

[to be continued, based on Askimet censorship]


Day after day, BG (as we'll call him), would comment using the same exact form as stated in the original article, not doubt getting the same amount of glee and fulfillment as the guy originally mentioned in the story. After a while, the moderators with no explanation started deleting posts. One would rationally conclude they decided "enough is enough."

As normally is the case, this did not stop the problem. The enraged troll kept it up, and the volume of posts, along with misspelled versions indicated that other trolls were joining his cause against "oppression" and "censorship". Posts kept vanishing, and the troll found more and more clever ways to fly below the moderators' radar. Soon posts with a simple reference to "wooden tables" or "embedded systems" would vanish, driving more trolls to his cause.

The mods haven't studied history. The best way to eliminate trolls is to ignore them, plain and simple. Just like violence in Afghanistan, you're just going to recruit more soldiers by deleting posts. Just like an improperly-applied anti-biotic, you are going to make the trolls more clever if you sometimes delete posts and sometimes don't.

While I enjoyed the ride, I do not like how those with intelligence now use it for evil instead of valid comments. Be wise, gentlemen.

Re: The Interface

2011-02-23 11:13 • by Behold (unregistered)
Interestingly, this is pretty much how you write Python modules in C (that is, bindings to C code for Python). Except I think the array is even larger there.

Re: The Interface

2011-02-23 11:15 • by Matt Westwood (unregistered)
338867 in reply to 338865
History Major:
History Major:
I think it all started back in August which, ironically, featured a troll. If we were to play hangman, I would hope you could fill in the blanks:

_ _ r t
_ _ _ _ _ t r _ _

(by the way, if you can't figure out who I'm referring to, you should go away and grow up ;)

[to be continued, based on Askimet censorship]


Day after day, BG (as we'll call him), would comment using the same exact form as stated in the original article, not doubt getting the same amount of glee and fulfillment as the guy originally mentioned in the story. After a while, the moderators with no explanation started deleting posts. One would rationally conclude they decided "enough is enough."

As normally is the case, this did not stop the problem. The enraged troll kept it up, and the volume of posts, along with misspelled versions indicated that other trolls were joining his cause against "oppression" and "censorship". Posts kept vanishing, and the troll found more and more clever ways to fly below the moderators' radar. Soon posts with a simple reference to "wooden tables" or "embedded systems" would vanish, driving more trolls to his cause.

The mods haven't studied history. The best way to eliminate trolls is to ignore them, plain and simple. Just like violence in Afghanistan, you're just going to recruit more soldiers by deleting posts. Just like an improperly-applied anti-biotic, you are going to make the trolls more clever if you sometimes delete posts and sometimes don't.

While I enjoyed the ride, I do not like how those with intelligence now use it for evil instead of valid comments. Be wise, gentlemen.


Add another factor: the addition of Askimet, which is extremely badly broken.

Re: The Interface

2011-02-23 11:18 • by Abso (unregistered)
338868 in reply to 338865
History Major:
Just like an improperly-applied anti-biotic, you are going to make the trolls more clever if you sometimes delete posts and sometimes don't.

Perhaps that's the plan? If they were more clever, they'd be less annoying.

Re: I learned it by watching you

2011-02-23 11:25 • by IRC is 1337 (unregistered)
338869 in reply to 338852
Nagesh:
#TDWTFMafia #SOMafia:
Nagesh:
Shiva:
Nagesh:
boog:
I'm pretty sure I would have strangled the penguin before I got to the 4th NULL.


What is strangling the penguin? Is this a BATMAN reference?

Nagesh, dude, someone hacked your account yesterday.


Idiot,
Nobody has hacked my account. THere's one stalkher I have acquired, who insists on using my good name.




One? We are legion and the coolest!


Why???????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????

Please do not reply with "WHY NOT".



Why ask why?

Re: The Interface

2011-02-23 11:26 • by History Major (unregistered)
338870 in reply to 338868
Abso:
History Major:
Just like an improperly-applied anti-biotic, you are going to make the trolls more clever if you sometimes delete posts and sometimes don't.

Perhaps that's the plan? If they were more clever, they'd be less annoying.

More clever = more difficult to detect. Apparently, you are only able to detect the less clever ones. The other side is the individual who marks a legitimate post as a "troll post". This, incidentally, can result in conversion to a troll or lack of desire to post anything.

Re: The Interface

2011-02-23 11:28 • by frits is DEADBEEF (unregistered)
338871 in reply to 338865
History Major:
History Major:
I think it all started back in August which, ironically, featured a troll. If we were to play hangman, I would hope you could fill in the blanks:

_ _ r t
_ _ _ _ _ t r _ _

(by the way, if you can't figure out who I'm referring to, you should go away and grow up ;)

[to be continued, based on Askimet censorship]


Day after day, BG (as we'll call him), would comment using the same exact form as stated in the original article, not doubt getting the same amount of glee and fulfillment as the guy originally mentioned in the story. After a while, the moderators with no explanation started deleting posts. One would rationally conclude they decided "enough is enough."

As normally is the case, this did not stop the problem. The enraged troll kept it up, and the volume of posts, along with misspelled versions indicated that other trolls were joining his cause against "oppression" and "censorship". Posts kept vanishing, and the troll found more and more clever ways to fly below the moderators' radar. Soon posts with a simple reference to "wooden tables" or "embedded systems" would vanish, driving more trolls to his cause.

The mods haven't studied history. The best way to eliminate trolls is to ignore them, plain and simple. Just like violence in Afghanistan, you're just going to recruit more soldiers by deleting posts. Just like an improperly-applied anti-biotic, you are going to make the trolls more clever if you sometimes delete posts and sometimes don't.

While I enjoyed the ride, I do not like how those with intelligence now use it for evil instead of valid comments. Be wise, gentlemen.


The constant trolling by a few "cool" kids turn even the most well-meaning participators in trolls.

Re: The Interface

2011-02-23 11:30 • by The Corrector (unregistered)
338872 in reply to 338871
frits is DEADBEEF:

The constant trolling by a few "cool" kids turn even the most well-meaning participators into trolls.

Re: The Interface

2011-02-23 11:30 • by RickD (unregistered)
338873 in reply to 338865
The best way to eliminate trolls is to ignore them, plain and simple.

Actually, the best way to eliminate trolls is to have a system where moderators tag the troll posts and the system hides the tagged posts from everyone but the poster. The trolls don't realize they've been moderated, they just see that nobody is taking their bait. Eventually they go away because it's no fun for them.

The downside is you have to require registration and logon to read posts.

Re: The Interface

2011-02-23 11:33 • by frits (unregistered)
338874 in reply to 338865
History Major:
History Major:
I think it all started back in August which, ironically, featured a troll. If we were to play hangman, I would hope you could fill in the blanks:

_ _ r t
_ _ _ _ _ t r _ _

(by the way, if you can't figure out who I'm referring to, you should go away and grow up ;)

[to be continued, based on Askimet censorship]


Day after day, BG (as we'll call him), would comment using the same exact form as stated in the original article, not doubt getting the same amount of glee and fulfillment as the guy originally mentioned in the story. After a while, the moderators with no explanation started deleting posts. One would rationally conclude they decided "enough is enough."

As normally is the case, this did not stop the problem. The enraged troll kept it up, and the volume of posts, along with misspelled versions indicated that other trolls were joining his cause against "oppression" and "censorship". Posts kept vanishing, and the troll found more and more clever ways to fly below the moderators' radar. Soon posts with a simple reference to "wooden tables" or "embedded systems" would vanish, driving more trolls to his cause.

The mods haven't studied history. The best way to eliminate trolls is to ignore them, plain and simple. Just like violence in Afghanistan, you're just going to recruit more soldiers by deleting posts. Just like an improperly-applied anti-biotic, you are going to make the trolls more clever if you sometimes delete posts and sometimes don't.

While I enjoyed the ride, I do not like how those with intelligence now use it for evil instead of valid comments. Be wise, gentlemen.

Who hasn't posted an article like this?

Re: The Interface

2011-02-23 11:37 • by History Major (unregistered)
338875 in reply to 338873
RickD:
The best way to eliminate trolls is to ignore them, plain and simple.

Actually, the best way to eliminate trolls is to have a system where moderators tag the troll posts and the system hides the tagged posts from everyone but the poster. The trolls don't realize they've been moderated, they just see that nobody is taking their bait. Eventually they go away because it's no fun for them.

The downside is you have to require registration and logon to read posts.

This system is fatally flawed because trolling is tricky to detect. To wit, I think there is an internet law about how sarcasm and trolling are indistinguishable.

Re: The Interface

2011-02-23 11:40 • by Maurits
338876 in reply to 338873
RickD:
the best way to eliminate trolls is to have a system where moderators tag the troll posts and the system hides the tagged posts from everyone but the poster. The trolls don't realize they've been moderated...


Unless they have backup "lurker" account.

Re: The Interface

2011-02-23 11:42 • by serguey123 (unregistered)
338877 in reply to 338875
History Major:
RickD:
The best way to eliminate trolls is to ignore them, plain and simple.

Actually, the best way to eliminate trolls is to have a system where moderators tag the troll posts and the system hides the tagged posts from everyone but the poster. The trolls don't realize they've been moderated, they just see that nobody is taking their bait. Eventually they go away because it's no fun for them.

The downside is you have to require registration and logon to read posts.

This system is fatally flawed because trolling is tricky to detect. To wit, I think there is an internet law about how sarcasm and trolling are indistinguishable.

Wouldn't sarcasm with a deadpan delivery be considered the equivalent to trolling IRL?

Re: The Interface

2011-02-23 11:46 • by Abso (unregistered)
338878 in reply to 338870
History Major:
Abso:
History Major:
Just like an improperly-applied anti-biotic, you are going to make the trolls more clever if you sometimes delete posts and sometimes don't.

Perhaps that's the plan? If they were more clever, they'd be less annoying.

More clever = more difficult to detect. Apparently, you are only able to detect the less clever ones. The other side is the individual who marks a legitimate post as a "troll post". This, incidentally, can result in conversion to a troll or lack of desire to post anything.

History Major:

This system is fatally flawed because trolling is tricky to detect. To wit, I think there is an internet law about how sarcasm and trolling are indistinguishable.

It's not so much that they get harder to detect as that I enjoy sarcasm, so when the trolls edge closer to the thin sarcasm-trolling line, I find them less annoying.

I suppose I could probably detect the more clever/less annoying trolls if I put more thought into it, but if they don't annoy me, then I don't care.

Re: The Interface

2011-02-23 11:50 • by History Major (unregistered)
338879 in reply to 338878
Abso:
History Major:
Abso:
History Major:
Just like an improperly-applied anti-biotic, you are going to make the trolls more clever if you sometimes delete posts and sometimes don't.

Perhaps that's the plan? If they were more clever, they'd be less annoying.

More clever = more difficult to detect. Apparently, you are only able to detect the less clever ones. The other side is the individual who marks a legitimate post as a "troll post". This, incidentally, can result in conversion to a troll or lack of desire to post anything.

History Major:

This system is fatally flawed because trolling is tricky to detect. To wit, I think there is an internet law about how sarcasm and trolling are indistinguishable.

It's not so much that they get harder to detect as that I enjoy sarcasm, so when the trolls edge closer to the thin sarcasm-trolling line, I find them less annoying.

I suppose I could probably detect the more clever/less annoying trolls if I put more thought into it, but if they don't annoy me, then I don't care.

Until you have a valid insite, and its marked as trolling or its buried in troll responses.

Re: The Interface

2011-02-23 11:52 • by b-redeker (unregistered)
338880 in reply to 338876
Maurits:
RickD:
the best way to eliminate trolls is to have a system where moderators tag the troll posts and the system hides the tagged posts from everyone but the poster. The trolls don't realize they've been moderated...


Unless they have backup "lurker" account.


Who doesn't have one of these?

Re: The Interface

2011-02-23 11:53 • by pjt33
338881 in reply to 338832
Steve The Cynic:
whatamess:
Seriously, anyone who thinks there isn't something inherently wrong with this code should change profession... you are hurting the industry!

These days I wouldn't *do* it that way, but on the grand scale of things, it is far from the worst possible WTF.

It's not up there with the clbuttics, but it's the kind of unmaintainable code that makes a fed up maintainer think of posting to the DailyWTF. Having to count the NULLs to check that functions are in the right positions is not fun. It's fundamentally another form of magic number.

Re: The Interface

2011-02-23 11:53 • by Skip (unregistered)
TRWTF here is that someone who would write this:

"Apparently, this structure is essential for passing information to other layers. Now if I only knew how it's supposed to do that..."

Was allowed to work on the project at all, and not sent to do some vb6 or javascript or something. Someone really should have said, "step away from the c compiler slowly, and nobody will get hurt". It shouldn't have to be said, but evidently I guess it has to be. A requirement for working on ancient c embedded systems is the ability to read c. This isn't even particularly complex c at that, it's just a normal vtable implementation. This is part of the piece of code that handles input from a hardware device. That device almost certainly is sending a packet of data where the first byte is an opcode, then two bytes indicating the length of data, then the data, and then probably a checksum. The code reading the data in from the port sanitizes it and calls the correct handler.

This isn't difficult stuff, and the only very, very small potential WTF here is using NULL instead of a dummy function that just returns, but I can think of several reasons off of the top of my head for not doing that. The input could be sanitized elsewhere, this could be essentially a 'subclass' vtable, many other possiblities.

Re: The Interface

2011-02-23 11:54 • by digghater (unregistered)
338883 in reply to 338875
History Major:
RickD:
The best way to eliminate trolls is to ignore them, plain and simple.

Actually, the best way to eliminate trolls is to have a system where moderators tag the troll posts and the system hides the tagged posts from everyone but the poster. The trolls don't realize they've been moderated, they just see that nobody is taking their bait. Eventually they go away because it's no fun for them.

The downside is you have to require registration and logon to read posts.

This system is fatally flawed because trolling is tricky to detect. To wit, I think there is an internet law about how sarcasm and trolling are indistinguishable.

But please, dear god, do not put in a system like Digg, where every comment section turns into an exercise of groupthink.

Re: The Interface

2011-02-23 12:02 • by boog (unregistered)
338884 in reply to 338883
digghater:
History Major:
RickD:
The best way to eliminate trolls is to ignore them, plain and simple.

Actually, the best way to eliminate trolls is to have a system where moderators tag the troll posts and the system hides the tagged posts from everyone but the poster. The trolls don't realize they've been moderated, they just see that nobody is taking their bait. Eventually they go away because it's no fun for them.

The downside is you have to require registration and logon to read posts.

This system is fatally flawed because trolling is tricky to detect. To wit, I think there is an internet law about how sarcasm and trolling are indistinguishable.

But please, dear god, do not put in a system like Digg, where every comment section turns into an exercise of groupthink.

I would digg this comment if I could.

Re: The Interface

2011-02-23 12:03 • by Skip (unregistered)
338885 in reply to 338881
pjt33:
Having to count the NULLs to check that functions are in the right positions is not fun. It's fundamentally another form of magic number.


Sigh. There are 255 of them. 10 per line. Can you count to 10? What would you have them do? something like, in code, assign:

SID[OP_START_DIAGNOSTIC] = &start_diagnostic_session;

etc.? That's a really bad idea, because it's wasted space on a system where you're very likely counting bytes to fit all the code and data on a very small ROM, and it's simply unneeded. If this kind of thing bothers you, stay the heck away from embedded systems.

Re: The Interface

2011-02-23 12:05 • by NOT the original, ORIGINAL by (unregistered)
338886 in reply to 338885
Skip:
pjt33:
Having to count the NULLs to check that functions are in the right positions is not fun. It's fundamentally another form of magic number.


Sigh. There are 255 of them. 10 per line. Can you count to 10? What would you have them do? something like, in code, assign:

SID[OP_START_DIAGNOSTIC] = &start_diagnostic_session;

etc.? That's a really bad idea, because it's wasted space on a system where you're very likely counting bytes to fit all the code and data on a very small ROM, and it's simply unneeded. If this kind of thing bothers you, stay the heck away from embedded systems.


You posted twice, and have yet to tell people to stay the hell off your lawn... I'm quite disappointed, I must say.

Re: The Interface

2011-02-23 12:12 • by El Jefe (unregistered)
338887 in reply to 338885
Skip:
pjt33:
Having to count the NULLs to check that functions are in the right positions is not fun. It's fundamentally another form of magic number.


Sigh. There are 255 of them. 10 per line. Can you count to 10? What would you have them do? something like, in code, assign:

SID[OP_START_DIAGNOSTIC] = &start_diagnostic_session;

etc.? That's a really bad idea, because it's wasted space on a system where you're very likely counting bytes to fit all the code and data on a very small ROM, and it's simply unneeded. If this kind of thing bothers you, stay the heck away from embedded systems.


*Shudder*
That line of code reminds me of an application I used to maintain. The codebase had several thousand lines of code like that in many different constructors. This particular application also had a C++ header file that had over 40,000 line of code. That file had the full inline implmentation code for something like 250 subclasses. Just thinking about that monstrocity makes me want a drink...

Re: The Interface

2011-02-23 12:23 • by hoodaticus
I do this same thing in C#. After all, the simplicity of using lambda expressions is made even more simple by passing them around in giant STRUCTS. I dump every lambda I need into a struct and just pass it around everywhere.

Re: The Interface

2011-02-23 12:23 • by Yuppie (unregistered)
338892 in reply to 338806
Nagesh:
Inside each small problem is a bigger one waiting to get out.


Kind of like a reverse matryoshka doll from an evil parallel universe.

Yes I did write that code in the Starbucks built on top of an ancient Native American burial ground ... why do you ask?

Re: The Interface

2011-02-23 12:25 • by Myself (unregistered)
So TRWTF is... actually, nope, the WTF IS TRWTF.

Re: The Interface

2011-02-23 12:26 • by boog
338894 in reply to 338884
boog (copycat):
I'm pretty sure I would digg this comment if I could.

FTFY

Re: The Interface

2011-02-23 12:27 • by NOT the original, ORIGINAL by (unregistered)
338895 in reply to 338891
hoodaticus:
I do this same thing in C#. After all, the simplicity of using lambda expressions is made even more simple by passing them around in giant STRUCTS. I dump every lambda I need into a struct and just pass it around everywhere.


I died a little inside reading that.

Re: The Interface

2011-02-23 12:29 • by The laughter of Children (unregistered)
338896 in reply to 338895
NOT the original, ORIGINAL by:
hoodaticus:
I do this same thing in C#. After all, the simplicity of using lambda expressions is made even more simple by passing them around in giant STRUCTS. I dump every lambda I need into a struct and just pass it around everywhere.


I died a little inside reading that.


I died laughing!

Re: The Interface

2011-02-23 12:35 • by NOT the original, ORIGINAL by (unregistered)
338897 in reply to 338896
The laughter of Children:
NOT the original, ORIGINAL by:
hoodaticus:
I do this same thing in C#. After all, the simplicity of using lambda expressions is made even more simple by passing them around in giant STRUCTS. I dump every lambda I need into a struct and just pass it around everywhere.


I died a little inside reading that.


I died laughing!


You just know someone is going to read that, and think that it's 'extensible', or that it's some kind of pattern...

Oh intertubes, you know not what power you yield over the minds of the uneducated, unwashed masses.

Re: The Interface

2011-02-23 12:37 • by boog
338898 in reply to 338806
Nagesh:
Inside each small problem is a bigger one waiting to get out.
And even when there isn't, the worst developers will try to solve it anyway.
« PrevPage 1 | Page 2 | Page 3 | Page 4 | Page 5Next »

Add Comment