[cfe-dev] -ast-print not printing scope resolution operator

Eli Friedman eli.friedman at gmail.com
Thu Jun 20 11:29:07 PDT 2013


On Thu, Jun 20, 2013 at 11:22 AM, Bin Tzeng <bintzeng at gmail.com> wrote:

> Thanks for the quick reply! Is there any discussion or plan to make it
> accurate (I might miss them) or it is left at the bottom of priority list?
>

It's pretty low on the priority list, but we're happy to review patches.

-Eli


> On Thu, Jun 20, 2013 at 10:59 AM, Eli Friedman <eli.friedman at gmail.com>wrote:
>
>> On Thu, Jun 20, 2013 at 10:43 AM, Bin Tzeng <bintzeng at gmail.com> wrote:
>>
>>> Hi all,
>>>
>>> I am not sure whether this is a bug or intended design. The following
>>> snippet:
>>> class junk {
>>>   void foo(void);
>>> };
>>>
>>> void junk::foo(void) {}
>>> void foo(void) {}
>>>
>>> prints out the following ast with `clang -cc1 -ast-print`:
>>>
>>> class junk {
>>>     void foo();
>>> };
>>> void foo() {
>>> }
>>>
>>>
>>> void foo() {
>>> }
>>>
>>> The class name and its scope resolution operator is missing in the
>>> printed ast for the first method foo. If it is indented, can anybody shed
>>> some light? Thanks!
>>>
>>>
>> If you see a problem with AST printing, it's probably a bug; nobody has
>> really put in a concerted effort to make AST printing round-trip accurately.
>>
>> -Eli
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20130620/d4c2dc8a/attachment.html>


More information about the cfe-dev mailing list