mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Simple size check for old ABI decoder.
This commit is contained in:
committed by
Alex Beregszaszi
parent
2cdf44f65c
commit
32c94f5059
@@ -90,8 +90,12 @@ public:
|
||||
|
||||
/// Creates code that unpacks the arguments according to their types specified by a vector of TypePointers.
|
||||
/// From memory if @a _fromMemory is true, otherwise from call data.
|
||||
/// Expects source offset on the stack, which is removed.
|
||||
void abiDecode(TypePointers const& _typeParameters, bool _fromMemory = false);
|
||||
/// Calls revert if @a _revertOnOutOfBounds is true and the supplied size is shorter
|
||||
/// than the static data requirements or if dynamic data pointers reach outside of the
|
||||
/// area. Also has a hard cap of 0x100000000 for any given length/offset field.
|
||||
/// Stack pre: <source_offset> <length>
|
||||
/// Stack post: <value0> <value1> ... <valuen>
|
||||
void abiDecode(TypePointers const& _typeParameters, bool _fromMemory = false, bool _revertOnOutOfBounds = false);
|
||||
|
||||
/// Copies values (of types @a _givenTypes) given on the stack to a location in memory given
|
||||
/// at the stack top, encoding them according to the ABI as the given types @a _targetTypes.
|
||||
@@ -154,7 +158,7 @@ public:
|
||||
/// Decodes data from ABI encoding into internal encoding. If @a _fromMemory is set to true,
|
||||
/// the data is taken from memory instead of from calldata.
|
||||
/// Can allocate memory.
|
||||
/// Stack pre: <source_offset>
|
||||
/// Stack pre: <source_offset> <length>
|
||||
/// Stack post: <value0> <value1> ... <valuen>
|
||||
void abiDecodeV2(TypePointers const& _parameterTypes, bool _fromMemory = false);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user