Properly check argument count for autojit
Implement typedlist.sort