A good compiler

R

Richard Heathfield

Chris Hills said:
Then stop going on about lcc-win It is the only one you pick on.

It is the only one that is constantly and remorsely plugged here by its
owner. Nevertheless, if you are bothered by other people mentioning
other compilers here, tell them so. If you can't be bothered to mention
the fact yourself, you can hardly blame others for not doing so.
It cost no one anything to download and try.
If they like it or not it is up to them.

What has that to do with the price of fish? There are a great many
products available for people to download and try at no cost. That
doesn't make those products topical in comp.lang.c.
 
J

jacob navia

Keith said:
Nonsense. It can be used unsafely, but (unlike, say gets), strcpy can
be used perfectly safely. You just have to make sure that the target
array is big enough to hold the source string, which is easy enough to
do.
Easy enough to do it once.

Or maybe twice...

But since C discards all array size information when passing a
pointer to a function, and C strings are very often
copied in buffers that are passed around, it is
highly unlikely that you will ALWAYS win and NEVER
make a mistake.

The problem with strcpy design is that it requires always
perfect code.
 
J

jacob navia

Richard said:
Chris Hills said:


It is the only one that is constantly and remorsely plugged here by its
owner. Nevertheless, if you are bothered by other people mentioning
other compilers here, tell them so. If you can't be bothered to mention
the fact yourself, you can hardly blame others for not doing so.


What has that to do with the price of fish? There are a great many
products available for people to download and try at no cost. That
doesn't make those products topical in comp.lang.c.

BUT THIS THREAD WAS ABOUT:

< quote >

Can anyone suggest me a good compiler for(c/cpp) for windows?

< end quote>

I replied in the context of THAT question, I am not spamming
anyone!!!!

HOW MANY TIMES I HAVE TO REPEAT THAT???
 
R

Richard Heathfield

Chris Hills said:
This gets us into the discussion about the "secure" library that MS
has pushed into an ISO Technical Report with their so-called safe
functions.....

Er, indeed. But if I wanted someone to design a library of safe
functions for me, Microsoft wouldn't exactly leap to mind as my first
choice.

I wish I could be sure the ISO C committee would be of the same mind.
 
R

Richard Heathfield

jacob navia said:

But since C discards all array size information when passing a
pointer to a function,

No, it doesn't. It just doesn't explicitly pass that information to the
function of its own accord. This is the kind of silly thoughtless
comment that does you so much harm in clc. C *never* discards array
size information. The size of, and the number of elements in, an
in-scope array is *always* available via sizeof, and is *never*
discarded.

The problem with strcpy design is that it requires always
perfect code.

Indeed, the problem with programming is that it requires perfection.
 
R

Richard

Richard Heathfield said:
Chris Hills said:


It is the only one that is constantly and remorsely plugged here by its
owner. Nevertheless, if you are bothered by other people mentioning
other compilers here, tell them so. If you can't be bothered to mention
the fact yourself, you can hardly blame others for not doing so.

*blink* What an amazing attempt at a cover up.
What has that to do with the price of fish? There are a great many
products available for people to download and try at no cost. That
doesn't make those products topical in comp.lang.c.

They are if someone asks for advice from seasoned C programmers and the
get some good answers. As happened in this case. Maybe someone is
looking for a good standards compliant compiler and IDE.
 
R

Richard Heathfield

jacob navia said:

BUT THIS THREAD WAS ABOUT:

< quote >

Can anyone suggest me a good compiler for(c/cpp) for windows?

< end quote>

Yes, that's right. And the proper answer is: "You would get better
answers to this question by asking in a group where Windows programming
is discussed, such as comp.os.ms-windows.programmer.win32"
I replied in the context of THAT question, I am not spamming
anyone!!!!

HOW MANY TIMES I HAVE TO REPEAT THAT???

Zero, for preference. Starting now, if you'd be so kind.
 
K

Keith Thompson

jacob navia said:
BUT THIS THREAD WAS ABOUT:

< quote >

Can anyone suggest me a good compiler for(c/cpp) for windows?

< end quote>

I replied in the context of THAT question, I am not spamming
anyone!!!!

HOW MANY TIMES I HAVE TO REPEAT THAT???

That was the original subject of this thread. I've looked over the
thread on Google Groups, but I lack the patience to read the whole
thing (again).

I would have no particular objection to your mentioning lcc-win32 in
the context of answering the original question. I may have missed
something, but I don't recall anyone complaining specifically about
that. (I would suggest that you acknowledge your connection to
lcc-win32 when you mention it.)

