473,402 Members | 2,046 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,402 software developers and data experts.

Commandline compiler for windows?

Is there a C-compiler (and for that matter C++ compiler) for windows that
can be run from the commmand line?
Jul 13 '08 #1
87 3228
rufus wrote:
Is there a C-compiler (and for that matter C++ compiler) for windows that
can be run from the commmand line?

All of them can be run from the command line

o MSVC. In your installation tab there is a visual studio
tools item. Open it and choose the command line option. That
will open a command shell with all the necesary environment variables
alraedy set.

o mingw. Install it, add the binaries directory to your path, then
just use it with "gcc options"

o Pelles C: Just install it, go to the installation directory and
use the .bat that sets the environment variables

o lcc-win. Just add \lcc\bin to your path and compile with
lc <arguments>
--
jacob navia
jacob at jacob point remcomp point fr
logiciels/informatique
http://www.cs.virginia.edu/~lcc-win32
Jul 13 '08 #2
rufus said:
Is there a C-compiler (and for that matter C++ compiler) for windows that
can be run from the commmand line?
Yes. Borland C (and its little brother Turbo C), Microsoft C, Pacific C,
gcc, Digital Mars C, Pelles C (and no doubt plenty more) can all be run
from the command line. Your current C compiler can almost certainly do it.
Check the documentation.

--
Richard Heathfield <http://www.cpax.org.uk>
Email: -http://www. +rjh@
Google users: <http://www.cpax.org.uk/prg/writings/googly.php>
"Usenet is a strange place" - dmr 29 July 1999
Jul 13 '08 #3
rufus wrote:
Is there a C-compiler (and for that matter C++ compiler) for windows
that can be run from the commmand line?
As far as I know all compilers that come with IDEs can also be run from
the command line. This includes MSVC, Intel, gcc, Borland, lcc-win,
PellesC etc. Your compiler's documentation will tell you what the
actual command is to invoke the command line compiler and bypass all
the IDE stuff.

But just to get you up and running here are the names of executables
that you need to invoke for compiling from the command line.

MSVC - cl.exe
gcc - gcc (gcc.exe on Windows)
Borland - bcc.exe (and tcc.exe for their "Turbo C" branded products)
lcc-win32 - lcc.exe
Intel - icc (or icc.exe)

But there is no substitute for reading the documentation that comes with
your compiler and Standard library.

Jul 13 '08 #4
Richard Heathfield <rj*@see.sig.invalidwrites:
rufus said:
>Is there a C-compiler (and for that matter C++ compiler) for windows that
can be run from the commmand line?

Yes. Borland C (and its little brother Turbo C), Microsoft C, Pacific C,
gcc, Digital Mars C, Pelles C (and no doubt plenty more) can all be run
from the command line. Your current C compiler can almost certainly do it.
Check the documentation.
You forgot to mention lcc-win. Available free for home use.

Jul 13 '08 #5
Richard wrote:
Richard Heathfield <rj*@see.sig.invalidwrites:
>rufus said:
>>Is there a C-compiler (and for that matter C++ compiler) for windows that
can be run from the commmand line?
Yes. Borland C (and its little brother Turbo C), Microsoft C, Pacific C,
gcc, Digital Mars C, Pelles C (and no doubt plenty more) can all be run
from the command line. Your current C compiler can almost certainly do it.
Check the documentation.

You forgot to mention lcc-win. Available free for home use.
Yeah, bad memory this heathfield...

Thanks for remind him of lcc-win

:-)
--
jacob navia
jacob at jacob point remcomp point fr
logiciels/informatique
http://www.cs.virginia.edu/~lcc-win32
Jul 13 '08 #6
jacob navia wrote:
Richard wrote:
>Richard Heathfield <rj*@see.sig.invalidwrites:
>>rufus said:

Is there a C-compiler (and for that matter C++ compiler) for
windows that can be run from the commmand line?
Yes. Borland C (and its little brother Turbo C), Microsoft C,
Pacific C, gcc, Digital Mars C, Pelles C (and no doubt plenty more)
can all be run from the command line. Your current C compiler can
almost certainly do it. Check the documentation.

You forgot to mention lcc-win. Available free for home use.

Yeah, bad memory this heathfield...
As long as lcc-win doesn't fully conform to either the C89- or C99-Standard,
he doesn't regard it a C-compiler, or did that slip your memory? ;-)

Bye, Jojo
Jul 13 '08 #7
jacob navia said:
Richard wrote:
>Richard Heathfield <rj*@see.sig.invalidwrites:
>>rufus said:

Is there a C-compiler (and for that matter C++ compiler) for windows
that can be run from the commmand line?
Yes. Borland C (and its little brother Turbo C), Microsoft C, Pacific
C, gcc, Digital Mars C, Pelles C (and no doubt plenty more) can all be
run from the command line. Your current C compiler can almost certainly
do it. Check the documentation.

You forgot to mention lcc-win. Available free for home use.

Yeah, bad memory this heathfield...
The troll is mistaken (as usual), and so are you (as usual). I didn't
"forget" to mention lcc-win. The OP asked for command-line-driven C
compilers. As far as I'm aware, lcc-win doesn't claim conformance to
either C90 or C99, so how can it be called a C compiler?

--
Richard Heathfield <http://www.cpax.org.uk>
Email: -http://www. +rjh@
Google users: <http://www.cpax.org.uk/prg/writings/googly.php>
"Usenet is a strange place" - dmr 29 July 1999
Jul 13 '08 #8
Joachim Schmitz wrote:
jacob navia wrote:
>Richard wrote:
>>Richard Heathfield <rj*@see.sig.invalidwrites:

rufus said:

