Newbie with ANSI C

  • Thread starter Bruno Desthuilliers
  • Start date
B

Bruno Desthuilliers

Peter said:
Hello

I just enrolled at a university and I might have to do a subject on C
programming (depending on what exemptions I get). The book is "A First Book
of ANSI C. Third Edition" by Gary J Bronson (I think).

I just want to know what software I'd use for that. I already have Visual
C++ version 6 as part of Visual Studio Enterprise Version 6. I'm running
both Windows NT 4 Server and Windows 98 SE.

<a-bit-OT-I-think>
Visual C++ has a C compiler, so it should do the job.

Now if at university you use GCC, you may want to dl and install mingw
or cygwin at home, so you can use the same tools at university and at
home...

my 2 cents
<a-bit-OT-I-think>

Bruno
 
P

Peter Mount

Hello

I just enrolled at a university and I might have to do a subject on C
programming (depending on what exemptions I get). The book is "A First Book
of ANSI C. Third Edition" by Gary J Bronson (I think).

I just want to know what software I'd use for that. I already have Visual
C++ version 6 as part of Visual Studio Enterprise Version 6. I'm running
both Windows NT 4 Server and Windows 98 SE.

So far I've studied Turbo Pascal for DOS, Visual Basic 6 and Java.

Thanks

Peter Mount
(e-mail address removed)
 
C

CBFalconer

Peter said:
I just enrolled at a university and I might have to do a subject
on C programming (depending on what exemptions I get). The book is
"A First Book of ANSI C. Third Edition" by Gary J Bronson (I think).

Not familiar with it.
I just want to know what software I'd use for that. I already have
Visual C++ version 6 as part of Visual Studio Enterprise Version 6.
I'm running both Windows NT 4 Server and Windows 98 SE.

Visual C would do fine with the maximum warning level, except that
that triggers unholy complaints about Micro$loths own header
files. So I would recommend a gcc based system, which is also
much more portable. You can avoid all confusion with GUIness by
installing DJGPP (start from http://www.delorie.com), which is
free and first class. Other options include MINGW and CYGWIN.
All assuming your basic platform is Windoze, for Linux you don't
need to do anything, it is just there.

I recommend using gcc with the following flags:

gcc -W -Wall -ansi -pedantic -Wwrite-strings -gstabs+ -O1

which will give you C89 conformance. Full C99 conformance is not
yet available.
 
R

Richard Heathfield

CBFalconer said:
Visual C would do fine with the maximum warning level, except that
that triggers unholy complaints about Micro$loths own header
files.

I have not found this to be the case. /Za /W4 generally gives me a very
quiet diagnostic life.

Perhaps you're thinking of the C++ compiler (which is indeed very noisily
incapable of compiling its own headers when in conforming mode) rather than
the C compiler.
 
C

CBFalconer

Richard said:
I have not found this to be the case. /Za /W4 generally gives me a
very quiet diagnostic life.

Perhaps you're thinking of the C++ compiler (which is indeed very
noisily incapable of compiling its own headers when in conforming
mode) rather than the C compiler.

I am virtually certain it was the C compiler. This was something
I tried out several years ago, and never installed their service
pack (because it involved some sort of monstrous download). Maybe
they fixed it. And maybe I am dropping more bits.
 
R

Richard Heathfield

CBFalconer said:
I am virtually certain it was the C compiler. This was something
I tried out several years ago, and never installed their service
pack (because it involved some sort of monstrous download). Maybe
they fixed it. And maybe I am dropping more bits.

Well, I find that inexplicable. I've had more or less trouble-free Visual C
compiles for over a decade. A couple of minor glitches (a // comment in
math.h, and a rather strange warning when assigning 1.0 to a double!) were
the only oddities I ever encountered.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,138
Messages
2,570,804
Members
47,349
Latest member
jojonoy597

Latest Threads

Top