Unfortunately, the discussion has drifted considerably, to the point
that this thread has become mostly an argument about what is or is not
topical in this newsgroup. In the context of that discussion, a
number of people have commented on things you've posted *in other
threads*.

I think everyone knows by now that lcc-win32 is one of the C compilers
available for MS Windows. I suggest that any comments about whether
jacob's postings are topical should be made only in direct response to
those postings. The discussion here has become so vague that I don't
believe any resolution is possible.
 
C

CBFalconer

Chris said:
.... snip ...

BTW I sell compilers and supply FREE software & source code (that
isn't FOSS) Also I have other interest that I don't usually
advertise.

You keep using that word "FOSS". What, if anything, does it mean?
 
C

CBFalconer

Richard said:
.... snip ...

They are if someone asks for advice from seasoned C programmers and
the get some good answers. As happened in this case. Maybe someone
is looking for a good standards compliant compiler and IDE.

In which case they should probably avoid lcc-win32 like the plague,
considering its many unusual (and standards contravening)
extensions. I may well be mistaken in this.
 
C

CBFalconer

jacob said:
.... snip ...

Can't you READ at least?
The ORIGINAL POSTER question was:

< quote >

Can anyone suggest me a good compiler for(c/cpp) for windows?
.....

This is at least the third time you have posted this identical
reply in the past few hours. Consider using some restraint.
 
C

CBFalconer

jacob said:
Easy enough to do it once. Or maybe twice...

But since C discards all array size information when passing a
pointer to a function, and C strings are very often
copied in buffers that are passed around, it is
highly unlikely that you will ALWAYS win and NEVER
make a mistake.

The problem with strcpy design is that it requires always
perfect code.

No, it requires that the programmer be able to read the routine
description, and then it would be helpful if s/he could remember
the requirements, i.e. be capable of learning. The description is
easily found in N869, harder in N1124 (because that is in .pdf
format).
 
C

Chris Hills

Richard Heathfield said:
Chris Hills said:


Er, indeed. But if I wanted someone to design a library of safe
functions for me, Microsoft wouldn't exactly leap to mind as my first
choice.

I wish I could be sure the ISO C committee would be of the same mind.

I was never happy about it.
 
R

Richard Heathfield

Chris Hills said:
[...] if I wanted someone to design a library of safe
functions for me, Microsoft wouldn't exactly leap to mind as my first
choice.

I wish I could be sure the ISO C committee would be of the same mind.

I was never happy about it.

You make it sound like it's already happened. Does this mean C is going
to get weighed down with a lot of Microjunk?

C99 was bad enough. How much damage do you think the language can stand
before it breaks under its own weight?
 
C

Chris Hills

Off list because this is political and my own personal views that may
not concur with other members of the ISO c panel
[...] if I wanted someone to design a library of safe
functions for me, Microsoft wouldn't exactly leap to mind as my first
choice.

I wish I could be sure the ISO C committee would be of the same mind.

I was never happy about it.

You make it sound like it's already happened. Does this mean C is going
to get weighed down with a lot of Microjunk?

Yes. I argued against it from the outset over 5 years ago The Safe(r)
C/ Secure / etc lib proposal is a clever move. There is also one for
C++ Again largely put about by MS. The problem is that although it is
"only a TR" as MS keep pointing out "TRs invariably become part of the
standard" even is these don't the effect is the same dor the vast
majority of desktop programmers.

This means that [marketing speak] the MS C and C++ libraries are The
Standard for safe programming .... MS is leading the way etc.

Anyone who does not implement the Safe/secure libs in the TR can not
really be serious.... MS has of course already got them implemented.

MS is also going via ECMA to push the C++/CLI standard on a fast track
through ISO this has been stopped once but I fear in reality it is too
late.
C99 was bad enough. How much damage do you think the language can stand
before it breaks under its own weight?

Too late it has happened.

However there is already discussion in some parts of the ISO C panel to
REMOVE parts of C99!! Yes the penny has finally dropped that too much
was added for small pressure groups and a lot has not been implemented
nor is ever likely to be by the majority...

We are now 9 years since the release and there is no sign that any time
soon the majority of the compiler vendors will do more than a partial
implementation.

In fact 4 years ago a group in the UK of which I was one and some of
whom were on the UK C panel, looked at cutting back C99 but we did not
have the time or resources to do it. We all had real lives and jobs to
do.

Now the main ISO C panel has woken up to the fact that C99 is not being
implemented in any seriousness by anyone. In fact as predicted about 5
years ago by Derek Jones the GCC standard (but NOT the compilers) would
become the major de-facto C standard.

A real mess. I can see there being several groups.

1 MS/desktop "C/C++" (I know c/c++ is not a real language :) Using the
secure/safer libraries etc for the vast majority of desktop users and
"embedded XP users" Shirley an oxymoron. This will be "Standard C"
because they have God/Satan on their side depending on your viewpoint.
Also all the lawyers and marketing.

2 Embedded C (based around C95) for the vast majority of non desktop
users and will be called "C-like" by the pedants and C by embedded
users.

3 Gcc Users who will use Gcc syntax come hell or high water who don't
care what anyone else calls it because they have god on their side.

4 ISO C used by virtually no one. (Where then for Clc? )

Remember ISO BASIC....... that died after a similar onslaught by
VisualBasic.

I fear Standard ISO C will go the same way.

Does it matter if it does?

I have to look at this is some seriousness as we are gearing up to start
MISRA-C-3. Thus far we have been C90+A1+TC1+TC2 based..... we have been
contemplating moving to C99 but..... it is all a moving target.


Regards
Chris
 
F

Flash Gordon

jacob navia wrote, On 27/07/07 09:17:
Chris said:
Richard Bos said:
[snips]

Mr Navia, however, is in a different position. He is touting a
product.

A FREE product.

"This software is not freeware,
It is freeware it is just not FOSS. There are many types of licens fro
free SW.

it is copyrighted by Jacob Navia.

Is this his crime?

It's
free for non-commercial use, if you use it professionally you have
to have
to buy a licence."

So what?

So it is _not_ actually freeware. It's shareware.

So what are the versions of Linux and Gcc you have to pay for?

For instance this ones:
Red Hat Enterprise Linux Advanced Platform
Standard Subscription 1 year 12x5 phone support, 1 year web, unlimited
incidents 1 499 $
Premium Subscription 1 year 24x7 phone support, 1 year web, unlimited
incidents 2 499 $

Or you get exactly the same SW from another source (called CentOS) for
free and you can use it professionally and even sell it on if you can
find someone to buy it.
Raleigh, NC (Business Wire) - June 28, 2006 - Red Hat, Inc.
(NASDAQ:RHAT), the world's leading provider of open source solutions to
the enterprise, today announced financial results for the first quarter
of its fiscal 2007 year.

Total revenue for the quarter was $84.0 million, an increase of 38% from
the year ago quarter and 7% from the prior quarter. Subscription revenue
was $71.5 million, up 45% year-over-year and 7% sequentially.

Now point to the posts here by RedHat employees or shareholders
advocating one of the above. Advocating Fedora does not count since that
is free to download from RedHat.
 
C

Chris Hills

Flash Gordon said:
jacob navia wrote, On 27/07/07 09:17:
Now point to the posts here by RedHat employees or shareholders
advocating one of the above. Advocating Fedora does not count since
that is free to download from RedHat.

LCC-win is free to download and use. Like Fedora it has a license

show me the Fedora I can use, adapt and sell on without disclosing the
source?
 
J

JT

LCC-win is free to download and use
Like Fedora it has a license

Say my company wants me to write a short C
program to convert some legacy files
from old format to new format.

If I donwload Fedoca Core and install it on my company computer.
Then I download and use gcc to compile and run the C program.
That's legal.

If I download and use lcc-win to compile and run my C program
without paying Jacob first, then I've broken the law.

There is a HUGE HUGE HUGE difference between
the licenses of gcc/linux/freebsd/apache...
versus the license by Jacob Nadia

Is this clear enough?
 
K

Kelsey Bjarnason

[snips]

It goes beyond your comprehension that strcpy is unsafe by design?

It is? Hmm. News to me. I've been using it for, well, 20 years give or
take, never had an issue with it. Wonder why that is?

Oh, yes - because, as with all tools, I learned how to use it properly.

strcpy is no more or less safe than most other functions, when used
properly. When used improperly, well, what do you expect if you let a
semi-educated chimp write code?
 
K

Kelsey Bjarnason

[snips]

Easy enough to do it once.

Or maybe twice...

But since C discards all array size information when passing a
pointer to a function

It does no such thing; it merely doesn't include it. It's readily
available to the caller, though, so not like you can't pass it if you need
it.
, and C strings are very often
copied in buffers that are passed around, it is
highly unlikely that you will ALWAYS win and NEVER
make a mistake.

Lots of ways around this, but the simplest and most basic is proper
design. If you're the sort to code first, design later, fine, you're
going to get bit by this. That's what you get for bad programming
practices.
 

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

Forum statistics

Threads
473,776
Messages
2,569,602
Members
45,184
Latest member
ZNOChrista

Latest Threads

Top