Re: [csswg-drafts] [css-functions-mixins] Handling superfluous arguments (#11190)

Yeah, (1) isn't an issue, just a question (and the answer is "yes"). I've renamed this issue. And as for "The [current functions spec](https://drafts.csswg.org/css-mixins-1/#function-rule) does not appear to mention this yet", it is called out in Example 3, but it's not in the grammar because it's not custom-functions specific; it's a new *generic* functionality [defined in Values 5](https://drafts.csswg.org/css-values-5/#component-function-commas) for any function that takes an "arbitrary value" argument.

For (2), I don't think that I have a strong opinion either way. I think I'm lightly inclined towards making it an error, as it is in most programming languages (and in CSS for built-ins).

The use-case you mention (building arrays using custom functions) should be addressed more directly, I think. I've been sitting on an [nth-value()](https://github.com/w3c/csswg-drafts/issues/5009#issuecomment-626072319) suggestion for a long while which would do this, and actually passes the index as an argument so it's *more* dynamically usable.

-- 
GitHub Notification of comment by tabatkins
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/11190#issuecomment-2596276757 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Thursday, 16 January 2025 17:12:46 UTC