This is an archive of the discontinued LLVM Phabricator instance.

PR23923: "redefine_extname" pragma handled incorrectly in case of a local var with the same name
ClosedPublic

Authored by andreybokhanko on Jun 23 2015, 4:03 AM.

Details

Summary

As Richard Smith noted in his review (http://lists.cs.uiuc.edu/pipermail/cfe-commits/Week-of-Mon-20150608/130447.html), pragma "redefine_extname" doesn't work correctly when there is a local of the same name. The patch fixes this.

Diff Detail

Event Timeline

andreybokhanko retitled this revision from to PR23923: "redefine_extname" pragma handled incorrectly in case of a local var with the same name.
andreybokhanko updated this object.
andreybokhanko edited the test plan for this revision. (Show Details)
andreybokhanko added a subscriber: Unknown Object (MLST).

Patch updated in response to Aaron Ballman's comment (http://lists.cs.uiuc.edu/pipermail/cfe-commits/Week-of-Mon-20150622/131626.html).

Aaron, everything fixed according to your comments (including adding a new test).

test/CodeGenCXX/redefine_extname.cpp test fixed

andreybokhanko accepted this revision.Jun 25 2015, 8:34 AM
andreybokhanko added a reviewer: andreybokhanko.

Accepted after Aaron's LGTM.

Aaron, thank you for the review!

I don't have commit access yet; Alexander [Musman], could you, please, commit this patch?

This revision is now accepted and ready to land.Jun 25 2015, 8:34 AM
aaron.ballman edited edge metadata.Jun 25 2015, 8:37 AM

I am not Alexander Musman, but I commit your patch anyway. ;-) It's in r240653.

Thanks!

~Aaron