forbidigo
forbidigo copied to clipboard
Include type info for unknown packages
builtin
package is non detected (maybe some others too) which results in missing both package and type info in match string. I propose to keep as much info as possible. Should allow matching of builtin
type functions too.
For example:
var err error
err.Error() -----> results in .Error
match string. With this change it will be .error.Error
@isergieienkov Thanks for your proposal and sorry for not reviewing it sooner. Is it possible to write a test for this behavior so I can better understand the issue? As I understand it, you'd like to forbid some identifiers in the builtin
package. Thanks.
Added test for this case