bazelbuild / starlark

Starlark Language
Apache License 2.0
2.44k stars 161 forks source link

Clarify whether each builtin function and method parameter is named #210

Open brandjon opened 2 years ago

brandjon commented 2 years ago

The spec says:

Except where noted, built-in functions accept only positional arguments.

As with built-in functions, built-in methods accept only positional arguments except where noted. The parameter names serve merely as documentation.

But it does not make clear which parameters are in fact named. For instance, x in bool(x) should almost certainly be unnamed, but base in int(..., base=8) should be named.

This issue subsumes #195.

ndmitchell commented 2 years ago

See

These all explicitly have named parameters. I note that min doesn't, which is likely an oversight.