This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/61057] [C++11] operator . considered part of User Defined Literal invocation.
- From: "emsr at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Wed, 09 Jul 2014 15:58:06 +0000
- Subject: [Bug c++/61057] [C++11] operator . considered part of User Defined Literal invocation.
- Auto-submitted: auto-generated
- References: <bug-61057-4 at http dot gcc dot gnu dot org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61057
emsr at gcc dot gnu.org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution|--- |INVALID
--- Comment #2 from emsr at gcc dot gnu.org ---
As someone who has dabbled in Ruby I am sympathetic to the request to have this
work. After looking at the standard language and our implementation I must
conclude that your code is invalid. I then tried to imagine a way, for
example, if the stuff after a dot could not be a mantissa stop processing chars
at the dot so the remainder can become an invocation or access. Unfortunately,
123. is a valid double so this idea can't work even as an extension.
FWIW, character and string user-defined literals can have invocations like
"Hello, World!!!"s.length().
Perhaps two dots could signal a termination of a literal as was tried for '_'
as digit separator. This would require much noodling by the standards folks
though.
I'll ponder this last idea but I'll mark this as resolved invalid.