Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
a1369209993
on June 12, 2019
|
parent
|
context
|
favorite
| on:
C++ Patterns: The Badge
You actually need:
template<typename T> Badge<T> FakeBadge() { static struct Stub {} stub; return *(Badge<T>*)&stub; };
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search: