[PATCH] D41627: [Modules TS] Fix namespace visibility

2018-07-21 Thread Hamza Sood via Phabricator via cfe-commits
hamzasood updated this revision to Diff 156689. hamzasood added a comment. - Don't assume that -fmodules-ts implies that we're in a TS module. - Don't ignore private namespaces when calculating the ownership kind. https://reviews.llvm.org/D41627 Files: include/clang/AST/DeclBase.h lib/AST/D

[PATCH] D41627: [Modules TS] Fix namespace visibility

2018-04-27 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: lib/AST/DeclBase.cpp:285 +Decl::ModuleOwnershipKind Decl::getModuleOwnershipKindForChildOf(DeclContext *DC) { + // Ignore namespaces because they're visible by default. + while (DC && DC->isNamespace()) "because they'r

[PATCH] D41627: [Modules TS] Fix namespace visibility

2017-12-29 Thread Hamza Sood via Phabricator via cfe-commits
hamzasood created this revision. hamzasood added reviewers: rsmith, bruno, boris. Namespaces without an explicit `export` were being mistakenly marked as module private. This patch fixes the visibility as per `[basic.namespace]p1` and adds a test case with previously rejected (yet valid) code.