Topic: New Book: C++ Unleashed


Author: brownsta@concentric.net (Stan Brown)
Date: 1999/01/07
Raw View
In newsgroup comp.std.c++, article <7707p4$f6d$1@engnews2.Eng.Sun.COM>,
more than 23 months before the end of the millennium Steve Clamage
(clamage@Eng.Sun.COM) wrote:

>I'm a little confused about the terms of discussion here.

I've snipped the previous context because I think it didn't help.

>So, Stan, are you objecting to the literal error ("::" instead of ";")
>or to the using-directive?

Neither. (Like you, I assumed the :: was a typo for ; and just passed
over it.)

I was objecting to someone else's statement to the effect that it's okay
to leave out the using directive (or equivalent required syntax) in a
book about C++ because it "takes too much space".

My point was that it's quite easy to put
 using namespace std;  // explained on page XXX
at the beginning of every example that needs it, so that students will
have correct examples to compile. Of course it's also possible to qualify
everything with std:: before explaining namespaces -- IIRC, Stroustrup
does mostly the latter.

Either way, it's just not fair to students (in class or studying alone)
to give them examples that can't possibly compile, when they will have no
idea what is wrong.

--
Stan Brown, Oak Road Systems, Cleveland, Ohio, USA
                      http://www.concentric.net/%7eBrownsta/
My reply address is correct as is. The courtesy of providing a correct
reply address is more important to me than time spent deleting spam.


[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu    ]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://reality.sgi.com/austern_mti/std-c++/faq.html              ]






Author: "Darrell Dupas" <ddupas@hotmail.com>
Date: 1999/01/10
Raw View
It is my understanding that the line

using namespace std;

is microsoft specific to accsess the Standard Template Library, if I am
wrong, let me know. This line may not be required with other C++ compilers.



[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu    ]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://reality.sgi.com/austern_mti/std-c++/faq.html              ]






Author: clamage@Eng.Sun.COM (Steve Clamage)
Date: 1999/01/10
Raw View
"Darrell Dupas" <ddupas@hotmail.com> writes:

>It is my understanding that the line

>using namespace std;

>is microsoft specific to accsess the Standard Template Library, if I am
>wrong, let me know. This line may not be required with other C++ compilers.

It is part of Standard C++.

The entire Standard C++ library is defined in namespace std.

You have three choices when using elements of the library:

1. Qualify each name individually:
 #include <iostream>
 ...
 std::cout << "Hello, world!" << std::endl;

2. Provide a using-declaration for the names you wish to use:
 #include <iostream>
 using std::cout;
 using std::endl;
 ...
 cout << "Hello, world!" << endl;

3. Provide a using-directive for namespace std, which makes EVERY
name in the standard library visible without qualification:
 #include <iostream>
 using namespace std:
 ...
 cout << "Hello, world!" << endl;

The three options can be used in any combination, but #3
elminates the need for #1 and #2.

Option 3 is a pretty big club, and can cause unexpected name
conflicts between your code and the standard library. That's
why the standard library was put into its own namespace,
and the name "std" is reserved as a namespace name.

But for beginning C++ programmers, it is a simple way to get
started. As with, for example, #include <iostream>, it can be
treated as a magic incantation you need to get your first
programs to work. Later, the reasons for it can be explained,
and the more advanced programmer can decide which of many options
is most appropriate for each program.

--
Steve Clamage, stephen.clamage@sun.com
---
[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu    ]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://reality.sgi.com/austern_mti/std-c++/faq.html              ]





Author: tony@ns.cook.ml.org (Tony Cook)
Date: 1999/01/10
Raw View
Darrell Dupas (ddupas@hotmail.com) wrote:

: It is my understanding that the line

: using namespace std;

: is microsoft specific to accsess the Standard Template Library, if I am
: wrong, let me know. This line may not be required with other C++ compilers.

 using namespace std;

or using declarations like:

 using std::vector;

or simply specifying the namespace as in

  std::vector<int> int_vect;

is required to access nearly all names required by the recent C++
standard.

The main exception are when you use the C style header names like:

  #include <stdio.h>

will put names like printf() into both the std namespace and the
global namespace.
---
[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu    ]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://reality.sgi.com/austern_mti/std-c++/faq.html              ]