Is there a C-compiler (and for that matter C++ compiler) for
windows that can be run from the commmand line?
Yes. Borland C (and its little brother Turbo C), Microsoft C,
Pacific C, gcc, Digital Mars C, Pelles C (and no doubt plenty more)
can all be run from the command line. Your current C compiler can
almost certainly do it. Check the documentation.
You forgot to mention lcc-win. Available free for home use.
Yeah, bad memory this heathfield...

As long as lcc-win doesn't fully conform to either the C89- or C99-Standard,
he doesn't regard it a C-compiler, or did that slip your memory? ;-)
Bravo!

I think you have earned some points here. Soon you will be a
member of the regulars clique!

Just keep the good work
--
jacob navia
jacob at jacob point remcomp point fr
logiciels/informatique
http://www.cs.virginia.edu/~lcc-win32
Jul 13 '08 #9
Richard Heathfield wrote:
jacob navia said:
>Richard wrote:
>>Richard Heathfield <rj*@see.sig.invalidwrites:

rufus said:

Is there a C-compiler (and for that matter C++ compiler) for windows
that can be run from the commmand line?
Yes. Borland C (and its little brother Turbo C), Microsoft C, Pacific
C, gcc, Digital Mars C, Pelles C (and no doubt plenty more) can all be
run from the command line. Your current C compiler can almost certainly
do it. Check the documentation.
You forgot to mention lcc-win. Available free for home use.
Yeah, bad memory this heathfield...

The troll is mistaken (as usual), and so are you (as usual). I didn't
"forget" to mention lcc-win. The OP asked for command-line-driven C
compilers. As far as I'm aware, lcc-win doesn't claim conformance to
either C90 or C99, so how can it be called a C compiler?
You are lying, as always.

--
jacob navia
jacob at jacob point remcomp point fr
logiciels/informatique
http://www.cs.virginia.edu/~lcc-win32
Jul 13 '08 #10
jacob navia <ja***@nospam.comwrites:
Joachim Schmitz wrote:
>jacob navia wrote:
>>Richard wrote:
Richard Heathfield <rj*@see.sig.invalidwrites:

rufus said:
>
>Is there a C-compiler (and for that matter C++ compiler) for
>windows that can be run from the commmand line?
Yes. Borland C (and its little brother Turbo C), Microsoft C,
Pacific C, gcc, Digital Mars C, Pelles C (and no doubt plenty more)
can all be run from the command line. Your current C compiler can
almost certainly do it. Check the documentation.
You forgot to mention lcc-win. Available free for home use.

Yeah, bad memory this heathfield...

As long as lcc-win doesn't fully conform to either the C89- or
C99-Standard, he doesn't regard it a C-compiler, or did that slip
your memory? ;-)

Bravo!

I think you have earned some points here. Soon you will be a
member of the regulars clique!

Just keep the good work
Between JoJo and Vippstar it must be hard for Heathfield to choose
his number one lackey!

Jul 13 '08 #11
jacob navia wrote:
Richard Heathfield wrote:
>jacob navia said:
>>Richard wrote:
Richard Heathfield <rj*@see.sig.invalidwrites:

rufus said:
>
>Is there a C-compiler (and for that matter C++ compiler) for
>windows that can be run from the commmand line?
Yes. Borland C (and its little brother Turbo C), Microsoft C,
Pacific C, gcc, Digital Mars C, Pelles C (and no doubt plenty
more) can all be run from the command line. Your current C
compiler can almost certainly do it. Check the documentation.
You forgot to mention lcc-win. Available free for home use.

Yeah, bad memory this heathfield...

The troll is mistaken (as usual), and so are you (as usual). I didn't
"forget" to mention lcc-win. The OP asked for command-line-driven C
compilers. As far as I'm aware, lcc-win doesn't claim conformance to
either C90 or C99, so how can it be called a C compiler?

You are lying, as always.
So win-lcc _is_ claiming conformance to C90 or C99? Which one then? Or even
both? Which which switches?
I only remember severel reports here about non-conformance to either
standard, so if you claim win-lcc to be conforming _you_ seem to be lying
here...

Bye, Jojo
Jul 13 '08 #12
Joachim Schmitz wrote:
So win-lcc _is_ claiming conformance to C90 or C99? Which one then? Or even
both? Which which switches?
C89 is supported
C99 is supported but there are a few things missing.

I only remember severel reports here about non-conformance to either
standard, so if you claim win-lcc to be conforming _you_ seem to be lying
here...
What are the problems? Can you specify?
--
jacob navia
jacob at jacob point remcomp point fr
logiciels/informatique
http://www.cs.virginia.edu/~lcc-win32
Jul 13 '08 #13
jacob navia wrote:
Joachim Schmitz wrote:
>So win-lcc _is_ claiming conformance to C90 or C99? Which one then?
Or even both? Which which switches?
C89 is supported
Which switches turn on full C89 conformance?
C99 is supported but there are a few things missing.
Which switch to turn this on? However, as long as things are missing, it is
not fully C99 conformant. Claiming otherwise would be a lie.
There is no half-way-conformant or nearly-there, that's like "almost
pregnant".
>I only remember severel reports here about non-conformance to either
standard, so if you claim win-lcc to be conforming _you_ seem to be
lying here...

What are the problems? Can you specify?
I remember several issues having been mentioned here in CLC, most recently
frand() from one of your standard headers.
I'm too lazy to dig up the other issues now, there were several in the past
few months and you perfectly know about them as you went balistic every
signle time one came up.

Hmm, maybe you can rightfully claim it to be C89 conformant, modulo bugs?

Bye, Jojo
Jul 13 '08 #14
jacob navia wrote:
Joachim Schmitz wrote:
>So win-lcc _is_ claiming conformance to C90 or C99? Which one then?
Or even both? Which which switches?
C89 is supported
What is the switch to enforce conformance to C90?

<snip>

