C++ help in command line

M

MN

Hi there,
Is there any command to type in the command line in order to get help
of C++ standard functions under Linux (let say Centos 5)?
For example, for C standard functions I can type: "man printf" and I
get the answer.
 
I

Ian Collins

MN said:
Hi there,
Is there any command to type in the command line in order to get help
of C++ standard functions under Linux (let say Centos 5)?

firefox?
 
M

Michael DOUBEZ

MN said:
Is there any command to type in the command line in order to get help
of C++ standard functions under Linux (let say Centos 5)?
For example, for C standard functions I can type: "man printf" and I
get the answer.

A lot of C functions are also part of Unix/Solaris/BSD/Posix
specifications. I think that's why they are present in the man catalog
but there is no such thing for c++.

You are welcome to make your own and contribute them to the community.
 
M

MN

A lot of C functions are also part of Unix/Solaris/BSD/Posix
specifications. I think that's why they are present in the man catalog
but there is no such thing for c++.

You are welcome to make your own and contribute them to the community.
You said that there isn't help in command line, so where can I find
help of c++ standard functions?
Should I every time search with google ?
 
I

Ian Collins

MN said:
You said that there isn't help in command line, so where can I find
help of c++ standard functions?

Get a copy of the standard or a good test book. You can't best good old
paper.
 
S

SG

You said that there isn't help in command line, so where can I find
help of c++ standard functions?
Should I every time search with google ?

I prefer http://www.cplusplus.com/reference/ for a quick reference.
Apparently, it has been recently updated to cover the complete
standard library (as far as I can tell).

If you're not familiar with the concepts you might also want to read a
good tutorial style book about C++ and its standard library. I don't
own Josuttis' book but it is supposedly very useful.

Cheers!
SG
 
J

James Kanze

MN wrote:

It shouln't be necessary, if you have a good C++ compiler,
installed correctly. Under Solaris, "man -s 3c++ find_if", for
example, returns the manpage for std::find_if (if Sun C++ has
been correctly installed, and you've set up your MANPATH
correctly for it, of course).

G++ doesn't seem to have man pages available for the standard
library. I don't know why; it would seem a rather basic
requirement.
 
M

Maxim Yegorushkin

It shouln't be necessary, if you have a good C++ compiler,
installed correctly.  Under Solaris, "man -s 3c++ find_if", for
example, returns the manpage for std::find_if (if Sun C++ has
been correctly installed, and you've set up your MANPATH
correctly for it, of course).

Under Solaris there are two standard C++ libraries: the crappy old non-
standard one and stlport. Which library does "man -s 3c++ find_if"
refer to?
 
J

James Kanze

Pre-standard, not non-standard. And neither are very good.
(I'm not sure about the STLPort, but the RogueWave library is
not their latest version, by far.)

The copyright is Rogue Wave.
If I remember correctly, the old crappy one doesn't have
find_if!

It does. I use it all the time.

The major problem with the old library is that it represents a
version that was finalized before compilers supported member
templates or explicit specification of function template
arguments. So the interface is somewhat constrained. There
are also one or two bugs; the only serious one I've encountered
makes ostrstream unusable. Other than that, it's a complete
implementation, very usable.

The STLPort that Sun delivers has a lot of bugs, some of them
(in locale) very serious. On the whole, it's worse than the
Rogue Wave version. But it does implement the interfaces which
use member templates or depend on explicit function template
arguments.

Neither are anywhere near the quality of the g++ or Dinkumware
libraries; neither ofter debugging checking, and both use
typedef's to pointers for the iterators in string and vector.
 
M

Maxim Yegorushkin

[]
The STLPort that Sun delivers has a lot of bugs, some of them
(in locale) very serious.  On the whole, it's worse than the
Rogue Wave version.  But it does implement the interfaces which
use member templates or depend on explicit function template
arguments.

Neither are anywhere near the quality of the g++ or Dinkumware
libraries; neither ofter debugging checking, and both use
typedef's to pointers for the iterators in string and vector.

What is wrong with using pointers as iterators (apart from the fact
that argument dependent name lookup for built-in types does not
consider ::std namespace)?
 
J

James Kanze

The STLPort that Sun delivers has a lot of bugs, some of
them (in locale) very serious. On the whole, it's worse
than the Rogue Wave version. But it does implement the
interfaces which use member templates or depend on explicit
function template arguments.
Neither are anywhere near the quality of the g++ or
Dinkumware libraries; neither ofter debugging checking, and
both use typedef's to pointers for the iterators in string
and vector.
What is wrong with using pointers as iterators (apart from the
fact that argument dependent name lookup for built-in types
does not consider ::std namespace)?

No validity checking. And problems when you try to overload a
function to work with either std::vector<>::iterator or T*.
 

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

No members online now.

Forum statistics

Threads
473,770
Messages
2,569,584
Members
45,077
Latest member
SangMoor21

Latest Threads

Top