If I understand right, you're personally commenting about my stuff or
you've misunderstood that I'm claiming myself as RJH or you didn't
understand what I said.
I won't put words in his mouth, but after looking over the content at the
above link, I find it hard to believe that DMR was actually involved,
except perhaps very peripherally with the text of the "book". Chapter 2
(Birth of C) is about the only portion that seems remotely likely.
It is filled with mistakes, errors, omissions, outright fallacies and
it's too painful to read it all the way through. I'm sorry, because I
like what you are trying to do (help C programmers improve), but the
information in the document is simply going to cause more harm than
good. Out of work developers in western countries should probably
hope that as many Indian C programmers as possible read this document,
but that is faint praise indeed. The book was written between 2000 and
2001 according to the website, yet refers to ANSI C (without specifics)
rather than ISO C, C99, etc. Not that it seems to matter.
Chapter 3: Is there any data to support that Indian Hill is used
by "most of the real programmers"? What happened to K&R, BSD,
GNU, etc.? I don't think Hungarian NOTATION is a coding style
at all per se, but rather a (poor) variable naming convention. The
reference to VB is perhaps true, but by no means relevant. The "WAR"
coding style is, well, best left ignored.
Chapter 4: Seems to assume (including references to hotkeys for
help in the GUI) to Turbo C++ 3.0. The "Myths" section is certainly
aptly named, both in questions and in the responses. It's completely
stunning that you can write any of the content in section 4.1 with
a straight face. The rest of the "chapter" doesn't get much better.
Chapter 5: Despite being only one page in length, it has errors. Hint:
What does the standard say that EXIT_FAILURE is equal to?. There are
technical arguments to be made about 5.2 as well, but....
Chapter 6: Oh boy. Your attempts to define undefined behavior are
pretty scary. A look at the standards documents might also be
terrifying in this regard, but at least you can't claim they aren't
the letter of the law, so to speak. 6.1 What Dennis Ritchie did or
did not say about program fragments is not the method of determining
undefined behavior. Section 6.2 makes no attempt to even explain WHY
any of the examples might or might not invoke undefined behavior, it
simply claims they are "idiotic questions ... often asked in Indian
Programming [sic] world". That's all you have to say on this topic?
I'm not sure how a book consists of multiple one page "chapters",
but ...
Chapter 7: "The Magic XOR". Using XOR for SWAP actually itself
invokes undefined behavior, yet you show call it out as an example of
the "magic" of XOR rather than including it in the above "chapter.
See CLC FAQ 10.3 for more info on why. While I'm thinking about it,
replacing the entire text with a pointer to
http://www.eskimo.com/~scs/C-faq/top.html
would be a huge improvement. 7.3 actually tells the reader that the
use of
ch ^ 'a'
is a valid encryption technique, with one of the added benefits
of "Since such technique does not have any 'key' values, it is
easy to decrypt the file". How joyous. The mind boggles further.
A big flashing "DANGER: THIS IS NOT ENCRYPTION" should be nearby.
Chapter 8: "String Function" [sic]. This is simply another one
page chapter with the author's pet implementations of strlen,
strcpy, strcat and strcmp. Apparently, understanding these will
help improve your programming skills. I suppose that all depends
upon where you fall on the totem pole.
This is getting long, so I'll skip around, section 12.3 provides
a *claimed* cure for memory leaks. It turns out that "The remedy
for memory leak is to declare pointer constant". It has to be read
to be fully appreciated.
Chapter 13 is dedicated to the concept of Code Obfuscation in which
we find out that "Throughout the world most of the C programmers
participate in this contest". The fact that no Indian has yet won
the prize is called out for a reason to explore the topic. *Sigh*
Almost none of chaptes 14-79 have anything to do with modern
programming, or ANSI or ISO C at all, so I won't bother. Most
of it would be far better replaced with an old copy of Ray
Duncan's "Advanced MSDOS Programming" from 18 years ago.
If you really want to help Indian programmers, point them at
some content written about things relevant in this century,
and more importantly written accurately. As previously stated,
the CLC FAQ (FREE in online form, but the book is nice to
have handy as well) and a copy of K&R2 would be orders of
magnitude better than this "book".