Hacker News new | ask | show | jobs
by guavaNinja 1623 days ago
This[1] is a c-flavoured c++ STL replacement, uses minimal number of c++ features to be easy to use yet simple. We built it and use it internally where I work.

It's not c but almost c, it could be useful for you

[1] https://github.com/MoustaphaSaad/mn/blob/master/mn/include/m...

2 comments

This is still all in c++ correct? why not just using STL instead, am I missing something here.

There are a few pure-C made STL alike containers for C that uses no c++ code at all, a random github search finds this: https://github.com/assyrianic/Harbol , there are quite a few of them just not recalling them now.

Thank you. You don't seem to provide a c_str() equivalent (a method that gives a pointer to or copies out a C-string) or views ? Sorry if I missed them.
We hate getters/setters. There is `using Str = Buf<char>` if you looked into Buf you will find ptr and count and cap. You are looking for ptr