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
OK, I have a bit of problem with one change in this commit: fc8cc58
If you look at Function.swift (https://github.com/Vaultio/EtherKit/blob/fc8cc589a0bf92c819f86778cf3955fbbc588156/EtherKit/Models/Function.swift),
then you can notice there are two public init which are exactly the same, but one expects an array of ABIType and one an array of ABIValueType.
And since the name of the parameters are the same, you have to explicitly type the init like this: let testViewFuncFunctionCall = Function(name: "testViewFunc", parameters: [] as [ABIType])
instead of this: let testViewFuncFunctionCall = Function(name: "testViewFunc", parameters: [])
Do you think that it maybe would be easier to change the parameters in one init to something like "valueTypeParameters"?
Let me know what you think 🙂
Marek from Ackee.
The text was updated successfully, but these errors were encountered:
Now that I think about it, it's maybe better to explicitly define empty arrays with as [ABIType] since non-empty arrays compile just fine, but it's still something to consider ...
OK, I have a bit of problem with one change in this commit: fc8cc58
If you look at
Function.swift
(https://github.com/Vaultio/EtherKit/blob/fc8cc589a0bf92c819f86778cf3955fbbc588156/EtherKit/Models/Function.swift),then you can notice there are two
public init
which are exactly the same, but one expects an array ofABIType
and one an array ofABIValueType
.And since the name of the parameters are the same, you have to explicitly type the init like this:
let testViewFuncFunctionCall = Function(name: "testViewFunc", parameters: [] as [ABIType])
instead of this:
let testViewFuncFunctionCall = Function(name: "testViewFunc", parameters: [])
Do you think that it maybe would be easier to change the parameters in one init to something like "valueTypeParameters"?
Let me know what you think 🙂
Marek from Ackee.
The text was updated successfully, but these errors were encountered: