feat: reverse argument order of List.insert to index-first convention
The previous signature `insert(element, index)` was counter-intuitive and inconsistent with every major language's list API. This commit swaps the parameters to `insert(index, element)`, matching the convention used by Ruby, JavaScript, C++, Lua, C#, Java, and Python. All documentation, C implementation, and test files are updated to reflect the new order.
This commit is contained in:
@@ -17,7 +17,7 @@ Removes all items from the list.
|
||||
|
||||
The number of items in the list.
|
||||
|
||||
### **insert**(item, index)
|
||||
### **insert**(index, item)
|
||||
|
||||
**TODO**
|
||||
|
||||
|
||||
Reference in New Issue
Block a user