Jul 13 '08 #15
santosh wrote:
jacob navia wrote:
>Joachim Schmitz wrote:
>>So win-lcc _is_ claiming conformance to C90 or C99? Which one then?
Or even both? Which which switches?
C89 is supported

What is the switch to enforce conformance to C90?

<snip>
The C90 standard is no longer the current standard. But all
of C90 is supported as far as it doesn't contradict C99.

And no, I will NOT issue a warning for // comments. I stay
compatible with Microsoft C that doesn't warn either.

:-)
--
jacob navia
jacob at jacob point remcomp point fr
logiciels/informatique
http://www.cs.virginia.edu/~lcc-win32
Jul 13 '08 #16
jacob navia wrote:
santosh wrote:
>jacob navia wrote:
>>Joachim Schmitz wrote:
So win-lcc _is_ claiming conformance to C90 or C99? Which one then?
Or even both? Which which switches?
C89 is supported

What is the switch to enforce conformance to C90?

<snip>

The C90 standard is no longer the current standard. But all
of C90 is supported as far as it doesn't contradict C99.

And no, I will NOT issue a warning for // comments. I stay
compatible with Microsoft C that doesn't warn either.

:-)
A more serious problem is that you do not issue any diagnostic for using
a C99 feature that would be a constraint violation under C90 like a
VLA, even with the '-A' and '-ansic' switches.

IMO, this seriously impacts the usefulness of lcc-win32 as a C90
compiler, as we apparently cannot rely on it to point out code that
violates the rules of C90 but may be fine under C99.

Thus lcc-win32 can only be used, AFAICS, as an "almost conformant" C99
compiler.

Jul 13 '08 #17
jacob navia said:
Richard Heathfield wrote:
<snip>
>As far as I'm aware, lcc-win doesn't claim conformance to
either C90 or C99, so how can it be called a C compiler?

You are lying, as always.
No, you still don't understand what "lying" means. Perhaps you are claiming
that lcc-win conforms to C90 or C99. If so, please make it clear.

(a) Is it your claim that lcc-win conforms to C90?

(b) Is it your claim that lcc-win conforms to C99?

--
Richard Heathfield <http://www.cpax.org.uk>
Email: -http://www. +rjh@
Google users: <http://www.cpax.org.uk/prg/writings/googly.php>
"Usenet is a strange place" - dmr 29 July 1999
Jul 13 '08 #18
jacob navia said:
Joachim Schmitz wrote:
>So win-lcc _is_ claiming conformance to C90 or C99? Which one then? Or
even both? Which which switches?
C89 is supported
But does lcc-win *conform* to C89? There's a huge difference between
"supports" and "conforms to".
C99 is supported but there are a few things missing.
So presumably you agree that "supported" doesn't mean "conforms to". And if
you were under the impression that lcc-win conformed to either Standard,
you'd have said so, right?
>I only remember severel reports here about non-conformance to either
standard, so if you claim win-lcc to be conforming _you_ seem to be
lying here...

What are the problems? Can you specify?
If you claim that lcc-win *CONFORMS TO* (not "supports" but actually
conforms to) some C Standard or other, then it's your job to find out what
the non-conformance problems are. But as a start, many have been raised in
this group, so all you have to do is dig out your archive search tool.

--
Richard Heathfield <http://www.cpax.org.uk>
Email: -http://www. +rjh@
Google users: <http://www.cpax.org.uk/prg/writings/googly.php>
"Usenet is a strange place" - dmr 29 July 1999
Jul 13 '08 #19
jacob navia said:
santosh wrote:
>jacob navia wrote:
>>Joachim Schmitz wrote:
So win-lcc _is_ claiming conformance to C90 or C99? Which one then?
Or even both? Which which switches?
C89 is supported

What is the switch to enforce conformance to C90?

<snip>

The C90 standard is no longer the current standard. But all
of C90 is supported as far as it doesn't contradict C99.
main(){ return 0; } contradicts C99, but is C89-standard code. That's a
trivial example, but it shouldn't stretch your imagination too much to
come up with more important examples.

Since you say C99 is not fully supported, and since you say that C89
features that contradict C99 are not supported, what you're basically
saying is that you don't have a C compiler, because it doesn't conform to
either standard. And yet you called me a liar for pointing this out. So
does that mean you're lying too? After all, you're making the same claim I
made.
>
And no, I will NOT issue a warning for // comments. I stay
compatible with Microsoft C that doesn't warn either.
Yes, it does, when invoked in conforming mode. To become compatible with
Microsoft C, you're going to need a conforming mode.

--
Richard Heathfield <http://www.cpax.org.uk>
Email: -http://www. +rjh@
Google users: <http://www.cpax.org.uk/prg/writings/googly.php>
"Usenet is a strange place" - dmr 29 July 1999
Jul 13 '08 #20
jacob navia wrote:
santosh wrote:
>jacob navia wrote:
>>Joachim Schmitz wrote:
So win-lcc _is_ claiming conformance to C90 or C99? Which one then?
Or even both? Which which switches?
C89 is supported

What is the switch to enforce conformance to C90?

<snip>

The C90 standard is no longer the current standard. But all
of C90 is supported as far as it doesn't contradict C99.

And no, I will NOT issue a warning for // comments. I stay
compatible with Microsoft C that doesn't warn either.
non-conformance to C89/C90, not even a bug, but a deliberate decision.
non-conformance to C99, as 'a few things are missing'

So who again was lying?

Bye, Jojo
Jul 13 '08 #21

"Joachim Schmitz" <no*********@schmitz-digital.deskrev i en meddelelse
news:g5**********@online.de...
jacob navia wrote:
>santosh wrote:
>>jacob navia wrote:

Joachim Schmitz wrote:
So win-lcc _is_ claiming conformance to C90 or C99? Which one then?
Or even both? Which which switches?
C89 is supported

