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
Please answer these questions before submitting your issue. Thanks!
How I can list all structs and functions by package name, or create a struct instance by struct name,such as
package test
type User struct {
Name string
}
func getStructNameByPackageName(packageName string) []string{
...
}
func createStructInstance(structName string) interface{}{
...
}
call function getStructNameByPackageName("test") we will get result: ['User']
call function createStructInstance("test.User") we will get result: a User instance
I scan many pages on the web,but most people say cann't do these. If can ,please tell me, thank you very much
What version of Go are you using (go version)?
1.7.3
Does this issue reproduce with the latest release?
What operating system and processor architecture are you using (go env)?
What did you do?
If possible, provide a recipe for reproducing the error.
A complete runnable program is good.
A link on play.golang.org is best.
What did you expect to see?
What did you see instead?
The text was updated successfully, but these errors were encountered:
Thank you for raising this issue. Unlike many projects on GitHub, the Go project does not use its bug tracker for general discussion or asking questions. We only use our bug tracker for tracking bugs and tracking proposals going through the Proposal Process.
Please answer these questions before submitting your issue. Thanks!
How I can list all structs and functions by package name, or create a struct instance by struct name,such as
package test
type User struct {
Name string
}
func getStructNameByPackageName(packageName string) []string{
...
}
func createStructInstance(structName string) interface{}{
...
}
I scan many pages on the web,but most people say cann't do these. If can ,please tell me, thank you very much
What version of Go are you using (
go version
)?1.7.3
Does this issue reproduce with the latest release?
What operating system and processor architecture are you using (
go env
)?What did you do?
If possible, provide a recipe for reproducing the error.
A complete runnable program is good.
A link on play.golang.org is best.
What did you expect to see?
What did you see instead?
The text was updated successfully, but these errors were encountered: