Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
code review from reddit #4
I find your lib interesting. I posted it on reddit and there's a thorough code review which highlights issues: https://www.reddit.com/r/Common_Lisp/comments/azs5hm/listopia_a_list_manipulation_library_port_of/
The function is recursive. Not even tail recursive. Then it calls .init.
Which calls LENGTH for every list, which traverses the full list. Cheaper: does the list have atleast two elements?
Above is limited to lists with the length of the supported lengths of argument lists. Which is 50 in ABCL.
.scanl is recursive -> stack overflows...
Don't use a vector. Use a structure instead.
Probably better (for example because it won't have stack overflows):