Generator uses proper type owner UUID during interface conversion
This commit is contained in:
parent
68be34ddfe
commit
40c5d10d4b
@ -124,7 +124,7 @@ func (this *generator) generateAssignmentToDestination ( // TODO: add -Val suffi
|
|||||||
destTypeBase, irDestLoc,
|
destTypeBase, irDestLoc,
|
||||||
irDestType, name)
|
irDestType, name)
|
||||||
key := entity.Key {
|
key := entity.Key {
|
||||||
Unit: sourceType.Unit(),
|
Unit: sourceType.Type.Unit(),
|
||||||
Name: sourceType.Name,
|
Name: sourceType.Name,
|
||||||
Method: name,
|
Method: name,
|
||||||
}
|
}
|
||||||
|
@ -44,11 +44,12 @@ func (this *generator) generateMethodCallVal (call *entity.MethodCall) (llvm.Val
|
|||||||
|
|
||||||
// check for methods on named type
|
// check for methods on named type
|
||||||
if sourceType, ok := call.Source.Type().(*entity.TypeNamed); ok {
|
if sourceType, ok := call.Source.Type().(*entity.TypeNamed); ok {
|
||||||
method, err := this.method(entity.Key {
|
methodKey := entity.Key {
|
||||||
Unit: sourceType.Unit(),
|
Unit: sourceType.Type.Unit(),
|
||||||
Name: sourceType.Name,
|
Name: sourceType.Name,
|
||||||
Method: call.Name,
|
Method: call.Name,
|
||||||
})
|
}
|
||||||
|
method, err := this.method(methodKey)
|
||||||
if _, notFound := err.(errNotFound); !notFound {
|
if _, notFound := err.(errNotFound); !notFound {
|
||||||
source, err := this.generateExpressionLoc(call.Source)
|
source, err := this.generateExpressionLoc(call.Source)
|
||||||
if err != nil { return nil, err }
|
if err != nil { return nil, err }
|
||||||
|
Loading…
Reference in New Issue
Block a user