What is the switch to enforce conformance to C90?

<snip>

The C90 standard is no longer the current standard. But all
of C90 is supported as far as it doesn't contradict C99.

And no, I will NOT issue a warning for // comments. I stay
compatible with Microsoft C that doesn't warn either.
non-conformance to C89/C90, not even a bug, but a deliberate decision.
non-conformance to C99, as 'a few things are missing'

So who again was lying?

Bye, Jojo

Christ guys you seriously need to get laid!
Jul 13 '08 #22
Joachim Schmitz <no*********@schmitz-digital.dewrote:
>
Hmm, maybe you can rightfully claim it to be C89 conformant, modulo bugs?
Not without disabling // comments, which he refuses to do. Otherwise,
it gets the wrong result for:

int slashslash = 1 //* */ 2
- 0;

C89 requires slashslash to have the value 0; compilers that support //
comments will give it the value 1 instead. Of course, Jacob will claim
that there isn't any real code like that, so it doesn't matter.
--
Larry Jones

Years from now when I'm successful and happy, ...and he's in
prison... I hope I'm not too mature to gloat. -- Calvin
Jul 13 '08 #23
Joachim Schmitz wrote:
jacob navia wrote:
>santosh wrote:
>>jacob navia wrote:

Joachim Schmitz wrote:
So win-lcc _is_ claiming conformance to C90 or C99? Which one then?
Or even both? Which which switches?
C89 is supported
What is the switch to enforce conformance to C90?

<snip>
The C90 standard is no longer the current standard. But all
of C90 is supported as far as it doesn't contradict C99.

And no, I will NOT issue a warning for // comments. I stay
compatible with Microsoft C that doesn't warn either.
non-conformance to C89/C90, not even a bug, but a deliberate decision.
And the only reason for such a lie is that I accept // comments?

Go get a life "jojo".
non-conformance to C99, as 'a few things are missing'
Yes, for you only 100% conformance counts.

So who again was lying?
You, as your master Heathfield.
--
jacob navia
jacob at jacob point remcomp point fr
logiciels/informatique
http://www.cs.virginia.edu/~lcc-win32
Jul 13 '08 #24
rufus wrote:
"Joachim Schmitz" <no*********@schmitz-digital.deskrev i en
meddelelse news:g5**********@online.de...
>jacob navia wrote:
>>santosh wrote:
jacob navia wrote:

Joachim Schmitz wrote:
>So win-lcc _is_ claiming conformance to C90 or C99? Which one
>then? Or even both? Which which switches?
C89 is supported

What is the switch to enforce conformance to C90?

<snip>
The C90 standard is no longer the current standard. But all
of C90 is supported as far as it doesn't contradict C99.

And no, I will NOT issue a warning for // comments. I stay
compatible with Microsoft C that doesn't warn either.
non-conformance to C89/C90, not even a bug, but a deliberate
decision. non-conformance to C99, as 'a few things are missing'

So who again was lying?

Bye, Jojo


Christ guys you seriously need to get laid!
Jacob keeps calling people liars and hypocrits without good reason. So this
thread shows once again that he's a liar and hypocrit himself.

Bye, Jojo
Jul 13 '08 #25
jacob navia wrote:
Joachim Schmitz wrote:
>jacob navia wrote:
>>santosh wrote:
jacob navia wrote:

Joachim Schmitz wrote:
>So win-lcc _is_ claiming conformance to C90 or C99? Which one
>then? Or even both? Which which switches?
C89 is supported
What is the switch to enforce conformance to C90?

<snip>

The C90 standard is no longer the current standard. But all
of C90 is supported as far as it doesn't contradict C99.

And no, I will NOT issue a warning for // comments. I stay
compatible with Microsoft C that doesn't warn either.
non-conformance to C89/C90, not even a bug, but a deliberate
decision.

And the only reason for such a lie is that I accept // comments?
Amongst others, yes. VLAs is another one, as RH pointed out upthread
>
Go get a life "jojo".
Shift key broken?
>non-conformance to C99, as 'a few things are missing'

Yes, for you only 100% conformance counts.
Indeed, as said earlier thers's no such thing as 'almost pregnant'

>So who again was lying?

You, as your master Heathfield.
No, you. And twice in that sentence alone.
Jul 13 '08 #26
jacob navia wrote:
Joachim Schmitz wrote:
>jacob navia wrote:
>>santosh wrote:
jacob navia wrote:

Joachim Schmitz wrote:
>So win-lcc _is_ claiming conformance to C90 or C99? Which one
>then? Or even both? Which which switches?
C89 is supported
What is the switch to enforce conformance to C90?

<snip>

The C90 standard is no longer the current standard. But all
of C90 is supported as far as it doesn't contradict C99.

And no, I will NOT issue a warning for // comments. I stay
compatible with Microsoft C that doesn't warn either.
non-conformance to C89/C90, not even a bug, but a deliberate
decision.

And the only reason for such a lie is that I accept // comments?
What about the fact that you accept VLAs without a diagnostic. Under
conformance to C90 a diagnostic is required (though afterwards you can
do anything), but lcc-win32 silently accepts such code.

As you said above C90 is supported as far as it "doesn't contradict"
C99, so you cannot claim C90 conformance. There isn't even any option
to turn on C90 conformance.

Now if you would only finish implementing the remaining bits of C99, you
could at least claim conformance to C99. What's the point in blaming
gcc when you too come all the way to 90% conformance and then stop
dead?

<snip>

OTOH I wouldn't go so far as to say that lcc-win32 isn't a C compiler.

Jul 13 '08 #27
jacob navia said:
Joachim Schmitz wrote:
<snip>
>non-conformance to C89/C90, not even a bug, but a deliberate decision.

