mirror of
https://github.com/c3lang/c3c.git
synced 2026-02-27 12:01:16 +00:00
Allow $defined take declarations: $defined(int x = y)
Taking the address of a label would cause a crash. #2430
This commit is contained in:
@@ -188,8 +188,9 @@ fn LinkedEntry*? LinkedHashMap.get_entry(&map, Key key)
|
||||
}
|
||||
|
||||
<*
|
||||
Get the value or update and
|
||||
@require @assignable_to(#expr, Value)
|
||||
Get the value or set it to the value
|
||||
|
||||
@require $defined(Value val = #expr)
|
||||
*>
|
||||
macro Value LinkedHashMap.@get_or_set(&map, Key key, Value #expr)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user