mirror of
https://github.com/mutouyun/cpp-ipc.git
synced 2025-12-06 16:56:45 +08:00
The issue occurs when container_allocator calls ipc::construct<T>() with no arguments.
MSVC and GCC have different behaviors regarding std::is_constructible for std::map's
internal node type.
Solution:
- Add explicit overload for zero-argument construct() using value initialization T()
- Separate overloads for one or more arguments to avoid SFINAE ambiguity
- This ensures MSVC uses direct initialization T() instead of aggregate initialization T{}
Fixes compilation error on Visual Studio 2017:
error C2512: no appropriate default constructor available
note: Invalid aggregate initialization
|
||
|---|---|---|
| .. | ||
| aligned.h | ||
| byte.h | ||
| codecvt.h | ||
| detect_plat.h | ||
| error.h | ||
| expected.h | ||
| export.h | ||
| fmt_cpo.h | ||
| fmt.h | ||
| generic.h | ||
| log.h | ||
| nameof.h | ||
| result.h | ||
| scope_exit.h | ||
| span.h | ||
| system.h | ||
| uninitialized.h | ||