-
Notifications
You must be signed in to change notification settings - Fork 55
Open
Description
Seeing as inplace_function
is standard layout and cannot allocate, I assumed it would be safe (dependent on what is put in it, of course) to be used across shared library interfaces. Apparently this is not the case.
The mechanism used to identify an empty inplace_function
relies on taking the address of an inline constexpr
global. Perhaps this is specific to MSVC (obviously this is not specified by the standard), but in practice I'm seeing a default constructed function converting to false in one module, but to true (callable) in another module due to differing addresses of empty_vtable
.
Is usage across shared libraries a bad idea in general and intentionally not supported? If not, is this something that can be easily addressed?
Metadata
Metadata
Assignees
Labels
No labels