I'm trying to figure out how to use codecopy in yul, but I can't see how to get the start position
Jul 27, 2023, 11:51 AM
there's some overhead with solidity converting the data into a bytes array that isn't necessary for what I'm trying to do, which is just to read a couple of bytes at a time from the constant
either way, regardless of my use case, there's an opcode in yul that seems impossible to use?
I'm just using a constant as an example, but in general I can't see how to use codecopy in any way
Jul 27, 2023, 12:01 PM
Codecopys syntax is pretty straightforward isn't it?
codecopy(destination,codeoffset, length)
Jul 27, 2023, 12:05 PM
but there's no way to know the codeoffset
solc clearly knows the offset or constants wouldn't work at all
but I can't seem to get at it
Jul 27, 2023, 12:07 PM