mirror of https://github.com/go-python/gopy.git
bind: change wrap pointer logic (HACK)
Change-Id: Idf21382b6b36d253e0ff46d8b86e75f3648ad0ab
This commit is contained in:
parent
9b97454b76
commit
c4ad7bd023
|
@ -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
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue