Go to Post There will inevitably be enough unintentional failure in any endeavor we take on that adding intentional failure on top of that seems unnecessary. - Jared Russell [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
Thread Tools Rate Thread Display Modes
  #16   Spotlight this post!  
Unread 26-02-2004, 19:55
Astronouth7303's Avatar
Astronouth7303 Astronouth7303 is offline
Why did I come back?
AKA: Jamie Bliss
FRC #4967 (That ONE Team)
Team Role: Mentor
 
Join Date: Jan 2004
Rookie Year: 2004
Location: Grand Rapids, MI
Posts: 2,071
Astronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud of
Re: Why I hate c

What do you mean by "single equality sign in a conditional"? Isn't = an assignment symbol?
  #17   Spotlight this post!  
Unread 26-02-2004, 20:21
telkanuru's Avatar
telkanuru telkanuru is offline
Generic Carbon Unit
#0246 (Overclocked)
Team Role: Engineer
 
Join Date: Feb 2004
Location: Amherst, MA
Posts: 27
telkanuru is an unknown quantity at this point
Send a message via AIM to telkanuru
Re: Why I hate c

Your inability to detect problems is in all likelyhood related to the self rather than the language. Personally, if I can't solve a C/C++ bug within 5-10 minutes, I ask someone who also knows it to look over the language, because they find things I miss. And good compilers do make a good deal of difference. Personally, I like C++ because I like object-oriented language, but C is better than visual whatever they were using before. You can do so much more with so much less. Plus, knowing it has broader practical applications.
__________________
"He who has cares also has brandy."
-Gothe

Murphey was an optimist.
  #18   Spotlight this post!  
Unread 26-02-2004, 20:36
Astronouth7303's Avatar
Astronouth7303 Astronouth7303 is offline
Why did I come back?
AKA: Jamie Bliss
FRC #4967 (That ONE Team)
Team Role: Mentor
 
Join Date: Jan 2004
Rookie Year: 2004
Location: Grand Rapids, MI
Posts: 2,071
Astronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud of
Re: Why I hate c

There's a way around that (sort of): Something I call "psuedo-objects". Basically, For each instance of the object, Copy the code and declarations and rename. And replace dots with underscores. Object_Procedure
  #19   Spotlight this post!  
Unread 26-02-2004, 21:19
velocipenguin velocipenguin is offline
Registered User
#0246 (Overclocked)
Team Role: Programmer
 
Join Date: Feb 2004
Location: Boston, MA
Posts: 77
velocipenguin is on a distinguished road
Send a message via AIM to velocipenguin
Re: Why I hate c

Quote:
Originally Posted by Astronouth7303
What do you mean by "single equality sign in a conditional"? Isn't = an assignment symbol?
By "equality sign", I meant "equals sign".
  #20   Spotlight this post!  
Unread 26-02-2004, 21:23
Astronouth7303's Avatar
Astronouth7303 Astronouth7303 is offline
Why did I come back?
AKA: Jamie Bliss
FRC #4967 (That ONE Team)
Team Role: Mentor
 
Join Date: Jan 2004
Rookie Year: 2004
Location: Grand Rapids, MI
Posts: 2,071
Astronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud of
Re: Why I hate c

I know that, but generally isn't "If (foo=42)" what one tries to avoid?
  #21   Spotlight this post!  
Unread 26-02-2004, 22:56
velocipenguin velocipenguin is offline
Registered User
#0246 (Overclocked)
Team Role: Programmer
 
Join Date: Feb 2004
Location: Boston, MA
Posts: 77
velocipenguin is on a distinguished road
Send a message via AIM to velocipenguin
Re: Why I hate c

Quote:
Originally Posted by Astronouth7303
I know that, but generally isn't "If (foo=42)" what one tries to avoid?
I think you missed the point.

The reason C compilers don't typically give warnings or errors for using the single equals sign inside a conditional is because it CAN be valid. In the code I posted, the single equals sign sets the address of a file handle, whose value needs to be inequal to zero in order to work. Yes, it's one of those annoying tricks used by programmers who like being clever (i.e. me), but my point is that it's valid and there's no reason the compiler should label it as a syntax error.
  #22   Spotlight this post!  
Unread 27-02-2004, 00:06
Ryan Cumings's Avatar
Ryan Cumings Ryan Cumings is offline
Programmer and University Rejected
#0134 (Team Discovery)
Team Role: Programmer
 
Join Date: Jan 2004
Rookie Year: 2000
Location: Pembroke, NH
Posts: 65
Ryan Cumings is an unknown quantity at this point
Send a message via AIM to Ryan Cumings
Re: Why I hate c

Some compilers will give you a warning if a condition will always be true or always be false.
__________________
Suddenly being rejected from college feels right during the build season. Now I am a mentor.
  #23   Spotlight this post!  
Unread 27-02-2004, 09:07
Andy Baker's Avatar Woodie Flowers Award
Andy Baker Andy Baker is offline
President, AndyMark, Inc.
FRC #3940 (CyberTooth)
Team Role: Engineer
 
Join Date: May 2001
Rookie Year: 1998
Location: Kokomo, Indiana
Posts: 3,416
Andy Baker has a reputation beyond reputeAndy Baker has a reputation beyond reputeAndy Baker has a reputation beyond reputeAndy Baker has a reputation beyond reputeAndy Baker has a reputation beyond reputeAndy Baker has a reputation beyond reputeAndy Baker has a reputation beyond reputeAndy Baker has a reputation beyond reputeAndy Baker has a reputation beyond reputeAndy Baker has a reputation beyond reputeAndy Baker has a reputation beyond repute
Send a message via AIM to Andy Baker
Re: Why I hate c

Off topic... but I gotta say...

Alan, you made a great program. While you were at work yesterday, we started making automodes. Your software system enabled us to create 5 workable automodes within about 6 hours. These are 5 modes that work, at least on our field.

The code was so clear that even I could tweak the numbers.

To the rest of you, get this: Alan was just an interested parent who attended meetings a few months ago. We needed some more talent in the software area and he rode in on his white horse and saved the day.

Thanks Alan!! Welcome to the craziness of FIRST!

Andy B.
  #24   Spotlight this post!  
Unread 27-02-2004, 09:45
Greg McCoy's Avatar
Greg McCoy Greg McCoy is offline
boiler up!
FRC #3940 (CyberTooth)
Team Role: Engineer
 
Join Date: Feb 2002
Rookie Year: 2002
Location: Kokomo, IN
Posts: 484
Greg McCoy has a reputation beyond reputeGreg McCoy has a reputation beyond reputeGreg McCoy has a reputation beyond reputeGreg McCoy has a reputation beyond reputeGreg McCoy has a reputation beyond reputeGreg McCoy has a reputation beyond reputeGreg McCoy has a reputation beyond reputeGreg McCoy has a reputation beyond reputeGreg McCoy has a reputation beyond reputeGreg McCoy has a reputation beyond reputeGreg McCoy has a reputation beyond repute
Send a message via AIM to Greg McCoy
Re: Why I hate c

I'm proud of Andy for working on the auto modes
  #25   Spotlight this post!  
Unread 27-02-2004, 10:27
Unsung FIRST Hero
JVN JVN is offline
@JohnVNeun
AKA: John Vielkind-Neun
FRC #0148 (Robowranglers)
Team Role: Engineer
 
Join Date: May 2001
Rookie Year: 2000
Location: Greenville, Tx
Posts: 3,159
JVN has a reputation beyond reputeJVN has a reputation beyond reputeJVN has a reputation beyond reputeJVN has a reputation beyond reputeJVN has a reputation beyond reputeJVN has a reputation beyond reputeJVN has a reputation beyond reputeJVN has a reputation beyond reputeJVN has a reputation beyond reputeJVN has a reputation beyond reputeJVN has a reputation beyond repute
Re: Why I hate c

Quote:
Originally Posted by Andy Baker
The code was so clear that even I could tweak the numbers.
Andy--
That is... of the dark side of the force... forever will it dominate your destiny.
Baker is now tainted goods....


Remember kids:
Do not fall to the Spark Side.

Gearboxes are more fun.

John
__________________
In the interest of full disclosure: I work for VEX Robotics a subsidiary of Innovation First International (IFI) Crown Supplier & Proud Supporter of FIRST
  #26   Spotlight this post!  
Unread 27-02-2004, 11:47
Steve Shade Steve Shade is offline
Registered User
no team
Team Role: Engineer
 
Join Date: Jun 2001
Rookie Year: 1999
Location: Pasadena, MD
Posts: 78
Steve Shade has much to be proud ofSteve Shade has much to be proud ofSteve Shade has much to be proud ofSteve Shade has much to be proud ofSteve Shade has much to be proud ofSteve Shade has much to be proud ofSteve Shade has much to be proud ofSteve Shade has much to be proud ofSteve Shade has much to be proud of
Re: Why I hate c

Quote:
Originally Posted by JVN
Andy--
That is... of the dark side of the force... forever will it dominate your destiny.
Baker is now tainted goods....


Remember kids:
Do not fall to the Spark Side.

Gearboxes are more fun.

John
John:

Sooner or later you will learn that you can't resist the natrual urge to become one of us. We have Baker now, and you're next! *evil laugh*

Seriously, isn't C much nicer because now you Gearheads no longer have an excuse about not understanding the basic operations of the language?


Steve
  #27   Spotlight this post!  
Unread 01-03-2004, 16:59
jeremy562 jeremy562 is offline
Engineer
#0562 (SPARK 562)
 
Join Date: Feb 2002
Location: Fitchburg, MA
Posts: 74
jeremy562 is an unknown quantity at this point
Send a message via AIM to jeremy562
Re: Why I hate c

Quote:
Originally Posted by Steve Shade
John:

Sooner or later you will learn that you can't resist the natrual urge to become one of us. We have Baker now, and you're next! *evil laugh*

Seriously, isn't C much nicer because now you Gearheads no longer have an excuse about not understanding the basic operations of the language?


Steve
I am very glad to be using C this year instead of P-BASIC. Of course, I use C++ all the time so going into C mode is a lot easier for me than BASIC...
__________________
SPARK 562: Students Pursuing Applied Robotics Knowledge

2006 BAE Granite State Regional: Finalists with 319 and 176
2006 BAE Granite State Regional: Winners of Motorola Quality Award
2004 BAE Granite State Regional: 7th Seed
2004 Mayhem on the Merrimack Champions! Thanks, 61 and 1289!
  #28   Spotlight this post!  
Unread 01-03-2004, 17:40
jacob_dilles's Avatar
jacob_dilles jacob_dilles is offline
Registered User
AKA: theshadow
FRC #0620 (WarBots)
Team Role: Mentor
 
Join Date: Jan 2003
Rookie Year: 2003
Location: Vienna, VA
Posts: 245
jacob_dilles will become famous soon enough
Send a message via AIM to jacob_dilles
Re: Why I hate c

Quote:
Originally Posted by jeremy562
I am very glad to be using C this year instead of P-BASIC. Of course, I use C++ all the time so going into C mode is a lot easier for me than BASIC...
and more inportantly, C is real world. basic is fine for playing around with little tabletop robots, but to do anything with anything in the real world of embeded prossesers, C is the standerd.
__________________
--------------------------
"You're not a real programmer until all your sentences end with semicolons;"
  #29   Spotlight this post!  
Unread 01-03-2004, 17:56
Astronouth7303's Avatar
Astronouth7303 Astronouth7303 is offline
Why did I come back?
AKA: Jamie Bliss
FRC #4967 (That ONE Team)
Team Role: Mentor
 
Join Date: Jan 2004
Rookie Year: 2004
Location: Grand Rapids, MI
Posts: 2,071
Astronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud of
Re: Why I hate c

Not to mention PCs, which may have a bigger market than embedded systems; C++ is the standard there, too (Though VB is good for a quick dev, I made a program in 10 minutes in VB).
  #30   Spotlight this post!  
Unread 07-03-2004, 22:19
jhnphm jhnphm is offline
Registered User
#0614
Team Role: Programmer
 
Join Date: Mar 2004
Rookie Year: 2003
Location: Fairfax, VA
Posts: 23
jhnphm is an unknown quantity at this point
Re: Why I hate c

Quote:
Originally Posted by Astronouth7303
There's a way around that (sort of): Something I call "psuedo-objects". Basically, For each instance of the object, Copy the code and declarations and rename. And replace dots with underscores. Object_Procedure
Why? What's wrong with type_procedure(structure,parameters)?
Closed Thread


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
I Hate It When... sanddrag Chit-Chat 77 25-12-2003 10:57
I hate the BCS and i really ha te KANSAS ST. Jon Reese Chit-Chat 10 11-12-2003 12:09
GRRr.... I hate webpages... XRaVeNX Chit-Chat 4 15-03-2002 12:28
Why I hate Logic EnderofDragon Chit-Chat 2 19-02-2002 21:02


All times are GMT -5. The time now is 22:57.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi