-
Notifications
You must be signed in to change notification settings - Fork 757
Open
Labels
Description
The spec says:
If passed a dashed-function, the arguments passed to the dashed-function are mapped to the mixin’s arguments; if more arguments are passed than the length of the mixin’s argument list, the @apply application does nothing. (Passing too few arguments is fine; the missing arguments take their default values instead.)
However, what if the missing arguments do not have default values? I can see three different interpretations:
- The entire
@applycall is invalid, and is ignored (whether the parameter is ever used or not). - Missing default values are treated as no
@envfor that parameter at all. This means you can use them in fallbacks (env(--missing-argument, blue)will returnblue), butenv(--missing-argument)with no fallback will be IACVT (unless an@envwith the same name has been declared higher up in the chain, possibly by another mixin). - Missing default values are treated as an
@envwith the guaranteed-invalid value, so you can use them in fallbacks like above but they will shadow any previous@envwith the same name.