Efficency and the standard library

I

Ian Collins

Richard said:
Because in picky mode they often point out real code problems that they
don't point out in non-picky mode. The earlier you discover the bug, the
cheaper it is to fix it.

I guess it depends on what you define as picky. I mainly works with Sun
CC, which issues considerably more warnings in default mode than gcc,
but significantly fewer than Sun's lint.

That gives me the best of both worlds, fast compilation during
development (I compile a lot) and pedantic application or library wide
warnings for daily builds.
If I were writing (or, still pretty unlikely but rather less unlikely,
specifying) a compiler, I'd want its default setting to be maximally
picky. Anyone who doesn't want that could switch OFF warnings, either
individually or by small inter-related groups.

I'd rather add warnings and have faster builds, but that's a matter of
personal preference.
 
S

Seebs

Why should they?

Because it catches errors.
If you want to analyse code, use a tool like lint.
Let the compiler focus on compiling legal code quickly and accurately.

It turns out that in practice, a whole lot of the work needed to do that
overlaps heavily with the work needed to produce the warnings.

More pragmatically, people tend not to put tools like lint in their
compilation path, which means that they don't notice warnings until there
are too many to deal with, which means they don't get fixed.

-s
 
S

Seebs

I didn't realise he'd got around to fixing that one. I don't have a copy
of CTCR3, for obvious reasons.

To clarify:

2E: Both sizeof and use of <> as !=
3E: Sizeof still wrong, != fixed
4E: Sizeof fixed too, but as I recall in an unidiomatic way

-s
 
B

BruceS

The real vulgarity is the treatment that I and many others have been
subjected to in this newsgroup. Others mistreated here include C
compiler developer Jacques Navia, who has attempted to use this
newsgroup, as I am, for technical discussion only to have his good
name dragged in the mud by two incompetent programmers here, Richard
Heathfield and Peter Seebach.

I think I recall Navia from some time back, as another who repeatedly
painted himself as an arrogant incompetent. If I'm confusing him with
someone else, I apologize in advance for my being too lazy to research
it. Otherwise, it makes perfect sense why you identify with him.
FWIW, to people like me, Heathfield and Seebach don't make you look
foolish or incompetent; you do that all by yourself.
The former has written a poorly-received
book with far more, and far more global, errors than Schildt, who is
being scapegoated here for the incompetence of the regulars. The
latter started the anti-Schildt canard by attacking his book when he
could not extort money from McGraw Hill, and has repeatedly posted
erroneous code, and Seebach is distinguished, if that is the word, by
having taken a grand total of zero classes in computer science at
university or thereafter.

I've only been in the business since the mid '80s, but in that time
have worked with several people who had taken no CS classes, yet
managed to be quite skilled as programmers. I also worked with some
who had great credentials, including one who had a Masters in CS from
(IIRC) Yale, but were demonstrably unqualified to write code. My own
degree is a BS in CSS from a third-rate school, but it did me no
harm. I still get great compliments from coworkers and customers, and
get paid enough to get lots of pretty trinkets. IME, there's little
correlation between formal education in CS and actual ability.
Feminized males in corporations don't defend their reputations: this
is "disruptive". I defend mine.

Feminized, disempowered, weak and soft males have been taught by bimbo
feminism and the corporation to simply look the other way when evil
occurs whether here, in the corporate world, or in Palestine. They
reason that if someone's getting his ass kicked, he must have deserved
it. They reason that if someone fights back, he must be a terrorist.

Feminized males, Palestinians, terrorists? Weren't we discussing
programmers and authors? Is this where you start calling me an anti-
Semite, or a Zionist, or maybe veer off into another direction and
accuse me of being part of some bizarre conspiracy?
You have poor reading comprehension indeed, because you have read one
or two posts

At times I think that would have been wiser, but I'm afraid the count
is rather higher than that.
and jumped to a conclusion. When I am treated with
dignity, collegiality, and respect, I respond in kind to people like
Professor Massengill and others right here. I conducted myself with
enough dignity, collegiality, respect and technical acumen to be
selected to assist John Nash with C at Princeton University.

Name dropping is not very impressive. It appears to me that you
resort to vulgarity quickly when your repeated failure to understand
something leads another to frustration far short of your own rage.
This doesn't seem to impress anyone with your qualifications, but
rather make them more likely to just tune you out. I suggest you'd do
better with less vitriol, more careful fact checking, and a greater
attempt to understand what's being explained to you.
However, I am quite past the point of showing patience with break-room
antics here: back-stabbing, childish name-calling insults, and
scapegoating others for errors we ALL make in a complex business.

And you can take it as read that I will fight fire with fire. I will
call people "names". The difference is my evidence. When I call Peter
Seebach an "incompetent" my evidence, if needs be in a court of law,
will be his attempt to simulate strlen() with a newbie's off by one
bug, his "replace %s" that replaces all percent signs, and his self-
confessed lack of ANY academic qualifications.

When I call Richard Heathfield a thug, I repeat my evidence of his
false "humility" unlinked to charity, his enabling of others'
bullying, his name-calling, and his lack of any substantive technical
contributions to this newsgroup other than break room programming
saws.

My book, "Build Your Own .Net Language and Compiler" is still selling
well and has in the past ranked among the top ten compiler books on
Amazon. It describes technology that is a complete mystery to the regs
here. I suggest you buy a copy: I can use your money, and it would be
a worthwhile investment on your part.

I doubt that. If I were interested in building a .NET language, I'd
get a book that actually addressed it. From what I've read about
yours, it sounds like it doesn't do that. As it is, I have little
enough interest in building a new language that I won't spend time on
confirming or countering those reviews. I *did* buy a copy of C99,
and consider that a good use of my money. We all have different
special interests, which is of course in no way an invalidation of
others' special interests.
 
I

Ian Collins

Seebs said:
Because it catches errors.


It turns out that in practice, a whole lot of the work needed to do that
overlaps heavily with the work needed to produce the warnings.

That's true and I think Richard and I had different reference points for
compiler pedantry. I use Sun cc witch is a lot more pedantic than gcc
in default mode (as anyone who has ported Linux code to Solaris will
know). While a lot of the analysis is similar to that required for
optimisations, it does slow the compilation process significantly. The
analysis is also limited to the file being compiled, while lint can
perform analysis over a complete application or library.
More pragmatically, people tend not to put tools like lint in their
compilation path, which means that they don't notice warnings until there
are too many to deal with, which means they don't get fixed.

That is a problem, but it is one of process not tools. For example, a
lint pass is included in the OpenSolaris build process which helps to
keep that project's code clean.
 
I

Ian Collins

santosh said:
Apparently though, unsigned long is still 32 bits even under 64 bit
versions of Visual C. That's indeed a very strange choice, but I
guess there was a compelling reason for it.

Lots of 4s in their code perhaps?
 
I

Ian Collins

Nick said:
which compiler *does* come with reasonable default options!

Sun cc/c99. You have to add a lot of options to gcc to get the same
degree of checking.
 
S

spinoza1111

I think I recall Navia from some time back, as another who repeatedly
painted himself as an arrogant incompetent.  If I'm confusing him with
someone else, I apologize in advance for my being too lazy to research

Yes, you are too lazy to research it. You don't give a **** about
reputations because you have none of your own, and you'd like to drag
others down.
it.  Otherwise, it makes perfect sense why you identify with him.
FWIW, to people like me, Heathfield and Seebach don't make you look
foolish or incompetent; you do that all by yourself.

How do I do that? By posting, discussing and debugging code here as
intended? You are literally afraid of your own Shadow, since what you
express is the fear you have of your OWN exposure and your OWN
weakness.
I've only been in the business since the mid '80s, but in that time
have worked with several people who had taken no CS classes, yet
managed to be quite skilled as programmers.  I also worked with some

How would you know?
who had great credentials, including one who had a Masters in CS from
(IIRC) Yale, but were demonstrably unqualified to write code.  My own

This usually means "unqualified to write code in the way that an
unqualified and sometimes criminal management commands".
degree is a BS in CSS from a third-rate school, but it did me no
harm.  I still get great compliments from coworkers and customers, and
get paid enough to get lots of pretty trinkets.  IME, there's little

It's not all about money. The fact you think it is is part of the
problem.
correlation between formal education in CS and actual ability.



Feminized males, Palestinians, terrorists?  Weren't we discussing
programmers and authors?  Is this where you start calling me an anti-
Semite, or a Zionist, or maybe veer off into another direction and
accuse me of being part of some bizarre conspiracy?

No, I see parallels which you don't because you're uneducated and
incurious.
At times I think that would have been wiser, but I'm afraid the count
is rather higher than that.


Name dropping is not very impressive.  It appears to me that you
resort to vulgarity quickly when your repeated failure to understand
something leads another to frustration far short of your own rage.
This doesn't seem to impress anyone with your qualifications, but
rather make them more likely to just tune you out.  I suggest you'd do
better with less vitriol, more careful fact checking, and a greater
attempt to understand what's being explained to you.