Author: zalman@netcom.com (Zalman Stern)
Date: 1999/01/12
Raw View
I claim that within textbook examples, putting std:: in front of
identifiers that are within that namespace is of great help to novice
programmers as it allows them to easily see which identifiers are provided
for them by C++ and which are either their own code or provided by the
context of the book. (And in fact, I would suggest authors introduce their
own namespace(s) to make it clear which identifiers are "the book's".)

I usually explain to beginning programers the importance of knowing whether
an identifier is part of the language, the operating system, the
application framework, or their own code.(*) (Much less whether its a local
variable, a class member, or a global variable, etc.) After that, its
difficult to explain how to make the determination. Namespace help a lot
here.

Another thing that is a great help is to make it clear which headers
provide the identifiers in the examples. (This is more controversial as
namespace qualifiers will usually eat horizontal space which is not at an
extreme premium in textbook exapmles while always writing out headers takes
up vertical space which can always be used for something else.)

Someday we'll have first class modules and this will all seem like a pretty
silly argument.

-Z-

(*) Things like:
"Try to use the standard library instead of the OS if possible."
"Interfaces from the same body of code usually have similar conventions.
Different bodies of code seldom do."
"The documentation for the standard is here, for the OS its here, and for
the app framework, its here."
"You have source code to what you write and the app framework, but not to
the OS or the library."
"A bug is almost certainly in your code, but if not, the next candidate is
the app framework, then the library, then the OS."
"You can change some stuff but not others."
"Here's what's portable."
Etc. All these issues involve determining where an API "comes from."
---
[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu    ]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://reality.sgi.com/austern_mti/std-c++/faq.html              ]





Author: mtobler@no-spam-ibm.net (Michael J. Tobler)
Date: 1999/01/05
Raw View
In article <535rRhAtoUj2Ew9n@robinton.demon.co.uk>,
francis@robinton.demon.co.uk says...
>
> In article <76i1n8$ls6$1@dolf.netfront.net>, cadelite
> <cadelite@hotmail.com> writes
> >I plan to buy this book as my C++ tutorial and reference. May anyone give me
> >some comment about this book. By the way, do all the materials inside this
> >book cover the C++ standard?? Better than C++ Primer by Lippman??
>
> Is that the complete title because I have not seen it yet?  The
> unleashed books are generally about specific products (e.g. Visual C++
> UNleashed) and so the emphasis is on the product rather than things such
> as the C++ Standard.

Are you talking about "C++ Primer by Lippman", or "C++ Unleashed"? Both
books are on the shelves.

> How quickly do you intend making a decision (I think that as I have not
> seen it, the book is probably very new)? Take this offline and email me
> if you get little guidance from others.

I have both books and they are very good (it just so happens I am a
contributing author to C++ Unl.)

> However a couple of quick tests,
>
> Do the authors use the correct headers (e.g. iostream not iostream.h)?
Yes.

> Do they leave you using C style arrays of char for a couple of hundred
> pages before introducing string?  And do they insist on providing their
> own string class?

Well, that depends on context. You shouldnt always judge that way.

