Skip to Main Content
Practical C++
book

Practical C++

by Rob McGregor
August 1999
Beginner to intermediate content levelBeginner to intermediate
912 pages
15h 44m
English
Que
Content preview from Practical C++

Chapter 16. Exploring Namespaces

<feature>
  • Learn what namespaces are and what they can do for you

  • See how to declare and define namespacess

  • Discover how to use unnamed namespaces

  • Learn about the using declaration and the using directive

  • Find out about namespace aliases and composite namespaces

  • Understand the global namespace

</feature>

What Is a Namespace?

A namespace is a C++ declaration area that lets you add a secondary name to an identifier, helping to ensure that no duplicate global identifier names exist in a program. The namespace is just a name that acts as a wrapper for the identifiers within it. Why would you need something like this in C++?

Namespace

A C++ declaration area that lets you add a secondary name to an identifier, helping to insure ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Practical C++ Programming, 2nd Edition

Practical C++ Programming, 2nd Edition

Steve Oualline
C++ Cookbook

C++ Cookbook

D. Ryan Stephens, Christopher Diggins, Jonathan Turkanis, Jeff Cogswell

Publisher Resources

ISBN: 0789721449Purchase book