Commit a805756 1 parent abeb375 commit a805756 Copy full SHA for a805756
File tree 2 files changed +14
-8
lines changed
2 files changed +14
-8
lines changed Original file line number Diff line number Diff line change @@ -4634,14 +4634,6 @@ static void CompleteDecl(
4634
4634
ContainerDecl* containerDecl,
4635
4635
Modifiers modifiers)
4636
4636
{
4637
-
4638
- // If this is a namespace and already added, we don't want to add to the parent
4639
- // Or add any modifiers
4640
- if (as<NamespaceDecl>(decl) && decl->parentDecl )
4641
- {
4642
- return ;
4643
- }
4644
-
4645
4637
// Add any modifiers we parsed before the declaration to the list
4646
4638
// of modifiers on the declaration itself.
4647
4639
//
@@ -4699,6 +4691,13 @@ static void CompleteDecl(
4699
4691
}
4700
4692
}
4701
4693
4694
+ // If this is a namespace and already added, we don't want to add to the parent
4695
+ // Or add any modifiers
4696
+ if (as<NamespaceDecl>(decl) && decl->parentDecl )
4697
+ {
4698
+ return ;
4699
+ }
4700
+
4702
4701
if (!as<GenericDecl>(containerDecl))
4703
4702
{
4704
4703
// Make sure the decl is properly nested inside its lexical parent
Original file line number Diff line number Diff line change
1
+ //DIAGNOSTIC_TEST:SIMPLE(filecheck=CHECK): -target spirv
2
+
3
+ struct Type
4
+ {
5
+ // CHECK: ([[# @LINE+1]]): error 30102:
6
+ namespace ns {}
7
+ }
You can’t perform that action at this time.
0 commit comments