There is nothing to understand in these cases except folklore created
by corporate recruits who never were properly educated for their job.
 
S

spinoza1111

spinoza1111wrote:


No, you do it by posting:

(a) long pseudosociological diatribes;

They're not pseudo, since they are sourced.
(b) puerile scatological expletives;

I've explained why I've recently started. It's to demonstrate by
example that ruining people's reputations in a public network is much
worse than saying "**** you".
(c) excessive personal attacks, including but by no means restricted to
"Nazi", "Fascist", "fag", and so on;

I've explained that the technical lower middle class IS at risk for
Fascism, and I have nothing but contempt for homosexuals who have
benefited from the fag movement only to take out their resentments by
using the sort of "bashing" language they were subject-to. I am
referring to Seebs.
(d) lunatic claims against specific individuals (for example, you have
claimed that Sams and MI5 pay me to do Usenet);

No, SAMS, MI5 or, not and. And indeed this is just one possible
explanation of the psychotic way you constantly interfere in
constructive discussion in order to change the subject from technology
to people's qualifications.
(e) hasty and erroneous conclusions and then, on being shown to be
wrong, posting equally hasty equally erroneous conclusions in the other
direction;

Get a clue. That's called "work" in which people form explanations and
then reject them when further information, converging through
willingness to change direction on a solution, such as my replace code
which is superior to anything else I've examined. It's much preferable
to the way in which you nail yourself to the mast, insisting on being
right about some vague and useless point whilst forcing people who
disagree with you to defend, not their points, but their professional
status.

(f) accusations of illiteracy, "aliteracy", and general lack of education;

