Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/andreasfertig/programming-with-cpp20
/ as
Method
as
01.33-optional6/main.cpp:71–71 ·
view source on GitHub ↗
Source
from the content-addressed store, hash-verified
69
storage_t() = default;
70
71
T* as() { return reinterpret_cast<T*>(&data); }
72
// use placement new to create an instance of T inside this
73
// union
74
};
Callers
2
~optional
Method · 0.45
~optional
Method · 0.45
Calls
no outgoing calls
Tested by
no test coverage detected