View Single Post
  #2   Spotlight this post!  
Unread 20-02-2006, 04:30
Matt Krass's Avatar
Matt Krass Matt Krass is offline
"Old" and Cranky. Get off my lawn!
AKA: Dark Ages
FRC #0263 (Sachem Aftershock)
Team Role: Mentor
 
Join Date: Oct 2002
Rookie Year: 2002
Location: Long Island, NY
Posts: 1,187
Matt Krass has a reputation beyond reputeMatt Krass has a reputation beyond reputeMatt Krass has a reputation beyond reputeMatt Krass has a reputation beyond reputeMatt Krass has a reputation beyond reputeMatt Krass has a reputation beyond reputeMatt Krass has a reputation beyond reputeMatt Krass has a reputation beyond reputeMatt Krass has a reputation beyond reputeMatt Krass has a reputation beyond reputeMatt Krass has a reputation beyond repute
Send a message via AIM to Matt Krass
Re: another compiler bug/oddity?

Quote:
Originally Posted by Rickertsen2
Omit the " at the end of the last include statement in a file and you get a rather strange error in which the compiler quotes a vast region of your code and then tells you there is an error on a seemingly random line.

ie: #include "something.h

If you do this with anything other than that last include statement, error but it is a little less convoluded.

This does not work with include statements that use <> style brackets.
How is that a bug? It's a programming mistake, you're telling the compiler to include vast amounts of, to the compiler, random data and its confusing the heck out of it. Blaming the compiler for your mistakes isn't a good thing, it could get you in trouble later.

I wouldn't call it an oddity, I'd call it an amusing response to a silly mistake, we all make them so it's not a big deal, just don't attribute them to the compiler, it's not there to clean up after you.
__________________
Matt Krass
If I suggest something to try and fix a problem, and you don't understand what I mean, please PM me!

I'm a FIRST relic of sorts, I remember when we used PBASIC and we got CH Flightsticks in the KoP. In my day we didn't have motorized carts, we pushed our robots uphill, both ways! (Houston 2003!)