Sorry, but it's pretty obvious. Seebach is one example, who by
majoring in psychology manages to be neither fish nor fowl: neither a
proper scientist ("the 'heap' is a DOS term") nor able to express
himself well ("Herb is clear but he has thousands of bugs, and here
are twenty and there are more").
(g) accusations of "campaigns of personal destruction";

I am by no means the only one to say this. Richard, Kenny McCormack
and others have said that you and your mates have done this.
(h) bald assertions with no supporting evidence, and not providing that
evidence when asked;

You're lying. I'm one of the few posters to post references to actual
books which constitute "evidence". You don't post code anymore if you
ever did, because you are unwilling to be subject to the same
personality destruction to which you subject others. Instead, your
"evidence" is corporate folklore.
(i) replies (sometimes one-liners) that are made many (sometimes
hundreds of) times longer by your inability or refusal to snip material
that you are not addressing;

Big deal. You need to start showing less respect for machines and
networks and a modicum of decency and respect for PEOPLE.
(j) replies to technical articles that show little or no understanding
of the issues or indeed the language under discussion;

Actually, the problem is that I have a deeper understanding, having
worked as a programmer continuously from 1971 to 2005 internationally.
What I don't "understand" is the corporate folklore, a set of inchoate
saws that was created by the fact that as data processing became a
cost center, it needed only be staffed by inferior people who could be
uneducated and pliant enough to work to rule and folklore.
(k) code that appears to be deliberately designed to take a long time to
read, which is fine in IOCCC but not in clc.

News flash, Dickie Wad. You don't have to read rows of asterisks in a
box comment. They are merely there to show you that "this comment
leads off the code and should be read".
 
S

spinoza1111

spinoza1111wrote:


You do often come to conclusions that are not supported by the
references and post references that you clearly have not read.
Many of your CS references are are 20 plus years old.

The coding examples and approach reflects the technology of
the past.

That's bullshit. In fact, coding practice is in decline. An example is
the abandonment of pre-Szymonyi Hungarian notation by lazy
programmers, and the mess that is "standard" C. An example is the
contrast between NASA software development and general engineering
which supported several Moon missions, and the crashes of Challenger
and Columbia, as well as the fact that the Space Shuttle never flew as
high as Apollo, Gemini, or even Mercury. An example is the use of
Powerpoint and poor software to "demonstrate" that Saddam Hussein had
WMD. An example is the use of poorly understood "rocket science"
software that caused the credit crisis and today's Depression, in
which thousands of programmers have permanently lost their jobs.

Furthermore, some of the most useful principles of good software are
mathematical results, getting their utility from rugged truth, and
mathematical results when true NEVER go "out of date". We still know
that all control structures are Bohm Jacopini. We still know that a
Turing machine cannot detect whether another will halt.

Furthermore, amongst programmers, basic literacy as observed by their
English teachers is in rapid decline, which means that most
programmers are literally unable to express what their code does or
why they coded it, and have as a result to become other-directed,
appealing as does Seebach to custom, and refusing to try to understand
the code of some programmer who fails to use their shibboleths. As a
result they lash out as we see here in infantile rage, calling their
colleaugues "morons" and "idiots" and "verbose". As a result they make
racist jokes about Indian developers when their management sends their
work assignments abroad, being unable to instruct those developers in
a common world English as to what's needed.
 
S

spinoza1111

spinoza1111wrote:


You asked how you make yourself look incompetent. If you don't like my
answer, that's no skin off my nose. Your objections are noted, spurious,
and snipped.

Shut up and post code, or get out. You have NO credibility. You have
not participated in the replace() discussion apart from an idiotic
comment to the effect that including an #include of malloc.h was a
bug, which it is not, and apart from impugning people's reputation.

You've attacked real developers such as Navia on completely spurious
grounds, making false accusations that he's using this ng for profit
when in fact many people come here to get on the job assistance in for-
profit corporate jobs, and when Navia has WRITTEN A COMPILER and CAN
WRITE. You attacked a real developer for wanting to use pointer to
void, and claimed elsewhere that you use it yourself, which means you
make self-contradictory statements, one of which is a lie of
necessity, in order to confuse the situation.

You're a little cheap assed thug. Shut up and post code or leave.
 
N

Nick Keighley

Wouldn't a picky compiler complain about your use of pointer to void
in your linked list tool?

there is no standardised definition of "a picky compiler". The
Standard mandates certain diagnostics. The implementor is permitted to
produce any other diagnostics he feels like. It is common practice
(but by no means universal) to produce "error" messages for Standard
mandated diagnostics and "warning" messages for optional dignostics.
This can confuse people. "why does this code give warnings if I
increase the warning level?".

So picky compilers tend to produce warnings that in the implementor's
mind are dodgy practices. Well known C idioms tend not to attract
warnings.

This attracts a warning in many compilers
if (n = some_func())
It might be correct or it might not. Many compilers that warn about
the above don't warn about this
if ((n = some_func()))
It is assumed the extra pair of brackets is a signal "I really meant
that!".

Using void* as a generic pointer is idiomatic C. What else would you
use a void* for? I think on balance most reasonable compilers wouldn't
issue warnings for this sort of usage of void*. If you disagree then
patch gcc!


--
-pedantic
This option is not intended to be useful; it exists only to satisfy
pedants who would otherwise claim that GNU CC fails to support the
ANSI standard.
(Using and Porting GNU CC)
 
B

blmblm

[ snip ]

[ snip ]

I rather regret providing an opportunity for yet another long post
about matters most people in this group will find off-topic. I did
read your reply but will follow up only on a couple of points.
In programming, what Dijkstra called
the "cruelty" of computer science is the fact that it presents Father-
like demands,

This association between CS and "Father-like demands" -- is this
yours, or Dijkstra's? (Sometimes I do wonder what he would have made
of what you say about him here.)

[ snip ]
I like it when women act like the best of men: competently, wisely,
compassionately and never pointing the finger at a scapegoat, instead
(like you) focusing on problem solving.

You give me more credit than I think I deserve. Julienne Walker,
now -- *she* seems able to focus on technical matters and avoid
being pulled into pointless wrangling. Well, whatever.

[ snip ]
 
B

blmblm

This brings up a vaguely topical question:

Can anyone name a dialect of C that has ever not supported variable
initialization?


MS is not famous for great compiler work, or for reasonable default
options.

Well, in all fairness, the default warning level for gcc is pretty
low also, no? I don't have experience with commercial C compilers;
are they in general better?

Speaking of gcc and warnings .... One of my semi-crusades as
someone who teaches C to undergraduates is to convince them
to always, always compile with at least -Wall. Some of them
are surprisingly resistant, which I find baffling. I guess I
should ask, but -- I wonder whether it's the extra keystrokes,
or the fact that they get more messages they don't know what to
do about, or what. Maybe I just need to come up with compelling
examples of warnings that really do help point out problems that
would otherwise show up at runtime and be difficult to debug?

(Vaguely topical, I hope?)
 
B

blmblm

[ snip ]
[ .... ] Professor Massengill [ .... ]

