An exported function or method returning a value of an un-exported type may be frustrating to use. Non-preferred way: go type unexportedType string func ExportedFunc() *unexportedType { return &unexportedType("some string") } Preferred way: go type ExportedType string func ExportedFunc() *ExportedType { return &ExportedType("some string") }
Occurrences
There are 16 occurrences of this issue in the repository.
Description
An exported function or method returning a value of an un-exported type may be frustrating to use. Non-preferred way:
go type unexportedType string func ExportedFunc() *unexportedType { return &unexportedType("some string") }
Preferred way:go type ExportedType string func ExportedFunc() *ExportedType { return &ExportedType("some string") }
Occurrences
There are 16 occurrences of this issue in the repository.
See all occurrences on DeepSource → deepsource.io/gh/ii64/tanem/issue/RVV-B0011/occurrences/