Skip to content

Commit 70f8506

Browse files
committed
Allow anonymous object alias, closes #787
1 parent 8a93460 commit 70f8506

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

source/sema.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1205,11 +1205,12 @@ class sema
12051205
n.has_name("_")
12061206
&& !n.is_object()
12071207
&& !n.is_namespace()
1208+
&& !n.is_object_alias()
12081209
)
12091210
{
12101211
errors.emplace_back(
12111212
n.identifier->position(),
1212-
"'_' (wildcard) may not be the name of a function or type - it may only be used as the name of an anonymous object or anonymous namespace"
1213+
"'_' (wildcard) may not be the name of a function or type - it may only be used as the name of an anonymous object, object alias, or namespace"
12131214
);
12141215
return false;
12151216
}

0 commit comments

Comments
 (0)