bind: change wrap pointer logic (HACK)

Change-Id: Idf21382b6b36d253e0ff46d8b86e75f3648ad0ab
This commit is contained in:
Sebastien Binet 2015-08-12 10:25:07 +02:00
parent 9b97454b76
commit c4ad7bd023
1 changed files with 3 additions and 1 deletions

View File

@ -21,7 +21,7 @@ type Type interface {
}
func needWrapType(typ types.Type) bool {
switch typ.(type) {
switch typ := typ.(type) {
case *types.Basic:
return false
case *types.Struct:
@ -45,6 +45,8 @@ func needWrapType(typ types.Type) bool {
return wrap
case *types.Signature:
return true
case *types.Pointer:
return needWrapType(typ.Elem())
}
return false
}