We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
If I have something like the following and replace X with int
type _X_ generic.Type type Cell_X_ struct { Value int } func m(_X_) {} func example() { a := Cell_X_{} m(Cell_X_{}) }
The following code which wont compile is generated.
type CellInt struct { Value int } func m(int) {} func example() { a := CellInt{} m(Cellint{}) }
Is this a limitation in how genny works or a bug?
The text was updated successfully, but these errors were encountered:
Looks like a bug in your code. Shouldn't the argument to m be Cell_X_? And shouldn't the value of Value be X?
Sent from my iPhone
On 12 Oct 2015, at 19:15, Martin Karlsch notifications@github.com wrote: If I have something like the following and replace X with int type X generic.Type type Cell_X_ struct { Value int } func m(X) {} func example() { a := Cell_X_{} m(Cell_X_{}) } The following code which wont compile is generated. type CellInt struct { Value int } func m(int) {} func example() { a := CellInt{} m(Cellint{}) } Is this a limitation in how genny works or a bug? — Reply to this email directly or view it on GitHub.
On 12 Oct 2015, at 19:15, Martin Karlsch notifications@github.com wrote:
type X generic.Type
type Cell_X_ struct { Value int }
func m(X) {}
func example() { a := Cell_X_{} m(Cell_X_{}) }
type CellInt struct { Value int }
func m(int) {}
func example() { a := CellInt{} m(Cellint{}) } Is this a limitation in how genny works or a bug?
— Reply to this email directly or view it on GitHub.
Sorry, something went wrong.
You are right, the example was not entirely correct ... should be.
type _X_ generic.Type type Cell_X_ struct { Value _X_ } func m(p Cell_X_) {} func example() { a := Cell_X_{} m(Cell_X_{}) }
leads to
package main type CellInt struct { Value int } func m(p CellInt) {} func example() { a := CellInt{} m(Cellint{}) }
The issue is the same. The Cell_X_ passed to m has a lower case "i" whereas the rest has an uppercase "I".
It's almost the same as #49 and #36. Will be fixed in the next release.
Fixed in #52
No branches or pull requests
If I have something like the following and replace X with int
The following code which wont compile is generated.
Is this a limitation in how genny works or a bug?
The text was updated successfully, but these errors were encountered: