From 023465ff13792803dc90cda01f98d310417fee3f Mon Sep 17 00:00:00 2001 From: Tyge Løvset Date: Thu, 26 Nov 2020 17:31:24 +0100 Subject: Added link to beginning of cstr API documentation, and some small docu fixes. --- README.md | 26 +++++++++++++------------- stc/cpqueue.h | 2 +- stc/cqueue.h | 4 ++-- stc/cstack.h | 2 +- 4 files changed, 17 insertions(+), 17 deletions(-) diff --git a/README.md b/README.md index 7137a701..8d34cfec 100644 --- a/README.md +++ b/README.md @@ -5,19 +5,19 @@ Introduction ------------ An elegant, fully typesafe, generic, customizable, user-friendly, consistent, and very fast standard container library for C99. This is a small headers only library with the most used container components, and a few algorithms: -- **stc/carray.h** - Dynamic generic **multi-dimensional array**, implemented as a single contiguous section of memory. -- **stc/cbitset.h** - Bitset similar to c++ std::bitset or boost::dynamic_bitset. -- **stc/clist.h** - A genric circular **singly linked list**. Can be used as a **queue** as it supports *push_back(), push_front(), and pop_front()*. It also contains various *splice* functions and *merge sort*. -- **stc/cmap.h** - A generic **unordered map / set** implemented as open hashing without tombstones. Highly customizable and fast. -- **stc/cstr.h** - Compact and powerful **string** class. -- **stc/cvec.h** - Dynamic generic **vector** class, works well as a **stack**. -- **stc/cstack.h** - **stack** adapter, currently works with *cvec*. -- **stc/cqueue.h** - **queue** adapter, currently works with *clist*. -- **stc/cpqueue.h** - **priority queue** adapter. Works with *cvec*. -- **stc/cptr.h** - Support for pointers in containers, and a reference counted shared pointer **csptr**. -- **stc/coption.h** - Implementation of a **getopt_long()**-like function, *coption_get()*, to parse command line arguments. -- **stc/crandom.h** - A few very efficent modern random number generators *pcg32* and my own *64-bit PRNG* inspired by *sfc64*. Both uniform and normal distributions. -- **stc/ccommon.h** - A common include file with a few general definitions. +- **carray** - Dynamic generic **Multi-Dimensional Array**, implemented as a single contiguous section of memory. +- **cbitset** - **Bitset** similar to c++ *std::bitset* or *boost::dynamic_bitset*. +- **clist** - A genric circular **Singly Linked List**. Can be used as a *queue* as it supports *push_back(), push_front(), and pop_front()*. It also contains various *splice* functions and *merge sort*. +- **cmap** - A generic **Unordered Map / Set** implemented as open hashing without tombstones. Highly customizable and fast. +- **[cstr](docs/cstr_api.md)** - Powerful and compact **String** type. +- **cvec** - Dynamic generic **Vector** class. +- **cstack** - **Stack** adapter, currently works with *cvec*. +- **cqueue** - **Queue** adapter, currently works with *clist*. +- **cpqueue** - **Priority Queue** adapter. Works with *cvec*. +- **cptr** - Support for **pointers** in containers, and a reference counted shared pointer *csptr*. +- **coption** - Implementation of a **getopt_long()**-like function, *coption_get()*, to parse command line arguments. +- **crandom** - A few very efficent modern **random number generators** *pcg32* and my own *64-bit PRNG* inspired by *sfc64*. Both uniform and normal distributions. +- **ccommon** - A common include file with a few general definitions. The usage of the containers is quite similar to the C++ standard containers, so it should be easy if you are familiar with them. diff --git a/stc/cpqueue.h b/stc/cpqueue.h index b23560d0..130cac03 100644 --- a/stc/cpqueue.h +++ b/stc/cpqueue.h @@ -21,7 +21,7 @@ * SOFTWARE. */ -/* Priority Queue using heap, with adapter class (normally cvec). +/* Priority-Queue adapter (implemented as heap), default uses cvec. #include #include diff --git a/stc/cqueue.h b/stc/cqueue.h index cf549cd2..e0a34636 100644 --- a/stc/cqueue.h +++ b/stc/cqueue.h @@ -23,12 +23,12 @@ #ifndef CQUEUE__H__ #define CQUEUE__H__ -/* Priority Queue using heap, with adapter class (normally cvec). +/* Queue adapter, default uses clist. #include #include using_clist(i, int); - using_cqueue(i, clist_i); // min-heap (increasing values) + using_cqueue(i, clist_i); int main() { int n = 10000000; diff --git a/stc/cstack.h b/stc/cstack.h index 6a4ec35f..170e6f45 100644 --- a/stc/cstack.h +++ b/stc/cstack.h @@ -23,7 +23,7 @@ #ifndef CSTACK__H__ #define CSTACK__H__ -/* Stack adapter (normally uses cvec). +/* Stack adapter, default uses cvec. #include #include -- cgit v1.2.3