[Issue 16165] New: Better error message for mismatched function argument types
via Digitalmars-d-bugs
digitalmars-d-bugs at puremagic.com
Sat Jun 11 17:11:12 PDT 2016
https://issues.dlang.org/show_bug.cgi?id=16165
Issue ID: 16165
Summary: Better error message for mismatched function argument
types
Product: D
Version: D2
Hardware: All
OS: All
Status: NEW
Severity: enhancement
Priority: P1
Component: dmd
Assignee: nobody at puremagic.com
Reporter: johnnymarler at gmail.com
Currently when a function call has mismatched argument types from the function
definition, an error message like this will get printed when compiling with
dmd:
Error: function myfunction(...) is not callable using argument types (...)
When a function has more than a couple arguments (like most Windows functions),
it can take a bit of effort to figure out which argument is incorrect. Adding
extra information like this: "Cannot convert argument 3 'message' from int to
string" or "you've called myfunction with 10 arguments but it only has 9",
would help developers save time trying to figure out what actually went wrong.
--
More information about the Digitalmars-d-bugs
mailing list