And the only reason for such a lie is that I accept // comments?
It's not a lie, and you really should stop using that word until you learn
what it means. Joachim is telling you the absolute truth. Conforming
implementations *must* diagnose programs containing at least one syntax
error or constraint violation. If your implementation translates a program
containing a syntax error (or constraint violation) without issuing a
diagnostic message, then your implementation is non-conforming, and
calling people liars for saying so just makes you look stupid.

In almost all cases, // in C90 is a syntax error. In the case where it is
not, it is not a comment, and treating it as one represents a failure to
translate it correctly. Failure to diagnose a syntax error is a serious
conformance failure, and mistranslation is an even more serious
conformance failure.

If you don't claim conformance to C90, that isn't a problem, obviously. If
you *do* claim conformance to C90 but fail to diagnose a syntax error,
then it is you who is lying, not Joachim.

But if you don't claim conformance to either C90 or C99, how can your
implementation reasonably be described as a C compiler?
Go get a life "jojo".
Go write a C compiler. You haven't yet managed it.
>
>non-conformance to C99, as 'a few things are missing'

Yes, for you only 100% conformance counts.
Right. Well done. You might just be at the threshold of understanding this
at long last. Only 100% conformance counts.
>So who again was lying?

You, as your master Heathfield.
You seem to think that if one person disagrees with you, they're lying, and
if more than one disagrees with you, they're in collusion. You are
mistaken. Please grow up.

--
Richard Heathfield <http://www.cpax.org.uk>
Email: -http://www. +rjh@
Google users: <http://www.cpax.org.uk/prg/writings/googly.php>
"Usenet is a strange place" - dmr 29 July 1999
Jul 13 '08 #28

<la************@siemens.comschreef in bericht
news:kt************@jones.homeip.net...
so it doesn't matter.
indeed

Jul 13 '08 #29

"santosh" <sa*********@gmail.comschreef in bericht
news:g5**********@registered.motzarella.org...
A more serious problem is that you do not issue any diagnostic for using
a C99 feature that would be a constraint violation under C90 like a
VLA, even with the '-A' and '-ansic' switches.

IMO, this seriously impacts the usefulness of lcc-win32 as a C90
compiler, as we apparently cannot rely on it to point out code that
violates the rules of C90 but may be fine under C99.

Thus lcc-win32 can only be used, AFAICS, as an "almost conformant" C99
compiler.
I know its a novel idea but it can also be used to create programs that get
some work done

Jul 13 '08 #30
Serve Lau wrote:
>
"santosh" <sa*********@gmail.comschreef in bericht
news:g5**********@registered.motzarella.org...
[snip]
>Thus lcc-win32 can only be used, AFAICS, as an "almost conformant" C99
compiler.

I know its a novel idea but it can also be used to create programs that
get some work done
It has been my main objective

105 digits floating point precision with the 32 bit version, 135 with
the 64 bit version. and all the extras like debugger, resource editor,
project management, etc.

That is far from this sterile discussions about issuing a warning or
not when you see // comments.

I prefer giving to the user more power, and that is the objective of
this work.

--
jacob navia
jacob at jacob point remcomp point fr
logiciels/informatique
http://www.cs.virginia.edu/~lcc-win32
Jul 13 '08 #31
jacob navia <ja***@nospam.comwrites:
santosh wrote:
>jacob navia wrote:
>>Joachim Schmitz wrote:
So win-lcc _is_ claiming conformance to C90 or C99? Which one then?
Or even both? Which which switches?
C89 is supported
What is the switch to enforce conformance to C90?
<snip>

The C90 standard is no longer the current standard. But all
of C90 is supported as far as it doesn't contradict C99.
If lcc-win supports only the subset of C90 that doesn't contradict C99,
then it *doesn't* support C90.
And no, I will NOT issue a warning for // comments. I stay
compatible with Microsoft C that doesn't warn either.
So you care more about compatibility with Microsoft C (which doesn't
even attempt to support C99, as I recall) than about conformance to
the C90 standard.

I'm guessing you don't issue a diagnostic for "long long" either, or
allow "restrict" to be used as an identifier.

Let me make an important point here. I am *not* complaining about
lcc-win's apparent lack of support for C90. Not supporting C90 is a
perfectly valid choice, particularly for a compiler that supports most
of C99. And if I'm writing code in C90, I will attempt to limit
myself to the subset that's compatible with C99. I won't use
"restrict" (a C99-specific keyword) or "sqrtl (a C99-specific standard
library function) as an identifier, and so forth. I won't even use
non-prototyped functions, something allowed by both C90 and C99.

So, if I had a need to write new C90 code for Windows, lcc-win's
failure to conform fully to the C90 standard would not be a fatal
obstacle.

But *you're* the one who made the false claim that lcc-win conforms to
C90, and who continues to defend that false claim, and to attack those
who refute it.

--
Keith Thompson (The_Other_Keith) ks***@mib.org <http://www.ghoti.net/~kst>
Nokia
"We must do something. This is something. Therefore, we must do this."
-- Antony Jay and Jonathan Lynn, "Yes Minister"
Jul 13 '08 #32

"Joachim Schmitz" <no*********@schmitz-digital.dewrote in message
jacob navia wrote:
>Yes, for you only 100% conformance counts.

Indeed, as said earlier thers's no such thing as 'almost pregnant'
There's such as thing as "almost conforming" however.

--
Free games and programming goodies.
http://www.personal.leeds.ac.uk/~bgy1mm

Jul 13 '08 #33

<la************@siemens.comwrote in message news:
Joachim Schmitz <no*********@schmitz-digital.dewrote:
>>
Hmm, maybe you can rightfully claim it to be C89 conformant, modulo bugs?

Not without disabling // comments, which he refuses to do. Otherwise,
it gets the wrong result for:

int slashslash = 1 //* */ 2
- 0;

