KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
I'm not even sure if negative User-Defined Literals are allowed. If not, why were they left out? For example, I would like to use: auto money_i_owe_jack = -52_jpy; This is what I tried using gcc 4.7.2: constexpr int64_t operator "" _jpy(long long l) { return static_cast<int64_t>(l); } ERROR Test_udl.cpp:60:47: error: ‘constexpr int64_t operator"" _jpy(long long int)’ has invalid argument list
Tags (comma-separated)
Save Edits
Cancel