That's twice -- well, sort of, because this time you came a little
closer to spelling it right, though the variant you chose does
lend a bit of credibility to Seebs's suggestion about whether
the spelling mistake is a simple typo or something else. (I'm
uncertain about whether to add a :) here.)

I have not said whether "Professor" is an appropriate title,
and academics can be so touchy about such things, so I'd just as
soon you didn't use it.

How about if you just call me by the short form (blmblm) of the
e-mail address I use here?

[ snip ]
 
B

blmblm

[ snip ]
I've explained that the technical lower middle class IS at risk for
Fascism, and I have nothing but contempt for homosexuals who have
benefited from the fag movement only to take out their resentments by
using the sort of "bashing" language they were subject-to. I am
referring to Seebs.

"fag movement"? How is that *not* gay-bashing ....

(And while I'm at it -- the phrase you use elsewhere, "feminized
men" -- how is that not .... No, no, never mind; I'm pretty sure
I don't want to, um, go there.)

[ snip ]
[ .... ] such as my replace code
which is superior to anything else I've examined.

Have you looked at the code posted by others here? On a quick
skim of your code and that of the others I've been benchmarking
(Harter, Bacarisse, Thomasson, and willem), all of them seem to be
roughly comparable with respect to solving the problem correctly
and efficiently, and the only one that's not at least as readable
as yours (in my opinion anyway) is willem's -- and he probably
wasn't trying for readable. Harter's code even contains copious
comments, which again on a quick skim seem pretty good to me.

What is it you think is superior about your code?

[ snip ]
 
S

spinoza1111

[ snip ]
[ .... ] Professor Massengill [ .... ]

That's twice -- well, sort of, because this time you came a little
closer to spelling it right, though the variant you chose does
lend a bit of credibility to Seebs's suggestion about whether
the spelling mistake is a simple typo or something else.  (I'm
uncertain about whether to add a :) here.)

Please don't imagine that he has any credibility. I was merely too
lazy to check the spelling, and frankly, people have abused my own
name too much for me to be all sensitive. It's news to me that
programming has progressed to the state where it is in any way equal
to proofreading, and I am very tired of Seeb's carelessness in
important issues, and his fantasy that Trivia and personalities is in
any way compensatory.

However, I will try to check the spelling of your somewhat unusual
name in future.
I have not said whether "Professor" is an appropriate title,
and academics can be so touchy about such things, so I'd just as
soon you didn't use it.

Here, my extra care is not compensatory, I see, any more than
Seebach's.
How about if you just call me by the short form (blmblm) of the
e-mail address I use here?
Deal.

[ snip ]
 
S

spinoza1111

spinoza1111  said:
[ snip ]

[ snip ]

I rather regret providing an opportunity for yet another long post
about matters most people in this group will find off-topic.  I did
read your reply but will follow up only on a couple of points.

It takes what it takes, and as programming drifts more and more into
accidental welfare for white males, the journey in language back takes
longer.
This association between CS and "Father-like demands" -- is this
yours, or Dijkstra's?  (Sometimes I do wonder what he would have made
of what you say about him here.)

It's called "literary interpretation", and only in the somewhat
outdated "New Criticism" of the 1950s do we take it as axiomatic that
the author was always fully conscious of his meaning. I think
Dijkstra, save in one comment (to the effect that Republicans think
programming is easy) never realized the political dimension of his
problems, and over-identified with Power, thinking that Power is
interested in accurate, humane software, something that only Labor
demands.

It's an interpretation. Since in the Somme and WWII the good men
didn't have a good war, the lesson was that men get killed
meaninglessly (as in passing bells for those who die as cattle) in a
monstrous industrial factory. Bad life cannot be lived well, so people
try to reconcile miserable conditions of existence, for example by
trying to find "skill and challenge" in programming when in fact it
was intended (by John von Neumann no less) to be a low level clerical
skill for people who didn't count.

In this connection, cf. When Computers Were People, Princeton. The
last human "computers" were in the 1940s human flotsam who were made
unemployable in the Depression and blamed for their problems, and by
the 1940s under constant suspicion of being Communists. Many of them
entered programming as "mere coders" and were expected to be again
unemployable when computers figured out how to program themselves.

In fine, a patriarchal society had demonstrated the fate of the
marginal very clearly at Stalingrad, Omaha Beach and Auschwitz and it
seemed that the fathers like von Neumann didn't care. Programming
viewed from the outside was seen as an easy job that could be a
catchall or sink for the marginal, and it remains so. As a result,
programmers are haunted by feelings of inadequacy and are for this
reason only too easy to scapegoat what they consider others'
incompetence, since this in a magical sense means that they are not
the mental midgets of their secret fair.

But in fact it is hard, taking not only humility but also charity
towards others, which I don't see in the regs. My own lack of charity
for Seebach replaced my earlier hospitality for very good reasons,
because when I turn the other cheek I get bitch slapped.
[ snip ]
I like it when women act like the best of men: competently, wisely,
compassionately and never pointing the finger at a scapegoat, instead
(like you) focusing on problem solving.

You give me more credit than I think I deserve.  Julienne Walker,
now -- *she* seems able to focus on technical matters and avoid
being pulled into pointless wrangling.  Well, whatever.

Actually, she gets at times into pointless wrangling when she tries to
make me behave.
 
S

spinoza1111

[ snip ]
I've explained that the technical lower middle class IS at risk for
Fascism, and I have nothing but contempt for homosexuals who have
benefited from the fag movement only to take out their resentments by
using the sort of "bashing" language they were subject-to. I am
referring to Seebs.

"fag movement"?  How is that *not* gay-bashing ....

It's only "gay bashing" in what I call the Chomsky 3 sense. That is,
for bureaucratic convenience rather than for real human rights,
bureaucratic machinery examines human language AS IF it were a series
of regular expressions, which when applied fully means that because "I
don't think you should call me a 'fag'" conforms to the regular
expression *fag*, it is disallowed: "don't ask, don't tell".

