You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Based on the failure that @ijt provided, it appears that Wire is correctly determining the type in analysis, but is emitting incorrect code during the generation step. The change should be straightforward, as Wire changes go:
Provider would need to grow a Varargs bool field to indicate that the last parameter of the provider function is variadic. This would need to be populated during the parse step.
Similarly, call would need to grow a varargs bool field. This would be plumbed through during analysis.
Finally, the information in the call.Varargs would be used in funcProviderCall to determine whether to append ... to the final argument.
This would be a good Wire starter project, as this plumbs a feature through the whole program.
Describe the bug
Wire can't handle functions with varargs.
To Reproduce
google/go-cloud@7cfcbb8
Add a wire.Value entry to provide a concrete value for the parameter.
Run wire.
Expected behavior
The Go file generated by wire should compile, but it doesn't.
https://travis-ci.com/google/go-cloud/jobs/156507298
Version
bf223a0
The text was updated successfully, but these errors were encountered: