|
| |
Getting Started with C++
The first consideration in starting with C++ is a compiler. Most classroom
environments these days have installed the latest version of Microsoft Visual
C++. However, this can be a pricey option. See
installation instructions if you need to install this.
An Alternate Development Environment for NT/Win2K
It is possible for NT/Win2K users to use notepad. However, see the
installation instructions for
- Cygwin
- Emacs
for NT/Win2K (if applicable)
If
you want to use emacs to compile with the Microsoft compiler, you'll have to set
up a bunch of environment variables.
- Microsoft
- C++
Language
- C
Language
- Stream
Library
- Standard
Library
This documentation is pretty terse on the standard library -- you may
want to try SGI's STL
documentation. Note that the Standard Library is a old frozen
version of STL. However, much of the documentation is the same and SGI
has better explanations and examples.
- Microsoft has ported many of the standard C/C++ API's to their windows
platform. Just type in the function you want documentation on at http://search.microsoft.com.
For example, to use the C socket function (for network programming) just
type in
select. However, be forewarned, they have changed
things a bit. They use different header file names, they do not store
the errors codes in the global variable errno, their
implementation only accepts socket descriptors and not file descriptors
in general. Nevertheless, it is very useful for writing Microsoft
specific code (of course) and still helpful for writing generic code
(when combined with www.opengroup.org,
for example).
Here are some links to some mostly standard APIs:
- Standard
C Run time library
-
Sockets
(aka Winsock)
-
Remote
Procedure Calls (RPC) (this is wire compatible with other
standard implementations of RPC and is source code compatible if you
know where they have hidden their special header file that contains
the #define statements to translate the standard function names into
Microsoft's non-standard function names).
Unfortunately, Microsoft's
threading API is completely non-standard. This may well be remedied with
the Cygwin port of pthreads which may well be documented in www.opengroup.org's
pthread section. We hope to verify this soon.
-
Microsoft
Specific: Visual C
- GNU and Delorie
- C Preprocessor
- C++ Internals
- User's Manual for
C/C++
- C Run Time
Library
- Command Line
Options for Running the Compiler
- C++
Stream Library and index
- A
Guide to Using STL
- SGI
Note: STL != standard library. In the mid-90's STL was frozen and
incorporated into the standard library. Originally STL only consisted of
containers (like maps, lists and vectors) and the standard library contained
other things like streams. STL has continued to evolve at SGI and now
contains is own implementation of streams and enhancements to containers
that are not available in the standard library.
This may be the best online
documentation available for STL or the standard library. It has a lot of
example programs and annotations to indicate which features are unique to
STL.
- Standardized Vendor Neutral C/C++ API
Unix/Linux
Commands and APIs at www.opengroup.org is quite extensive. It documents
the standard sockets API (for network communication) and Pthreads (for
portable multi-threading) that (we believe) are implemented in Cygwin.
- Cygwin
Cygwin User's Guide, API
Reference & FAQ.
These links are probably of little interest to anyone using MSVC. These
links document the ports of compilers, function libraries and command line
utilities from the GNU/UNIX environment.
These are not terribly extensive -- but they are better than
nothing. The
API reference is especially disappointing, it is mostly lists of
function names that have been ported from the GNU environments to the
NT/Win2000. When I queried the folks on the Cygwin mailing list, the
suggested I download the source for the details. However, Unix/Linux
Commands and APIs at www.opengroup.org might be much more convenient.
- Graphical User Interface
Programming
Downloadable Source Code for More Advanced Programmers
- Coplien's Advanced C++ Programming Styles and Idioms is excellent and can
be downloaded from http://netlib.bell-labs.com/netlib/c++/idioms/.
- Todd's excellent articles on template programmng with source code are
available at http://www.extreme.indiana.edu/~tveldhui/.
|