-
Notifications
You must be signed in to change notification settings - Fork 94
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge commit 'pullrequests/Ralph7C2/genericparams'
- Loading branch information
Showing
6 changed files
with
251 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
package genericparam | ||
|
||
import ( | ||
"github.com/maxbrunsfeld/counterfeiter/v6/fixtures/genericparam/genericparamtype" | ||
"github.com/maxbrunsfeld/counterfeiter/v6/fixtures/genericparam/genericreturntype" | ||
) | ||
|
||
//counterfeiter:generate . GenericParamFunc | ||
type GenericParamFunc func(Generic[genericparamtype.T]) Generic[genericreturntype.R] | ||
|
||
//counterfeiter:generate . GenericParamInterface | ||
type GenericParamInterface interface { | ||
DoSomething(Generic[genericparamtype.T]) Generic[genericreturntype.R] | ||
} | ||
|
||
type Generic[T any] struct{ _ T } |
112 changes: 112 additions & 0 deletions
112
fixtures/genericparam/genericparamfakes/fake_generic_param_func.go
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
113 changes: 113 additions & 0 deletions
113
fixtures/genericparam/genericparamfakes/fake_generic_param_interface.go
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
package genericparamtype | ||
|
||
type T string |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
package genericreturntype | ||
|
||
type R struct{} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters