This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[C++-0x] User defined literals.


This patch repairs all the potential spacing and buffer overrun issues that I could see.

It is still not ready.
1. I would like to get pretty printing so that only one suffix is printed instead of 1.234L_abc or 123456ULL_xyz.
I know how to do this.
2. Templates don't really work. This is proving difficult for my little brain.


I need to parse this:
123_abc;
and replace it with a call to

operator"" _abc<'1', '2', '3'>();

I can call
operator"" _abc<>();

In other words I can't figure out how to get the template args in.

There's stuff in there getting the template function out of OVERLOAD.
Then I try tsubst.  No dice.

3. I can't get friend to work. The operator definition doesn't even get written.
I'm deferring this until after I get templates to work.


All the other aspects of this capability work.

Have at it and thank you all for your patience and help.

Ed

Attachment: patch_literal2
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]