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
Sorry , I have a question:
wire.go file must be on main package? If I have wire.go in another package , when I use wire cmd I am getting "undeclared name: methodName" message, and I am not sure why.
EDIT:
If wire.go is in the same folder that a provider it fails:
Example
duplicateThis issue or pull request already exists
1 participant
Heading
Bold
Italic
Quote
Code
Link
Numbered list
Unordered list
Task list
Attach files
Mention
Reference
Menu
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Sorry , I have a question:
wire.go file must be on main package? If I have wire.go in another package , when I use wire cmd I am getting "undeclared name: methodName" message, and I am not sure why.
EDIT:
If wire.go is in the same folder that a provider it fails:
Example
If wire.go is out that folder wire cmd is able to generate wire_gen.go , is it a correct behavior?
When my code looks like:
wire works well
Could you help me please?
Thanks in advance
Beta Was this translation helpful? Give feedback.
All reactions