We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
When trying to use the RLP builtin functions I got really confused.
This does not work:
import RLP //.... RLP.decodeString("...".utf8) //....
This also does not work:
// import RLP //.... decodeString("...".utf8) //....
But (confusingly) this works:
//import RLP //.... RLP.decodeString("...".utf8) //....
This is a bit confusing, and is not obvious from the docs: https://cadence-lang.org/docs/1.0/language/built-in-functions#rlp
Maybe add an example to the docs, or even allow the import RLP even if it is not doing anything.
import RLP
IMO, the best solution might actually be so that you have to import RLP...
I ran this in a go test env:
import RLP transaction(){ prepare(signer: auth(Storage, Contracts, Keys, Inbox, Capabilities) &Account) { var f: fun(): Void = fun(){} f = fun() { var i = 0 while i < 110 { i = i + 1 RLP.decodeString("xxxxxxxxxxxxxxxxxxxxxx".utf8) } } f() } execute { var f: fun(): Void = fun(){} } }
- Cadence version: 1.0 - Network: any
The text was updated successfully, but these errors were encountered:
We should allow the import and not report an error.
This also applies to other contracts that are part of the standard library, e.g. BLS.
BLS
Sorry, something went wrong.
No branches or pull requests
Current Behavior
When trying to use the RLP builtin functions I got really confused.
This does not work:
This also does not work:
But (confusingly) this works:
Expected Behavior
This is a bit confusing, and is not obvious from the docs: https://cadence-lang.org/docs/1.0/language/built-in-functions#rlp
Maybe add an example to the docs, or even allow the
import RLP
even if it is not doing anything.IMO, the best solution might actually be so that you have to import RLP...
Steps To Reproduce
I ran this in a go test env:
Environment
The text was updated successfully, but these errors were encountered: