Module scpd.Cpp
Types currently missing from core
and some additional utilities
Hopefully in the future we can reduce / remove this module.
In the meantime, this is the most pragmatic way to do C++ bindings,
as code in core
needs to care about cross platform,
cross compiler, cross C++ versions compatibility, but we have a much smaller
target.
The first step in reducing / removing this module would be to import exceptions / runtime binding for OSX to Druntime.
See Also
https
//github.com/dlang-cpp-interop
Functions
Name | Description |
---|---|
callCPPDelegate(cb)
|
Invoke an std::function pointer (note: must be void* due to mangling issues) |
make_shared(args)
|
Classes
Name | Description |
---|---|
exception
|
Structs
Name | Description |
---|---|
allocator
|
Can't import core because it transitively imports
core
In this case we just need to get the name right for vector
|
CPPDelegate
|
Simple wrapper around std::function |
duration
|
Simple bindings to std::chrono |
map
|
Fake bindings for std::map |
set
|
Fake bindings for std::set |
shared_ptr
|
Simple binding to std::shared_ptr
|
unique_ptr
|
Simple binding to std::unique_ptr
|
unordered_map
|
Rudimentary bindings for std::unordered_map |
vector
|
Simple bindings from std::vector
|
Aliases
Name | Type | Description |
---|---|---|
milli
|
scpd
|
Simple bindings to std::chrono |
milliseconds
|
duration!(long,scpd.Cpp.ratio!(1,1000).ratio)
|
Simple bindings to std::chrono |
SCPCallback
|
extern(C++) void function()
|
Type of SCP function callback called by a timer |