From d717656f4728d3cbbc9ade1c314275334c62466d Mon Sep 17 00:00:00 2001 From: Tyge Lovset Date: Sun, 9 Apr 2023 22:40:14 +0200 Subject: Added "STC logo" in banner. --- README.md | 18 ++++++++++++------ docs/pics/containers.jpg | Bin 96093 -> 138703 bytes 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 15778ddd..35431972 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ ![STC](docs/pics/containers.jpg) -STC - Smart Template Containers for C -===================================== +STC - Smart Template Containers +=============================== ### [Version 4.2](#version-history) @@ -10,8 +10,7 @@ Description ----------- STC is a *modern*, *typesafe*, *fast* and *compact* container and algorithms library for C99. The API naming is similar to C++ STL, but it takes inspiration from Rust and Python as well. -The library handles everything from trivial to highly complex data using *templates*, and it -supports a variety of containers. +The library handles everything from trivial to highly complex data using *templates*. Containers ---------- @@ -197,7 +196,9 @@ For user-defined struct elements, `i_cmp` compare function should be defined as only works for integral types. *Alternatively, `#define i_opt c_no_cmp` to disable sorting and searching*. Similarily, if an element destructor `i_valdrop` is defined, `i_valclone` function is required. *Alternatively `#define i_opt c_no_clone` to disable container cloning.* -Let's make a vector of vectors, which can be cloned. All of its element vectors will be destroyed when destroying the Vec2D. [ [Run this code](https://godbolt.org/z/5EY56qnfM) ] +Let's make a vector of vectors, which can be cloned. All of its element vectors will be destroyed when destroying the Vec2D. + +[ [Run this code](https://godbolt.org/z/5EY56qnfM) ] ```c #include @@ -231,7 +232,9 @@ int main(void) c_drop(Vec2D, &vec, &clone); // Cleanup all (6) vectors. } ``` -This example uses four different container types: [ [Run this code](https://godbolt.org/z/x5YKeMrEh) ] +This example uses four different container types: + +[ [Run this code](https://godbolt.org/z/x5YKeMrEh) ] ```c #include @@ -606,6 +609,9 @@ STC is generally very memory efficient. Memory usage for the different container --- # Version History ## Version 4.2 +- New home! And online single headers for https://godbolt.org + - Library: https://github.com/stclib/STC + - Headers, e.g. https://raw.githubusercontent.com/stclib/stcsingle/main/stc/cvec.h - Much improved documentation - Added Coroutines + documentation - Added new crand.h API & header. Old crandom.h is deprecated. diff --git a/docs/pics/containers.jpg b/docs/pics/containers.jpg index cc56a141..2eddd82b 100644 Binary files a/docs/pics/containers.jpg and b/docs/pics/containers.jpg differ -- cgit v1.2.3