Welcome to Collin Moon's C++ libraries documentation


This wiki will contain documentation about each library and its following public API. Because these libraries can change often, this wiki may be behind the current implementation. Over time, everything will get updated.

Currently, lots of libraries are not compiling because of use bleeding-edge features, such as modules. Each library home page will denote their development and test status.

This project is currently using C++20 features, and is mainly compiled using Visual Studio 2022 Preview. At this moment, not all features that are used in this project are supported by Visual Studio 2022 Preview, so some libraries are in limbo until those features get implemented.

Structure of the Code


All source code is under the src/cmoon folder. Each folder within is its own library. This project uses modules, and has taken an approach to naming of modules.

Inside each folder will contain a module file with the same name. This module file imports all files contained in the public API for that library. Users of the public library are encouraged to just import the entire module (example: import cmoon.geometry to import the geometry library). This is because not all module files within the library folder are part of the public API, and you are guaranteed to import everything correctly by importing the entire module.

Many libraries within here may reference other libraries. Typically, they import the entire library as expected. Sometimes they may import just part of the library for circular dependency reasons, although I do best to avoid this. In this case, care is taken to ensure the partial import is correct.

Tests

All tests are under the tests folder. Just like the structure of the source code, the test code will contain a folder for each module. Each folder contains a module file named the same thing as the module and is where all tests for that module get exported. A driver program is in each folder to run tests for that module. A driver program for the entire project is included, and will run all available tests.

Module Naming Convention


Every module is prefixed with cmoon, as to distinguish it from other projects. The naming convention is similar to Java's packages/imports. For example, to import the json library, you would type: import cmoon.json.

Libraries