Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/adah1972/output_container

Automatic output function for STL containers
https://github.com/adah1972/output_container

container cpp cpp17 ostream output stl

Last synced: about 2 months ago
JSON representation

Automatic output function for STL containers

Awesome Lists containing this project

README

        

This is a simple C++ header file to allow outputting of C++ containers.
It is generic and can work with any container that has `begin` and `end`
member functions. It avoids conflicts with existing output functions
(like that for `std::string`) by detecting whether they can be used.

You may want to check out [output_range][1] as well, which is a natural
extension of *output\_container*, supporting not only containers, but
also *ranges* like a C array or other C++20 ranges.

Using this file requires a C++17-compliant compiler.

[1]: https://github.com/adah1972/output_range