mirror of
https://github.com/c3lang/c3c.git
synced 2026-02-27 12:01:16 +00:00
Missing error on default values for body with default arguments #2148.
This commit is contained in:
14
test/test_suite/macros/macro_body_error_2148.c3
Normal file
14
test/test_suite/macros/macro_body_error_2148.c3
Normal file
@@ -0,0 +1,14 @@
|
||||
import std;
|
||||
|
||||
fn void main()
|
||||
{
|
||||
@foo(;int x)
|
||||
{
|
||||
io::printn(x);
|
||||
};
|
||||
}
|
||||
|
||||
macro @foo(; @body(int x = 1)) // #error: Body parameters
|
||||
{
|
||||
@body(3);
|
||||
}
|
||||
Reference in New Issue
Block a user