Re: Requesting advice how to clean up C code for validating string represents integer
- From: Flash Gordon <spam@xxxxxxxxxxxxxxxxxx>
- Date: Tue, 20 Mar 2007 20:48:42 +0000
Robert Maas, see http://tinyurl.com/uh3t wrote, On 20/03/07 09:18:
From: Flash Gordon <s...@xxxxxxxxxxxxxxxxxx>(which was true at the time I wrote it)Unfortunately
without access to the 1999 standard, this decision will be
difficult to implement.
It's a good job you have access to it then, isn't it.
At the time you wrote that, I didn't yet have access. But as soon
as I saw your article the next day or so, things might have
changed. Let me check...
Links have been posted in replies to your messages before, so if you do not have access it is because YOU have chosen not to have access.
If no one has given you the details before, then go here
http://www.clc-wiki.net/wiki/c_standard and follow the links.
That WebPage doesn't have a links section, however when I first saw
Not one section, but lots of links including in the section you mention below.
your article, before I had time to post nor time to read the Web
pages linked, I did manage to find these two links that might be
useful, from somewhere in the Wiki page, I have no idea where,
although if I search for the Linkname text I might find them again:
Linkname: c standard - clc-wiki
URL: http://www.clc-wiki.net/wiki/c_standard#Obtaining_the_Standard
Hmm, I seem to have bookmarked a section in that same Wiki page.
It says:
Neither the Standard nor its amendments are available free of charge,
I think that kills the issue for me.
Then you are either incapable of reading more than one sentence, too lazy to bother reading more than one sentence, too stupid to read more than one sentence, or trolling. Since the very next sentence tells you that you can get what you want.
<snip>
According to that statement and your web page that means you do not
understand C. Your cookbook still has this prototype given in what is
meant to be C "int g2(int n1,n2);" despite it having been pointed out to
you and you having read the post and commented about it.
I don't recall either the critique of that nor my response.
Checking Google I see indeed somebody said something was wrong with
that but didn't say what was wrong, so I asked for clarification,
but nobody ever answered, so I still don't know what was supposed
to be wrong, nor even whether there is anything wrong in the first
place or you are just <cliche>pulling my leg</cliche>.
If you cannot be bothered to put it through a compiler or read any vaguely correct resources that is your problem.
<snip>
For example, buffer overflow is natural with pointer arithmetic,I've never had to go back over all of any significantly complex program
all you need is a teensy programmer bug overlooked admist the
kilometers of source code that needs eyeballing to find anything,
but buffer overflow is impossible in Java or Common Lisp.
I've written.
Hey, does the Pope know about you? He's always looking for another
good candidate for Sainthood, and if you have never made a mistake
in your whole life then I think he should seriously consider you,
even if you're not Catholic, after all Jesus wasn't Catholic
either, and the Church rates him even better than a saint.
I never said I was perfect nor that I never have to fix bugs, just that I never have to go back over all of the program. If I did I would probably still be on my first C program since that was certainly in the 10s of thousands of lines of C. Obviously I had written a lot of code in other languages before I started C!
Is 20% speed gain really more important than security?
Depends. Do you want to crash in to the car in front because your
breaks did not apply in time? There are times when speed (or
consistency of speed) is just as important a requirement as any
other.
Anybody who would design a passenger vehicle with the only path
between brake pedal and brake pads being through a complicated
computer program would IMO be a fool.
Stay off aircraft and away from flight paths then, since a lot of aircraft are fly-by-wire (i.e. controlled by computers) then. Have you been asleep for the past decade?
<snip>
There are far too many misconceptions in your web pages, such as
being able to compare unrelated pointers, ...
So long as the pointers are of the same type, there's nothing
impossible with comparing them, which will tell you whether the
objects pointed-at are this way or the opposite with respect to
each other in memory. If you think a program is not able to compare
the pointers, please explain your reasoning.
You show your ignorance and the fact you don't bother to read again. It has been stated many times in the past that comparing pointers that do not point in to the same object (or 1 past the end) for anything other than equality invokes undefined behaviour. It needs no more reason than the standard state it.
<snip rubbish>
right shifting a negative number 0 fills
It depends on whether you are talking about arithetic shift or
logical shift.
C does not have "arithmetic shifts" and "logical shifts" it only has shifts which do not necessarily zero fill..
> Can you cite the paragraph where I said something
confusing to that point?
Yes, just above here.
* being for dynamically allocated objects only, [] being for
"static-allocated" objects only.
I'm sure I never said any such thing. You're misreading, or lying.
I doubt I would have said you said it if you did not, but I'm not going to bother re-reading your pages until there has been some indication that you have actually learned something. After all I tend to only bookmark things which might be either useful or interesting, your web site is neither.
--
Flash Gordon
.
- References:
- Re: Requesting advice how to clean up C code for validating string represents integer
- From: Robert Maas, see http://tinyurl.com/uh3t
- Re: Requesting advice how to clean up C code for validating string represents integer
- Prev by Date: Re: Quine
- Next by Date: Re: BUG: memory where pointer pointing to changed accidently
- Previous by thread: Re: Requesting advice how to clean up C code for validating string represents integer
- Next by thread: When to use alternative argument layout?
- Index(es):
Relevant Pages
|