A really fun function name in Common Lisp: the. It returns the value passed in, as well as checking the type. https://www.lispworks.com/documentation/HyperSpec/Body/s_the.htm#the
It reads rather nicely: (the integer foo).
miniblog.
Related Posts
Agentic programming workflows rather remind me of genetic programming. The agent has a validation step that looks like a fitness function, and both run iterative trials.
I'm super impressed by how many lint rules can be implemented with just eslint's no-restricted-syntax and selectors. Example:
{
selector: "ExportNamedDeclaration[declaration=null][source=null]",
message: "Add `export` directly to the function instead of a block export."
}
I'm never sure how to convert words with hyphens into SCREAMING_SNAKE_CASE. For example, should built-in function be BUILT_IN_FUNCTION or BUILTIN_FUNCTION?