Skip to content

Commit be67025

Browse files
committed
[Test] Add test for already-fixed macro example.
This used to cause a circular reference and crash. No more, but make sure we don't regress it. From rdar://109280926. (cherry picked from commit 19ca63a)
1 parent fd2fe5a commit be67025

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

test/Macros/macro_expand.swift

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -417,3 +417,10 @@ func testFreestandingClosureNesting() {
417417
func testLocalVarsFromDeclarationMacros() {
418418
#varValue
419419
}
420+
421+
// Variadic macro
422+
@freestanding(declaration, names: arbitrary) macro emptyDecl(_: String...) = #externalMacro(module: "MacroDefinition", type: "EmptyDeclarationMacro")
423+
424+
struct TakesVariadic {
425+
#emptyDecl("foo", "bar")
426+
}

0 commit comments

Comments
 (0)