RPGDXThe center of Indie-RPG gaming
Not logged in. [log in] [register]
 
Where can i get a good C++ compiler
 
Post new topic Reply to topic Goto page Previous  1, 2 
View previous topic - View next topic  
Author Message
TheHolyCatfish
Pretty, Pretty Fairy Princess


Joined: 21 Jul 2003
Posts: 8
Location: USA

PostPosted: Wed Jul 23, 2003 8:57 pm    Post subject: [quote]

so i should learn C also? are there any books on that that i can dl?
_________________
The catfish that likes to do pixel art!
Back to top  
TheHolyCatfish
Pretty, Pretty Fairy Princess


Joined: 21 Jul 2003
Posts: 8
Location: USA

PostPosted: Wed Jul 23, 2003 10:28 pm    Post subject: [quote]

yea i think i need to learn c first, could anyone point out any good books to get on C?
_________________
The catfish that likes to do pixel art!
Back to top  
Rainer Deyke
Demon Hunter


Joined: 05 Jun 2002
Posts: 672

PostPosted: Wed Jul 23, 2003 11:31 pm    Post subject: [quote]

Another book that teaches C++ is C++ in Action: Industrial-Strength Programming Techniques. It's available online, and does not require prior knowledge of C. The beginner C++ book most recommended by the experts is Accelerated C++, which also requires no prior knowledge of C but is not available online.

One thing to atch out for if you do learn C first is that many idioms in C are considered poor practice in C++. For example, manual memory management is inappropriate for C++, as is C-style string handling.
Back to top  
TheHolyCatfish
Pretty, Pretty Fairy Princess


Joined: 21 Jul 2003
Posts: 8
Location: USA

PostPosted: Thu Jul 24, 2003 12:16 am    Post subject: [quote]

sorry for the double post, i didnt see the other page. ok ill chek out the book
_________________
The catfish that likes to do pixel art!
Back to top  
BigManJones
Scholar


Joined: 22 Mar 2003
Posts: 196

PostPosted: Thu Jul 24, 2003 1:38 am    Post subject: [quote]

I found an case where Vis C++ 6.0 fell flat on its face recently; I had a class with an inner private struct an I couldn't compile the .cpp file for the class because some of the functions returned the private struct:

Code:

class binarysearchtree {
    private:
        struct node {
         ...
         };
     public:
         node *insert(node *, int);
    etc... rest of class
}

then in the .cpp

node *binarysearchtree::insert(node *root, int value)  {
...
}


Took me about 2 hours and some reading to figure that one out. The book I have said that most c++ compilers don't do very well when mixing language features.
Back to top  
LeoDraco
Demon Hunter


Joined: 24 Jun 2003
Posts: 584
Location: Riverside, South Cali

PostPosted: Mon Jul 28, 2003 8:20 am    Post subject: Re: Compilers and Libs [quote]

Jihgfed Pumpkinhead wrote:
Every once in a while I'll do a thorough run-through with MingW, re-compiling all my source (just in case my makefile is screwed up somewhere) with the -Wall option to make sure all my code is kosher.


Er, you do realize that -Wall does not enable all warnings that a gcc compiler can give you, right? If you really want to make sure that your code is kosher, you should try ridding what gcc complains about with -Weffc++ enabled.
_________________
"...LeoDraco is a pompus git..." -- Mandrake
Back to top  
DrunkenCoder
Demon Hunter


Joined: 29 May 2002
Posts: 559

PostPosted: Mon Jul 28, 2003 8:44 am    Post subject: [quote]

oh, and on the subject of kosher code... anyone know where to get a free lint?
_________________
If there's life after death there is no death, if there's no death we never live. | ENTP
Back to top  
Jihgfed Pumpkinhead
Stephen Hawking


Joined: 21 Jan 2003
Posts: 259
Location: Toronto, Canada

PostPosted: Sun Aug 03, 2003 8:24 pm    Post subject: Kosher Lint [quote]

LeoDraco wrote:
Er, you do realize that -Wall does not enable all warnings that a gcc compiler can give you, right? If you really want to make sure that your code is kosher, you should try ridding what gcc complains about with -Weffc++ enabled.

I tried something like that (not sure if it was the exact same thing) once, and it seemed to give me about 500 errors, so I decided I didn't need my code to be that clean after all. So maybe it's not kosher, but at least, well, if I knew more about Judaism I might be able to say something clever, but I guess I'll just say that it compiles, and I'm reasonably sure it'll work with most other compilers as well, which is all I ask for.

DrunkenCoder wrote:
anyone know where to get a free lint?
Um, you can have all of mine, provided you pay postage. I'll be going down to the laundromat later so I can send it off in an hour or so.

Yes, obviously I have no idea what a "lint" is.
Back to top  
Rainer Deyke
Demon Hunter


Joined: 05 Jun 2002
Posts: 672

PostPosted: Sun Aug 03, 2003 9:23 pm    Post subject: [quote]

"lint" is an external program to give you warnings on your code that your compiler won't give you. Sorry, don't know any free ones.
Back to top  
Post new topic Reply to topic Page 2 of 2 All times are GMT
Goto page Previous  1, 2 



Display posts from previous:   
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum