Add helper functions `canonicalSymbol` and `methodArgumentsString` to extract and format the argument count from symbol names. Update the runtime error message in `runInterpreter` to append the arity (e.g., "with 0 arguments", "with 2 arguments", "with 1 argument") when a class does not implement a method. Add new test cases for missing methods with one, two, and eleven arguments, and update all existing test expectations to include the arity suffix.
3 lines
110 B
Plaintext
3 lines
110 B
Plaintext
class Foo {}
|
|
|
|
Foo.bar // expect runtime error: Foo metaclass does not implement method 'bar' with 0 arguments. |