Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Mention method name in argument_amount report. #172
Other analysis classes name the language element they report on but ArgumentAmount did not.
I have also considered to distinguish class and instance methods but opted for simplicity.
Another way to improve this would be qualifying the method with the class/module it is defined in, but I didn't see an obvious way to determine that.
Yet another way to address this would be omitting the names from the report but quoting the source, clang style:
test.rb:14:9:error: wrong number of arguments (expected 0 but got 1) user.greet(:foo) ^^^^^^^^^^
In theory this should be possible using the
A separate reporter class could probably do this by reading the file (present in an entry), getting the line (also present) and then displaying it below the message.