Hacker News new | ask | show | jobs
by kazinator 3751 days ago
While &key is CL-specific (and if you don't have it, you can ad-hoc it if you have variable arguments) variadic functions are pretty important, and found broadly in Lisp dialects.

If you're on a VM or other target that doesn't do them natively, it's worth fighting tooth and nail to somehow get the functionality.

E.g. make an inefficient variadic type that at the VM level takes a single argument---a list or vector of the arguments. Or multiple types for different combinations of fixed arg arity plus variable list.

2 comments

>E.g. make an inefficient variadic type that at the VM level takes a single argument---a list or vector of the arguments. Or multiple types for different combinations of fixed arg arity plus variable list.

This would hurt interop with Erlang, which seems to be a goal of LFE.

> variadic functions are pretty important

As you already wrote in another comment, most practical uses of variadic functions can be replaced by macros.

What remains that is worth fighting the platform for?