C89 requires slashslash to have the value 0; compilers that support //
comments will give it the value 1 instead. Of course, Jacob will claim
that there isn't any real code like that, so it doesn't matter.
And of course there isn't and it doesn't matter. It's far more likely that
the compiler contains bugs that cause the mistranslation of unusual but
non-perverse programs than that someone would use that construct for any
purpose other than breaking a compiler that accepts slash slash comments.

--
Free games and programming goodies.
http://www.personal.leeds.ac.uk/~bgy1mm

Jul 13 '08 #34
jacob navia <ja***@nospam.comwrites:
[...]
Yes, for you only 100% conformance counts.
[...]

Only 100% conformance counts as 100% conformance.

Something with less than 100% conformance might be very useful. I do
not claim that lcc-win is not useful. I merely state, based on what
you've written about it, that it does not conform (i.e., does not
fully, 100% conform) to either C90 or C99.

There are plenty of not-quite-conforming C99 implementations out
there. I have no problem with that; I wish they were 100% conforming,
but I'm not necessarily going to criticize their implementers for
that.

If a compiler implementer produces a compiler that doesn't fully
conform, where the failure to conform isn't just a few bugs but
features that simply have not been implemented, then that's ok. It's
a necessary step on the path to full conformance, assuming that's the
goal.

But then that same implementer falsely claims that his compiler
conforms to the standard (both C90 *and* C99), and accuses anyone who
contradicted that false statement of lying.

A gcc maintainer falsely claiming that gcc conforms to C99 would
receive the same scorn.

lcc-win does not conform to C90.

lcc-win does not conform to C99.

Neither of the above statements is a personal attack.

And you are too damned stubborn to understand that.

--
Keith Thompson (The_Other_Keith) ks***@mib.org <http://www.ghoti.net/~kst>
Nokia
"We must do something. This is something. Therefore, we must do this."
-- Antony Jay and Jonathan Lynn, "Yes Minister"
Jul 13 '08 #35
Serve Lau said:
>
"santosh" <sa*********@gmail.comschreef in bericht
news:g5**********@registered.motzarella.org...
>A more serious problem is that you do not issue any diagnostic for using
a C99 feature that would be a constraint violation under C90 like a
VLA, even with the '-A' and '-ansic' switches.

IMO, this seriously impacts the usefulness of lcc-win32 as a C90
compiler, as we apparently cannot rely on it to point out code that
violates the rules of C90 but may be fine under C99.

Thus lcc-win32 can only be used, AFAICS, as an "almost conformant" C99
compiler.

I know its a novel idea but it can also be used to create programs that
get some work done
Possibly, although the cavalier attitude of its maintainer towards
diagnosing syntax errors must surely give some cause for concern to those
of a cautious nature.

What's more, there are plenty of other compilers out there that can be used
to create programs that get some work done, and that *can* be relied upon
to diagnose syntax errors in accordance with the Standard.

--
Richard Heathfield <http://www.cpax.org.uk>
Email: -http://www. +rjh@
Google users: <http://www.cpax.org.uk/prg/writings/googly.php>
"Usenet is a strange place" - dmr 29 July 1999
Jul 13 '08 #36
Malcolm McLean wrote:
>
<la************@siemens.comwrote in message news:
>Joachim Schmitz <no*********@schmitz-digital.dewrote:
>>>
Hmm, maybe you can rightfully claim it to be C89 conformant, modulo
bugs?

Not without disabling // comments, which he refuses to do. Otherwise,
it gets the wrong result for:

int slashslash = 1 //* */ 2
- 0;

C89 requires slashslash to have the value 0; compilers that support //
comments will give it the value 1 instead. Of course, Jacob will claim
that there isn't any real code like that, so it doesn't matter.
And of course there isn't and it doesn't matter. It's far more likely
that the compiler contains bugs that cause the mistranslation of unusual
but non-perverse programs than that someone would use that construct for
any purpose other than breaking a compiler that accepts slash slash
comments.
This is the kingdom of pedants, and my compiler is a good target for
them.

Note the kind of "bugs" presented here. Where have anybody ever seen
int s = 1 //* */2
-0;

?????

--
jacob navia
jacob at jacob point remcomp point fr
logiciels/informatique
http://www.cs.virginia.edu/~lcc-win32
Jul 13 '08 #37
"Serve Lau" <ni***@qinqin.comwrites:
"santosh" <sa*********@gmail.comschreef in bericht
news:g5**********@registered.motzarella.org...
>A more serious problem is that you do not issue any diagnostic for using
a C99 feature that would be a constraint violation under C90 like a
VLA, even with the '-A' and '-ansic' switches.

IMO, this seriously impacts the usefulness of lcc-win32 as a C90
compiler, as we apparently cannot rely on it to point out code that
violates the rules of C90 but may be fine under C99.

Thus lcc-win32 can only be used, AFAICS, as an "almost conformant" C99
compiler.

I know its a novel idea but it can also be used to create programs
that get some work done
Yes. Note that that doesn't contradict santosh's statement; an
"almost conformant" C99 compiler can certainly be used to create
programs that get some work done.

(So can a Fortran compiler.)

--
Keith Thompson (The_Other_Keith) ks***@mib.org <http://www.ghoti.net/~kst>
Nokia
"We must do something. This is something. Therefore, we must do this."
-- Antony Jay and Jonathan Lynn, "Yes Minister"
Jul 13 '08 #38
On Mon, 14 Jul 2008 00:49:25 +0200, jacob navia wrote:
This is the kingdom of pedants, and my compiler is a good target for
them.

Note the kind of "bugs" presented here. Where have anybody ever seen int
s = 1 //* */2
-0;

?????
As I believe has been pointed out already, not reporting the syntax error
in

s = 1; // set s to 1