> Do they meticulously provide a copy ctor and assignment for any class
> that includes a pointer?
>
> Does their code include namespace std::  (i.e. do their early code
> examples include a line:
>
> using namespace std::

Sometimes you have to do that for the sake of terseness. I'm sure if
you've "done a book", you'd understand that.

> If the book fails simple tests like these you need to be wary because
> you can easily waste a lot of money and time.

Not always true - although I agree to some extent. I think it's better for
someone to ask US, out here. Many inexperienced developers wont know HOW
to judge a C++ book, esp. if they are newbies.

--
<<<<<<<<<<  Blue Skies  >>>>>>>>>>>
<        Michael J. Tobler        >
<     mtobler@no-spam-ibm.net     >
< remove "no-spam-" when replying >
<<<<<<<<<<<<<<<<<>>>>>>>>>>>>>>>>>>


[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu    ]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://reality.sgi.com/austern_mti/std-c++/faq.html              ]






Author: Francis Glassborow <francis@robinton.demon.co.uk>
Date: 1999/01/06
Raw View
In article <MPG.10fbc523389ccfa198a03e@news3.ibm.net>, Michael J. Tobler
<mtobler@no-spam-ibm.net> writes
>
>In article <535rRhAtoUj2Ew9n@robinton.demon.co.uk>,
>francis@robinton.demon.co.uk says...
>>
>
>Are you talking about "C++ Primer by Lippman", or "C++ Unleashed"? Both
>books are on the shelves.

The former I am well familiar with, the later was in the latest new
books list that I received two days ago so it may be on the shelves in
the US but only just, unless the publisher is even worse than usual
about shipping over the Atlantic.  When a review copy lands on my desk I
will be giving it a close look and I think I have the experience to
judge.

>
>> How quickly do you intend making a decision (I think that as I have not
>> seen it, the book is probably very new)? Take this offline and email me
>> if you get little guidance from others.
>
>I have both books and they are very good (it just so happens I am a
>contributing author to C++ Unl.)

I think that disqualifies you from an opinion.  That is not meant to be
insulting, just that authors would always believe that (or else they
should not allow their work to be published)
>
>> However a couple of quick tests,
>>
>> Do the authors use the correct headers (e.g. iostream not iostream.h)?
>Yes.
Good
>
>> Do they leave you using C style arrays of char for a couple of hundred
>> pages before introducing string?  And do they insist on providing their
>> own string class?
>
>Well, that depends on context. You shouldnt always judge that way.

Of course not, but authors writing about modern C++ should not be
requiring novices (assuming that is the target readership) to do it the
C way first before doing it the C++ way.

>
>> Do they meticulously provide a copy ctor and assignment for any class
>> that includes a pointer?

well?  I hope the answer is yes, but experience suggests it may be no.
>>
>> Does their code include namespace std::  (i.e. do their early code
>> examples include a line:
>>
>> using namespace std::
>
>Sometimes you have to do that for the sake of terseness. I'm sure if
>you've "done a book", you'd understand that.

Actually I am entirely happy with early examples just echoing the magic
incantation.  What I am not happy with is books that elect to avoid
namespace std entirely.
>
>> If the book fails simple tests like these you need to be wary because
>> you can easily waste a lot of money and time.
>
>Not always true - although I agree to some extent. I think it's better for
>someone to ask US, out here. Many inexperienced developers wont know HOW
>to judge a C++ book, esp. if they are newbies.

How do you mean, 'not always true' ? I said 'wary', not 'dont't consider
it'  One of the problems with many of amazon.com's reviews is that they
are written by readers who lack adequate criteria for judging the
technical content.
>

Francis Glassborow      Chair of Association of C & C++ Users
64 Southfield Rd
Oxford OX4 1PA          +44(0)1865 246490
All opinions are mine and do not represent those of any organisation


[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu    ]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://reality.sgi.com/austern_mti/std-c++/faq.html              ]






Author: brownsta@concentric.net (Stan Brown)
Date: 1999/01/06
Raw View
In newsgroup comp.std.c++, article
<MPG.10fbc523389ccfa198a03e@news3.ibm.net>, the lovely and talented
Michael J. Tobler (mtobler@no-spam-ibm.net) wrote:
>
>In article <535rRhAtoUj2Ew9n@robinton.demon.co.uk>,
>francis@robinton.demon.co.uk says...
>> Does their code include namespace std::  (i.e. do their early code
>> examples include a line:
>>
>> using namespace std::
>
>Sometimes you have to do that for the sake of terseness. I'm sure if
>you've "done a book", you'd understand that.

I don't agree. In a book that is intended to teach, it is rather
important that the examples be correct code. An experienced C++
programmer would recognize why such an example didn't compile; a novice
would have no clue what was wrong.

Since the average C++ book is several hundred pages long, it doesn't make
an appreciable increase in size to put
 using namespace std;  // explained on page XXX
in every example that needs it -- and of course not all of them will.

It seems to me that justifying incorrect code in the name of terseness is
a step down that slippery road to justifying incorrect code because you
like the author's style, or because some compilers accept it. My
perspective is that if the code is wrong, it doesn't matter how terse or
how pretty it is, it has no place holding itself up as an example.

--
Stan Brown, Oak Road Systems, Cleveland, Ohio, USA
                      http://www.concentric.net/%7eBrownsta/
My reply address is correct as is. The courtesy of providing a correct
reply address is more important to me than time spent deleting spam.
---
[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu    ]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://reality.sgi.com/austern_mti/std-c++/faq.html              ]





Author: "Michael J. Tobler" <unx5t!mtobler@no-spam-ibm.net>
Date: 1999/01/06
Raw View
Stan Brown wrote:
>
> In newsgroup comp.std.c++, article
> <MPG.10fbc523389ccfa198a03e@news3.ibm.net>, the lovely and talented
> Michael J. Tobler (mtobler@no-spam-ibm.net) wrote:
> >
> >In article <535rRhAtoUj2Ew9n@robinton.demon.co.uk>,
> >francis@robinton.demon.co.uk says...
> >> Does their code include namespace std::  (i.e. do their early code
> >> examples include a line:
> >>
> >> using namespace std::
> >
> >Sometimes you have to do that for the sake of terseness. I'm sure if
> >you've "done a book", you'd understand that.
>
> I don't agree. In a book that is intended to teach, it is rather
> important that the examples be correct code. An experienced C++
> programmer would recognize why such an example didn't compile; a novice
> would have no clue what was wrong.

The "Unleashed" series is intended for intermediate to
advanced developers. The books of this stature, that
I have seen, do mention the caveats of the using
directive and using declaration. As I quickly glanced
through the Unleashed book, a lot of the source uses
<iostream.h> and in the instances where <iostream>, either
"std::" is prefixed (as I prefer) to any names in the
namespace std (the chapters I did :)  or the directive
is used.


>
> Since the average C++ book is several hundred pages long, it doesn't make
> an appreciable increase in size to put
>         using namespace std;  // explained on page XXX
> in every example that needs it -- and of course not all of them will.

In another book that is due out in a couple of weeks, "C++ How-To",
I mention the use of the directive. In Chapter One, the C++ intro,
I talk about its use and why we might use the directive to reduce
the size of the code listings. I also talk about correct usage of
the using directive and the using declaration.

> It seems to me that justifying incorrect code in the name of terseness is
> a step down that slippery road to justifying incorrect code because you
> like the author's style, or because some compilers accept it. My
> perspective is that if the code is wrong, it doesn't matter how terse or
> how pretty it is, it has no place holding itself up as an example.

Using the directive is not "wrong", it's just not recommended practice.
I dont recommend its use because it brings in everything in the named
namespace. If I DO use it in the book, I explain why I did it; otherwise,
as a rule, I use fully-qualified names.


--
<<<<<<<<<<< Blue Skies >>>>>>>>>>>
<       Michael J. Tobler        >
< remove "no-spam"when replying  >
< mailto:mtobler@no-spam-ibm.net >
<<<<<<<<<<<<<<<<>>>>>>>>>>>>>>>>>>
---
[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu    ]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://reality.sgi.com/austern_mti/std-c++/faq.html              ]





Author: brownsta@concentric.net (Stan Brown)
Date: 1999/01/06
Raw View
In newsgroup comp.std.c++, article <36938B9E.B5D0F776@no-spam-ibm.net>,
the lovely and talented Michael J. Tobler (unx5t!mtobler@no-spam-ibm.net)
wrote:
>> It seems to me that justifying incorrect code in the name of terseness is
>> a step down that slippery road to justifying incorrect code because you
>> like the author's style, or because some compilers accept it. My
>> perspective is that if the code is wrong, it doesn't matter how terse or
>> how pretty it is, it has no place holding itself up as an example.
>
>Using the directive is not "wrong", it's just not recommended practice.
>I dont recommend its use because it brings in everything in the named
>namespace. If I DO use it in the book, I explain why I did it; otherwise,
>as a rule, I use fully-qualified names.

I think you misunderstood me. I was not saying that using the directive
is wrong. I was saying that *omitting* it (or some other way of
qualifying the names that are in std) is wrong. I was objecting to a
previous writer's statement that it was okay to leave it out even when
using new-style headers. Obviously with <iostream> identifiers like cin
and cout are in namespace std, so they must be qualified or the directive
must be used.

I take the point of Glassborow and others that the directive is not
usually(*) the best choice, and I was not disagreeing with that. I *was*
disagreeing with people who try to justify incorrect examples in books
intended for instruction, and I feel quite strongly about it.

Does that make more sense?

(*) For "not usually" read "never" if you wish.

--
--
Stan Brown, Oak Road Systems, Cleveland, Ohio, USA
                      http://www.concentric.net/%7eBrownsta/
My reply address is correct as is. The courtesy of providing a correct
reply address is more important to me than time spent deleting spam.


[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu    ]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://reality.sgi.com/austern_mti/std-c++/faq.html              ]






Author: "Michael J. Tobler" <unx5t!mtobler@no-spam-ibm.net>
Date: 1999/01/07
Raw View
Stan Brown wrote:
[snip]
> I think you misunderstood me. I was not saying that using the directive
> is wrong. I was saying that *omitting* it (or some other way of
> qualifying the names that are in std) is wrong. I was objecting to a
> previous writer's statement that it was okay to leave it out even when
> using new-style headers. Obviously with <iostream> identifiers like cin
> and cout are in namespace std, so they must be qualified or the directive
> must be used.

...or the "using declaration" :)

> I take the point of Glassborow and others that the directive is not
> usually(*) the best choice, and I was not disagreeing with that. I *was*
> disagreeing with people who try to justify incorrect examples in books
> intended for instruction, and I feel quite strongly about it.
>
> Does that make more sense?

Yes, thanks

> (*) For "not usually" read "never" if you wish.

I agree

--
<<<<<<<<<<< Blue Skies >>>>>>>>>>>
<       Michael J. Tobler        >
< remove "no-spam"when replying  >
< mailto:mtobler@no-spam-ibm.net >
<<<<<<<<<<<<<<<<>>>>>>>>>>>>>>>>>>
---
[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu    ]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://reality.sgi.com/austern_mti/std-c++/faq.html              ]





Author: clamage@Eng.Sun.COM (Steve Clamage)
Date: 1999/01/07
Raw View
brownsta@concentric.net (Stan Brown) writes:

>In newsgroup comp.std.c++, article
><MPG.10fbc523389ccfa198a03e@news3.ibm.net>, the lovely and talented
>Michael J. Tobler (mtobler@no-spam-ibm.net) wrote:
>>
>>In article <535rRhAtoUj2Ew9n@robinton.demon.co.uk>,
>>francis@robinton.demon.co.uk says...
>>> Does their code include namespace std::  (i.e. do their early code
>>> examples include a line:
>>>
>>> using namespace std::
>>
>>Sometimes you have to do that for the sake of terseness. I'm sure if
>>you've "done a book", you'd understand that.

>I don't agree. In a book that is intended to teach, it is rather
>important that the examples be correct code. An experienced C++
>programmer would recognize why such an example didn't compile; a novice
>would have no clue what was wrong.

I'm a little confused about the terms of discussion here.

I assume that when Francis wrote
 using namespace std::
it was a typo and he meant to write
 using namespace std;
I think Michael was making the same assumption in his reply.

Surely no one is advocates writing literally
 using namespace std::
as some form of terseness -- it is simply wrong.

So, Stan, are you objecting to the literal error ("::" instead of ";")
or to the using-directive?

--
Steve Clamage, stephen.clamage@sun.com
---
[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu    ]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://reality.sgi.com/austern_mti/std-c++/faq.html              ]





Author: James.Kanze@dresdner-bank.com
Date: 1999/01/07
Raw View
In article <2ZKIqlA8mqk2Ewnm@robinton.demon.co.uk>,
  Francis Glassborow <francisG@robinton.demon.co.uk> wrote:

> >> Do they leave you using C style arrays of char for a couple of hundr=
ed
> >> pages before introducing string?  And do they insist on providing th=
eir
> >> own string class?
> >
> >Well, that depends on context. You shouldnt always judge that way.
>
> Of course not, but authors writing about modern C++ should not be
> requiring novices (assuming that is the target readership) to do it the
> C way first before doing it the C++ way.

I don't really disagree, but in a similar discussion in
fr.comp.lang.c++, one author pointed out that you cannot avoid talking
about C style arrays early, because that is the type of string literals,
that is the type needed for the filename in [io]fstream, etc., etc.  The
argument was basically that introducing two different types of array
early on was confusing, and since you cannot avoid C style arrays, the
others have to wait.

--
James Kanze                                           GABI Software, S=E0=
rl
Conseils en informatique orient=E9 objet  --
                          --  Beratung in industrieller Datenverarbeitung
mailto: kanze@gabi-soft.fr          mailto: James.Kanze@dresdner-bank.com

-----------=3D=3D Posted via Deja News, The Discussion Network =3D=3D----=
------
http://www.dejanews.com/       Search, Read, Discuss, or Start Your Own  =
 =20
---
[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu    ]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://reality.sgi.com/austern_mti/std-c++/faq.html              ]





Author: Francis Glassborow <francis@robinton.demon.co.uk>
Date: 1999/01/07
Raw View
In article <MPG.10fd8415bf902cf9896bf@news.concentric.net>, Stan Brown
<brownsta@concentric.net> writes
>I take the point of Glassborow and others that the directive is not
>usually(*) the best choice, and I was not disagreeing with that. I *was*
>disagreeing with people who try to justify incorrect examples in books
>intended for instruction, and I feel quite strongly about it.

Exactly my point.  I am not going to burden novices with requiring an
understanding of directives etc.  But when they type in a program it
should work if they are using a recent release of a respectable
development kit.  If you write code without doing anything re namespace
std you are being unhelpful.  Books for novices should contain good code
that works.  I am less demanding of code quality from books aimed at
experienced users of the language concerned.



Francis Glassborow      Chair of Association of C & C++ Users
64 Southfield Rd
Oxford OX4 1PA          +44(0)1865 246490
All opinions are mine and do not represent those of any organisation
---
[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu    ]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://reality.sgi.com/austern_mti/std-c++/faq.html              ]





Author: "cadelite" <cadelite@hotmail.com>
Date: 1999/01/01
Raw View
I plan to buy this book as my C++ tutorial and reference. May anyone give me
some comment about this book. By the way, do all the materials inside this
book cover the C++ standard?? Better than C++ Primer by Lippman??

Thank you.

cadelite@hotmail.com


[ moderator's note: Discussion of whether a book fully or accurately
  covers Standard C++ is suitable for comp.std.c++, but other
  discussion (such as quality of the tutorial) probably is not.
  If you reply to this cross-posted article and include comp.std.c++
  in the newsgroup list, please follow the newsgroup charter. See
  the FAQ reference below for more information. -sdc ]


[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu    ]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://reality.sgi.com/austern_mti/std-c++/faq.html              ]






Author: Francis Glassborow <francis@robinton.demon.co.uk>
Date: 1999/01/02
Raw View
In article <76i1n8$ls6$1@dolf.netfront.net>, cadelite
<cadelite@hotmail.com> writes
>I plan to buy this book as my C++ tutorial and reference. May anyone give me
>some comment about this book. By the way, do all the materials inside this
>book cover the C++ standard?? Better than C++ Primer by Lippman??

Is that the complete title because I have not seen it yet?  The
unleashed books are generally about specific products (e.g. Visual C++
UNleashed) and so the emphasis is on the product rather than things such
as the C++ Standard.

How quickly do you intend making a decision (I think that as I have not
seen it, the book is probably very new)? Take this offline and email me
if you get little guidance from others.

However a couple of quick tests,

Do the authors use the correct headers (e.g. iostream not iostream.h)?

Do they leave you using C style arrays of char for a couple of hundred
pages before introducing string?  And do they insist on providing their
own string class?

Do they meticulously provide a copy ctor and assignment for any class
that includes a pointer?

Does their code include namespace std::  (i.e. do their early code
examples include a line:

using namespace std::

If the book fails simple tests like these you need to be wary because
you can easily waste a lot of money and time.




Francis Glassborow      Chair of Association of C & C++ Users
64 Southfield Rd
Oxford OX4 1PA          +44(0)1865 246490
All opinions are mine and do not represent those of any organisation


[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu    ]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://reality.sgi.com/austern_mti/std-c++/faq.html              ]