2019-09-10 23:15:20 +00:00
|
|
|
#include "logging.hh"
|
2019-09-11 11:10:46 +00:00
|
|
|
#include "rust-ffi.hh"
|
2019-09-10 23:15:20 +00:00
|
|
|
|
|
|
|
namespace nix {
|
|
|
|
|
|
|
|
extern "C" std::exception_ptr * make_error(rust::StringSlice s)
|
|
|
|
{
|
|
|
|
// FIXME: leak
|
|
|
|
return new std::exception_ptr(std::make_exception_ptr(Error(std::string(s.ptr, s.size))));
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|