Improving source type info for typeof nodes.

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Improving source type info for typeof nodes.

Enea Zaffanella
Hello.

Please find attached a patch for improving the type source info
available for TypeOfExprType and TypeOfType nodes.

The augmented TypeOf(Expr)TypeLoc nodes provide info about:
   - the location of the typeof keyword;
   - the locations of the left&right parentheses (may be invalid);
   - the source range for the whole typeof construct;
   - source type info for the underlying type (for TypeOfType nodes).

The patch passes all clang tests.

Cheers,
Enea Zaffanella.

_______________________________________________
cfe-dev mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev

Typeof-TypeLoc.patch (12K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Improving source type info for typeof nodes.

John McCall

On Jan 13, 2010, at 7:47 AM, Enea Zaffanella wrote:

> Hello.
>
> Please find attached a patch for improving the type source info available for TypeOfExprType and TypeOfType nodes.
>
> The augmented TypeOf(Expr)TypeLoc nodes provide info about:
>  - the location of the typeof keyword;
>  - the locations of the left&right parentheses (may be invalid);
>  - the source range for the whole typeof construct;
>  - source type info for the underlying type (for TypeOfType nodes).
>
> The patch passes all clang tests.

Looks great.  Committed as r93344, thanks!

John.
_______________________________________________
cfe-dev mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev