string form. Starting with that plain string, I'd like to get the type's
(ultimate) backing type. The best enumeration of backing types that I am
aware of is reflect.Kind <http://golang.org/pkg/reflect/#Kind>.
I have a package's ast, and a string which names a type ("int" or "MyType"
or "YourType"). Let's assume that any types are either builtin or
specified in the package for which I have the ast. External dependencies
are out of scope.
If I'd like to discover whether MyType is ultimately backed by float64, how
might I do that, given the above?
As I mentioned, reflect.Kind is the *form* of data I am looking for but
it's important to note what I am doing is *not at runtime*. I am inspecting
source code, not reflecting on instances. (Though maybe a solution involves
doing so somehow.)
Looking for ideas, and let me know if the problem description confuses.
You received this message because you are subscribed to the Google Groups "golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email to email@example.com.
For more options, visit https://groups.google.com/groups/opt_out.