diff: clarify the AppendScope() call comment in TypePrinter::PrintTag()

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

diff: clarify the AppendScope() call comment in TypePrinter::PrintTag()

Vladimir Kirillov
Hello, cfe-dev!

As I've been digging into TypePrinter lately, I've noticed
a mismatch between the comment and the reality:

origin: clang/lib/AST

Index: TypePrinter.cpp
===================================================================
--- TypePrinter.cpp     (revision 112370)
+++ TypePrinter.cpp     (working copy)
@@ -431,8 +431,9 @@
   }
 
   if (!Policy.SuppressScope)
-    // Compute the full nested-name-specifier for this type. In C,
-    // this will always be empty.
+    // Compute the full nested-name-specifier for this type.
+    // In C, this will always be empty except when the type
+    // being printed is anonymous within other Record.
     AppendScope(D->getDeclContext(), Buffer);
 
   if (const IdentifierInfo *II = D->getIdentifier())

_______________________________________________
cfe-dev mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev
Reply | Threaded
Open this post in threaded view
|

Re: diff: clarify the AppendScope() call comment in TypePrinter::PrintTag()

Chris Lattner
On Aug 28, 2010, at 7:27 AM, Vladimir Kirillov wrote:

> Hello, cfe-dev!
>
> As I've been digging into TypePrinter lately, I've noticed
> a mismatch between the comment and the reality:

Applied in r112374, thanks!  For future patches, please send them as attachments, it makes it easier to apply them. Thanks again,

-Chris

>
> origin: clang/lib/AST
>
> Index: TypePrinter.cpp
> ===================================================================
> --- TypePrinter.cpp     (revision 112370)
> +++ TypePrinter.cpp     (working copy)
> @@ -431,8 +431,9 @@
>   }
>
>   if (!Policy.SuppressScope)
> -    // Compute the full nested-name-specifier for this type. In C,
> -    // this will always be empty.
> +    // Compute the full nested-name-specifier for this type.
> +    // In C, this will always be empty except when the type
> +    // being printed is anonymous within other Record.
>     AppendScope(D->getDeclContext(), Buffer);
>
>   if (const IdentifierInfo *II = D->getIdentifier())
>
> _______________________________________________
> cfe-dev mailing list
> [hidden email]
> http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev


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