This is an archive of the discontinued LLVM Phabricator instance.

Remove const qualifier from Modules returned by ExternalASTSource. (NFC)
ClosedPublic

Authored by aprantl on Mar 3 2020, 12:58 PM.

Details

Diff Detail

Event Timeline

aprantl created this revision.Mar 3 2020, 12:58 PM

Can you link what code is actually requiring this change? I just went over the patch series and it's not obvious to me what exactly this is used for.

I added a comment to D75488. It's in getOrCreateModule().

I am fine with this if we *really* need it for D75488. So far the only direct place where we do need the module to be non-const was some redundant assignment for Name (I added a comment in D75488), but if that is removed I believe the rest of the code should work with a const Module.

teemperor accepted this revision.Apr 1 2020, 2:29 AM

I seems quite a lot of APIs in Clang are already requiring non-const Modules so I think this is fine to make D75488 possible. Let's ship it

This revision is now accepted and ready to land.Apr 1 2020, 2:29 AM
This revision was automatically updated to reflect the committed changes.
Herald added a project: Restricted Project. · View Herald TranscriptApr 1 2020, 6:00 PM