is a failure to conform to the C90 standard as well. That one _is_ likely
to be found in real code, and when the compiler is specifically told the
code is meant to be C90, the // comment is probably not intentional.

(There is no inherent problem with a compiler that doesn't conform to C90,
as long as it doesn't claim to conform.)
Jul 13 '08 #39
In article <48***********************@news.sunsite.dk>,
rufus <as***@asd.comwrote:
>Is there a C-compiler (and for that matter C++ compiler) for windows that
can be run from the commmand line?
I notice that no one here has mentioned OpenWatcom, so I thought that I
ought to at least mention it. Of course, I must also disclaim any
knowledge as to the degree of conformance that this compiler has in any
state to any of the standards. However, you could try it out and see if
it does indeed satisfy your requirements.

Sincerely,
Aaron Hsu

--
+++++++++++++++ ((lambda (x) (x x)) (lambda (x) (x x))) +++++++++++++++
Email: <ar*****@sacrideo.us| WWW: <http://www.sacrideo.us>
Scheme Programming is subtle; subtlety can be hard.
++++++++++++++++++++++++++++++++++++++++++++++++++ +++++++++++++++++++++
Jul 14 '08 #40
Harald van Dijk <tr*****@gmail.comwrites:
On Mon, 14 Jul 2008 00:49:25 +0200, jacob navia wrote:
>This is the kingdom of pedants, and my compiler is a good target for
them.

Note the kind of "bugs" presented here. Where have anybody ever seen int
s = 1 //* */2
-0;

?????

As I believe has been pointed out already, not reporting the syntax error
in

s = 1; // set s to 1

is a failure to conform to the C90 standard as well. That one _is_ likely
to be found in real code, and when the compiler is specifically told the
code is meant to be C90, the // comment is probably not intentional.
So is not reporting all the other C99-specific syntax errors like:

for (int i = 0; i < 10; i++)...

and

f((struct S){42, NULL});

More seriously, I'd want any C compiler to diagnose:

void f(long *lp) { *lp = 0; }
int main(void) { int i; f(&i); return i; }

as invalid.

--
Ben.
Jul 14 '08 #41
jacob navia <ja***@nospam.comwrites:
Serve Lau wrote:
>>
"santosh" <sa*********@gmail.comschreef in bericht
news:g5**********@registered.motzarella.org...
[snip]
>>Thus lcc-win32 can only be used, AFAICS, as an "almost conformant" C99
compiler.

I know its a novel idea but it can also be used to create programs
that get some work done

It has been my main objective

105 digits floating point precision with the 32 bit version, 135 with
the 64 bit version. and all the extras like debugger, resource editor,
project management, etc.

That is far from this sterile discussions about issuing a warning or
not when you see // comments.

I prefer giving to the user more power, and that is the objective of
this work.
Each to his/her own. I don't need 105 digit floats, but I would like
working (a) VLAs (b) compound literals (c) designated initialisers (d)
__VA_ARGS__ (e) standard type checking (c.f. the int/long issue). You
have chosen extensions over standard features which may be correct
from a business point of view, but for getting some work done it rules
out lcc-win32.

--
Ben.
Jul 14 '08 #42
Malcolm McLean wrote:
"Joachim Schmitz" <no*********@schmitz-digital.dewrote:
>jacob navia wrote:
>>Yes, for you only 100% conformance counts.

Indeed, as said earlier thers's no such thing as 'almost pregnant'

There's such as thing as "almost conforming" however.
This brings up a logical problem. Can we classify all "almost
conforming" wenches as non-pregnant, or do we need to permit them
to be "almost pregnant". Alternatively, are all "almost pregnant"
wenches classifiable as "almost conforming"? What happens when we
replace the word "almost" with "strictly"? What if we replace
"almost " with "non-"?

--
[mail]: Chuck F (cbfalconer at maineline dot net)
[page]: <http://cbfalconer.home.att.net>
Try the download section.
Jul 14 '08 #43

On Jul 13, 8:42*pm, CBFalconer <cbfalco...@yahoo.comwrote:

All wenches are "almost pregnant", with the exception to the
"definitely pregnant" ones. The "strictly pregnant" should almost
definitely find a doctor.

Rafael
Jul 14 '08 #44

On Jul 13, 8:42*pm, CBFalconer <cbfalco...@yahoo.comwrote:

All wenches are "almost pregnant", with the exception to the
"definitely pregnant" ones. The "strictly pregnant" should almost
definitely find a doctor.

Rafael
Jul 14 '08 #45
jacob navia <ja***@nospam.comwrites:
Malcolm McLean wrote:
><la************@siemens.comwrote in message news:
>>Joachim Schmitz <no*********@schmitz-digital.dewrote:

Hmm, maybe you can rightfully claim it to be C89 conformant,
modulo bugs?

Not without disabling // comments, which he refuses to do. Otherwise,
it gets the wrong result for:

int slashslash = 1 //* */ 2
- 0;

C89 requires slashslash to have the value 0; compilers that support //
comments will give it the value 1 instead. Of course, Jacob will claim
that there isn't any real code like that, so it doesn't matter.
And of course there isn't and it doesn't matter. It's far more
likely that the compiler contains bugs that cause the mistranslation
of unusual but non-perverse programs than that someone would use
that construct for any purpose other than breaking a compiler that
accepts slash slash comments.

This is the kingdom of pedants, and my compiler is a good target for
them.

Note the kind of "bugs" presented here. Where have anybody ever seen
int s = 1 //* */2
-0;

?????
Only in code deliberately designed to demonstrate this issue.

On the other hand, have you ever seen code that uses "restrict" as an
identifier? Or that uses the names of any of the other C99-specific
library routines that aren't reserved in C90?

In any case, part of the job of a compiler for any language is to
diagnose errors. In C90, a // comment is an error. If I had a
requirement to write C90-conforming code, I wouldn't want to use a
compiler that fails to diagnose C90 syntax errors.

If you don't care about C90, that's fine; nobody has said you should.
But then don't claim that lcc-win supports C90.

--
Keith Thompson (The_Other_Keith) ks***@mib.org <http://www.ghoti.net/~kst>
Nokia
"We must do something. This is something. Therefore, we must do this."
-- Antony Jay and Jonathan Lynn, "Yes Minister"
Jul 14 '08 #46
Ben Bacarisse <be********@bsb.me.ukwrites:
[...]
More seriously, I'd want any C compiler to diagnose:

void f(long *lp) { *lp = 0; }
int main(void) { int i; f(&i); return i; }

as invalid.
Of course; that's a constraint violation in either C90 or C99.

If you know of a compiler that fails to diagnose this in conforming
mode, that's simply a bug, and it should be reported to the provider.
(I have no knowledge of whether any particular compiler fails in this
way. gcc issues a warning, not an error message, which is conforming
behavior.)

I question the relevance to this discussion.

--
Keith Thompson (The_Other_Keith) ks***@mib.org <http://www.ghoti.net/~kst>
Nokia
"We must do something. This is something. Therefore, we must do this."
-- Antony Jay and Jonathan Lynn, "Yes Minister"
Jul 14 '08 #47
Ben Bacarisse wrote:
Harald van D?k <tr*****@gmail.comwrites:
>On Mon, 14 Jul 2008 00:49:25 +0200, jacob navia wrote:
>>This is the kingdom of pedants, and my compiler is a good target for
them.

Note the kind of "bugs" presented here. Where have anybody ever seen
int s = 1 //* */2
-0;

?????

As I believe has been pointed out already, not reporting the syntax
error in

s = 1; // set s to 1

is a failure to conform to the C90 standard as well. That one _is_
likely to be found in real code, and when the compiler is
specifically told the code is meant to be C90, the // comment is
probably not intentional.

So is not reporting all the other C99-specific syntax errors like:

for (int i = 0; i < 10; i++)...

and

f((struct S){42, NULL});

More seriously, I'd want any C compiler to diagnose:

void f(long *lp) { *lp = 0; }
int main(void) { int i; f(&i); return i; }

as invalid.
This is serious enough to reconsider using lcc-win (presumably the paid
version is internally the same) for professional use. Every other
compiler I tested the code under provides a diagnostic, even when no
switch explicitly enabling diagnostics is active.

Jul 14 '08 #48
santosh wrote:
Ben Bacarisse wrote:
>Harald van D?k <tr*****@gmail.comwrites:
>>On Mon, 14 Jul 2008 00:49:25 +0200, jacob navia wrote:
This is the kingdom of pedants, and my compiler is a good target for
them.

Note the kind of "bugs" presented here. Where have anybody ever seen
int s = 1 //* */2
-0;

?????
As I believe has been pointed out already, not reporting the syntax
error in

s = 1; // set s to 1

is a failure to conform to the C90 standard as well. That one _is_
likely to be found in real code, and when the compiler is
specifically told the code is meant to be C90, the // comment is
probably not intentional.
So is not reporting all the other C99-specific syntax errors like:

for (int i = 0; i < 10; i++)...

and

f((struct S){42, NULL});

More seriously, I'd want any C compiler to diagnose:

void f(long *lp) { *lp = 0; }
int main(void) { int i; f(&i); return i; }

as invalid.

This is serious enough to reconsider using lcc-win (presumably the paid
version is internally the same) for professional use. Every other
compiler I tested the code under provides a diagnostic, even when no
switch explicitly enabling diagnostics is active.
Yes yes. But MSVC with the highest warning level doesn't
warn either. But you never say this to people recommending MSVC.

--
jacob navia
jacob at jacob point remcomp point fr
logiciels/informatique
http://www.cs.virginia.edu/~lcc-win32
Jul 14 '08 #49
Keith Thompson wrote:
Ben Bacarisse <be********@bsb.me.ukwrites:
[...]
>More seriously, I'd want any C compiler to diagnose:

void f(long *lp) { *lp = 0; }
int main(void) { int i; f(&i); return i; }

as invalid.

Of course; that's a constraint violation in either C90 or C99.

If you know of a compiler that fails to diagnose this in conforming
mode, that's simply a bug, and it should be reported to the provider.
(I have no knowledge of whether any particular compiler fails in this
way. gcc issues a warning, not an error message, which is conforming
behavior.)

I question the relevance to this discussion.
MSVC doesn't warn either, even with the highest warning level

--
jacob navia
jacob at jacob point remcomp point fr
logiciels/informatique
http://www.cs.virginia.edu/~lcc-win32
Jul 14 '08 #50

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: nick | last post by:
Hi all: In the winform i want to run commandline with return value(string), then display this string in winform textbox. anyone has idea about that? Thanks Nick
2
by: Christoph Borger | last post by:
Hello! I have wrote a windows service in vb.net. This service monitors the running processes with WMI and the Win32_Process class. Till last month all seems ok. But since the begin of september...
4
by: Bit byte | last post by:
I have a project that I normally build (without problems) from the DevStudio IDE. However, I have embarked on automating all my builds (this test project being one of several). The project...
0
by: axlq | last post by:
While trying to learn the ins and outs of the php CURL library, I decided to write a php script that posts a form on the Chicago Board of Options (CBOE) web site, which returns an ASCII text file. ...
1
by: RSH | last post by:
Hi, I have a silly question... I have a Windows Form project (VB.Net) that was created in Visual Studio 2003. The project runs great. Now I have to add the ability to run the same...
2
by: andreas.huesgen | last post by:
Hello, I am writing a commandline tool in Python which is often feed with lots of commandline arguments. In practice, the commandline already reached a critical length which is to long for Windows...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.