[erlang-questions] ANN: nifpp-2.0
Daniel Goertzen
daniel.goertzen@REDACTED
Fri Feb 14 17:59:28 CET 2014
nifpp is a C++11 wrapper for the Erlang NIF API. I have updated nifpp to
support v17 maps, and I have also removed the requirement to patch
"erl_nif.h". A quick nifpp maps example...
// create #{abc=>123, pqr=>456}
std::map<nifpp::str_atom, int> cppmap;
cppmap["abc"] = 123;
cppmap["pqr"] = 456;
ERL_NIF_TERM t = nifpp::make(env, cppmap);
See https://github.com/goertzenator/nifpp
Nifpp enhances the Erlang NIF API for C++ by providing:
- Overloaded get()/make() wrappers for the enif_get_xxx()/enif_make_xxx() C
API.
- get()/make() support for STL containers tuple, vector, array, list,
deque, set, unordered_set, multiset, map, and unordered_map.
- get()/make() support for nested containers.
- A resource pointer type so that any type can be easily used as a NIF
resource. Think of it as a std::shared_ptr that the emulator can hold
references to.
All feedback welcome,
Dan.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20140214/6c8db5fc/attachment.htm>
More information about the erlang-questions
mailing list