This not only occurs literally in certain automated tools with
Orwellian results, it's also applied to speech in such a way that
people, today, use a language that is considerably less vivid, and
fails consistently to add to human dignity, than our language of the
Sixties. Frankly, I encounter situations here of such absurdity, and
such a theater of cruelty, that the only sensible response is either
poetic (which I've essayed) or something like "shove it up your
ass" (which also seems to fit).

The movement for homo rights was on the street a fag movement. The
Chomsky 3 bureaucratic rule ignores intentions and treats speakers as
objects. But my intention was to draw attention that (in my opinion)
Seebach uses the liberation movements of the 1960s merely to unfairly
make his life easier and shit on others.

I was 18 when gays rioted at Stonewall. What it meant was that people
didn't have to go around in "character armor" denying their own
vulnerability, and one result in computing was the structured
walkthrough in which people would be "humble" on the one side, and,
perhaps even more important, unwilling to go off topic from problem
solving and start attacking people's credibility and qualifications,
as Seebach does. The effect is to me sickening, because as I've said
it's the delinking of humility from charity.
(And while I'm at it -- the phrase you use elsewhere, "feminized
men" -- how is that not ....  No, no, never mind; I'm pretty sure
I don't want to, um, go there.)

I will. Robert Bly, you know, the "men's movement" drumming in the
woods guy, ain't no joke. He's a real poet and a smart guy: I've met
him. He started the men's movement when he noticed how badly younger
post-Sixties males treated (1) their Moms and (2) their friends and
(3) their wives, and Bly was also horrified by the crap on the
Internet, where from day one people have said things they would not
say person to person (at the point where Seebie and Heathfield have
taken us, I WOULD invite them, person to person, to go ****
themselves).

He said "men learn compassion from their fathers". I think Seebach et
al. failed to learn this from emotionally or physically absent
fathers, whether those fathers were distanced by corporate jobs at IBM
which demanded unpaid overtime on projects like OS/360, or absented by
the divorces and family breakdowns which resulted from many
programming, engineering, and other types of jobs. So much so that the
men fortunate enough to have better fathers (which Seebs may very well
have had) learned the normalized deviance from their peers.

Despite Dijkstra's numerous enemies, you can search his quotes in vain
to EVER find him attacking another man by name or unique description.
In ALL cases, he describes GROUPS of people by describing GROUP
behaviors. Dijkstra was unaware, or did not care, that this always
makes trouble for the speaker.

Socrates described the folly of wealth, the folly of mob democracy,
and the love of wisdom that made it clear that he though most men,
including Athens' elite, to be fools, while Sophists were
strategically more clever: they would use the far commoner method of
scapegoating by selecting a unique person.

The result was Socrates' death, and Dijkstra's premature death from
the effects of lifelong clinical depression (according to Peter
Neumann, who I interviewed for my book). Dijkstra took out his own
anger on a group abstraction, the design of hardware and software
using foolish procedures, which was far more charitable than the sort
of specific attacks launched by Jean Sammet, John McCarthy and others
on their personal enemies. However, in the language of the ugly
corporate word "offend", Dijkstra was more "offensive" because many
people who read him could ask "does this not refer to me"?

If I write in an email that "Joe is a slob", this is safe as long as
Joe ain't a CEO and is below me or at my level. Whereas I discovered,
as did my female coworkers interested in best practice, that in the
corporate world it was almost always unsafe to diss a programming
language or practice, since in big corporations there could always be
some group using the idiotic praxis.

Men who learn compassion from their fathers are like Dijkstra anxious
to do things right like Dad, without attacking a named scapegoat like
Schildt. Whereas today, the normalised deviance is to always take care
to describe a sort of Chosen One or Monster, and to equate another
person with this fabular beast...as in the case where when someone
posts something intelligent and/or nonstandard here, and instead of
replying straightforwardly, posters start yapping about some "guy" who
used to work at their company or posted here in the old days, as if
the Chosen One or Monster could daemonically possess different people.

Seebach to his (limited) credit makes it no secret that, in what he
calls a timesaving gesture he will reject code that uses "quirky"
syntax but which given what I've seen of his skills is something more
than a timesaving gesture. But this reduces code reviews to adolescent
levels, where wearing the wrong sort of clothes ostracizes the "geek".
I always thought that to be the urbane, witty, intelligent guy that
some of my mates think I am, it is necessary to learn at least one
foreign language, to not get bent out of shape if someone wears
Speedos, and to also learn new computing paradigms in detail, as I
struggle to learn OO in the 1990s. But now I find that noooooo....the
Eternal Sunshine of the Spotless Mind is to get stuck in adolescence
until you fly a plane into a building or some shit like that.

Finally, it is true that unlike Dijkstra the Blessed, I attack people
by name. All I can say is that I've put up with their shit for too
long, after giving them the benefit of the doubt and asking them to
correspond privately. But they are cowards who flee this type of
encounter. Therefore I say, bring me the heads of Seebach and
Heathfield!
[ snip ]
[ .... ] such as my replace code
which is superior to anything else I've examined.

Have you looked at the code posted by others here?  On a quick
skim of your code and that of the others I've been benchmarking
(Harter, Bacarisse, Thomasson, and willem), all of them seem to be
roughly comparable with respect to solving the problem correctly
and efficiently, and the only one that's not at least as readable
as yours (in my opinion anyway) is willem's -- and he probably
wasn't trying for readable.  Harter's code even contains copious
comments, which again on a quick skim seem pretty good to me.

What is it you think is superior about your code?  

I solved the problem, which was to avoid string.h, and thinking
influenced by string.h, in which you have to start at one byte to the
right of the last point at which you did strstr (or its equivalent)
because strstr doesn't tell you where the one-character "handle" might
start to the left of this point.

The comments are not only highly literate, they are attractively laid
out in two dimensions within the limits of an Ascii view, as is the
code. I disciplined myself to keep nearly all lines (save two) within
67 characters, this being the limit imposed by the newsreader,
apparently. Each logical level has its own nesting.

I used literate and meaningful identifiers, and the use of pre-
Szymonyi "Hungarian" means I made a conscious and documented decision
as to data types (that's called "programming on purpose" as opposed to
the opposite, which ain't good in my book)

Because I released the code early in its development and because I not
only fixed each bug as it arose (unlike friend Seebach) the bug rate
diminished exponentially, approaching zero as a limit and not floating
maddeningly above zero at some large constant value, which happens to
be the case for most "working" software. I took the risk of the
cruelest form of mockery and abuse in this fucking slum so as to get
the insights of the decent people here in debugging, which is far and
away the best course.

I used the best possible algorithm within the constraint that I did
not choose to create auxiliary tables, which was to create a linked
list of segments where the target does not occur and then assemble
this linked list and each target occurence into the result string.
This was, I believe, the minimal algorithm in terms of time and memory
complexity within the constraint, along with Willem's elegant
solution, which uses extra stack memory.

I carefully tuned this algorithm using ideas from reading the Boyer
Moore CACM paper by restarting the search at the first occurence of
the first character of the target to the right of the previous
starting point, by noting this occurence in the search for the target.

Above all, I took pains. I realize that such craft, in the corporation
is now interpreted as "wasting" valuable (if unspecified) "resources"
in language that assumes I'm chattel because I don't own the means of
production. But I'm too old to start regarding Peter's slop as decent
code.

Any questions, blmblm?

I clearly deserve A+ if you ask me. I regard Willem's work as A+ and
although his style is radically different from mine, as a decent
programmer I do NOT use shibboleth as doth Peter Seebach. I dove right
into his code and read it, discovering his recursive insight...which I
helped him bring to fruition. I am all too familiar with people who
call themselves programmers but who can't and won't read unfamiliar
code, preferring personality destruction to Hamlet's "as a stranger
give it welcome".

Anyway, you asked for an apologia you got one.

You know, I really didn't know that my misspelling of your name was
also the name of a feminine hygiene product, because I'm not up to
speed in feminine hygiene. I live in Hong Kong ha ha. But speaking of
another meaning of apologies, I owe you one for that
confusion...despite the fact that *pace* Peter S, as in zip it,
knowing feminine hygiene, or its lack, hath zip to do with programming
as far as I can see.
 
S

spinoza1111

spinoza1111  said:
[ snip ]
When I use the words, "act like a man" I mean acting like a free and
independent moral agent who tries to do the right thing, like my
father for example, or me at my best. I think most of the male posters
here are not men but guys.
I'm inclined to think that the admonition "act like a man",
addressed to a woman, means something different from the same
admonition addressed to a man.  But it's possible I'm being
influenced by the difference between "he acts like a man"
(almost invariably positive) and "she acts like a man" (in some
contexts negative).  "Whatever", maybe.
I rather regret providing an opportunity for yet another long post
about matters most people in this group will find off-topic.  I did
read your reply but will follow up only on a couple of points.

It takes what it takes, and as programming drifts more and more into
accidental welfare for white males, the journey in language back takes
longer.


This association between CS and "Father-like demands" -- is this
yours, or Dijkstra's?  (Sometimes I do wonder what he would have made
of what you say about him here.)

It's called "literary interpretation", and only in the somewhat
outdated "New Criticism" of the 1950s do we take it as axiomatic that
the author was always fully conscious of his meaning. I think
Dijkstra, save in one comment (to the effect that Republicans think
programming is easy) never realized the political dimension of his
problems, and over-identified with Power, thinking that Power is
interested in accurate, humane software, something that only Labor
demands.

It's an interpretation. Since in the Somme and WWII the good men
didn't have a good war, the lesson was that men get killed
meaninglessly (as in passing bells for those who die as cattle) in a
monstrous industrial factory. Bad life cannot be lived well, so people
try to reconcile miserable conditions of existence, for example by
trying to find "skill and challenge" in programming when in fact it
was intended (by John von Neumann no less) to be a low level clerical
skill for people who didn't count.

In this connection, cf. When Computers Were People, Princeton. The
last human "computers" were in the 1940s human flotsam who were made
unemployable in the Depression and blamed for their problems, and by
the 1940s under constant suspicion of being Communists. Many of them
entered programming as "mere coders" and were expected to be again
unemployable when computers figured out how to program themselves.

In fine, a patriarchal society had demonstrated the fate of the
marginal very clearly at Stalingrad, Omaha Beach and Auschwitz and it
seemed that the fathers like von Neumann didn't care. Programming
viewed from the outside was seen as an easy job that could be a
catchall or sink for the marginal, and it remains so. As a result,
programmers are haunted by feelings of inadequacy and are for this
reason only too easy to scapegoat what they consider others'
incompetence, since this in a magical sense means that they are not
the mental midgets of their secret fair.

That should read "the mental midgets of their secret fear" but the
misprint is poetry:

I met the mental midget of my secret fair
Scuttling through the village square,
And he said to me beware, beware, live in fear
Of being exposed to fortune, and men's eyes
As what they fear is their surmise
That they are the mental midget of their secret fair.

I then put on my armor bright
And in a fight put my midget to flight
And with my Angel of Delight
Did disport myself in fields of Light.
But in fact it is hard, taking not only humility but also charity
towards others, which I don't see in the regs. My own lack of charity
for Seebach replaced my earlier hospitality for very good reasons,
because when I turn the other cheek I get bitch slapped.


[ snip ]
I like it when women act like the best of men: competently, wisely,
compassionately and never pointing the finger at a scapegoat, instead
(like you) focusing on problem solving.
You give me more credit than I think I deserve.  Julienne Walker,
now -- *she* seems able to focus on technical matters and avoid
being pulled into pointless wrangling.  Well, whatever.

Actually, she gets at times into pointless wrangling when she tries to
make me behave.




 

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
474,102
Messages
2,570,645
Members
47,246
Latest member
TemekaLutz

Latest Threads

Top