Releases: cakevm/huff-neo
Releases · cakevm/huff-neo
v1.1.1
- Update dependencies to the latest version.
v1.1.0
- Support for constants in code tables.
- Use correct code line for error messages in code tables for built-ins.
- Switch to Foundry's print function for trace logs.
- Allow using
--target-addressto specify the contract address during a test. - Disable base fee check for tests.
- Allow uneven bytes for code tables e.g.
0x1is valid and results in0x01bytecode. - Introduce new lexer token type
Bytes, as not all hex should be parsed to bytes32.- For constants in code tables, the bytes are copied as defined with e.g. leading zeros.
- For all other cases, leading zeros are removed and the smallest push operation is used.
- New built-in function
__LEFTPADto a pad a hex input or a function result in a code table to the left in 32 bytes.- The function can only be used in a code table.
- Example:
__LEFTPAD(0x123)->0000000000000000000000000000000000000000000000000000000000000123
- Allow to pass a constant as a parameter to
__RIGHTPADor__LEFTPAD.- Example:
__RIGHTPAD([CONST])
- Example:
- Allow to use built-in functions in constant assignment.
- Example:
#define constant FUNC_TEST = __FUNC_SIG("test(uint256)") - This solves the issue to define functions with the same name but different arguments.
- Example:
v1.0.8
- Support built-in function calls in code table (
#define table) body.- Supported are
__BYTES,__FUNC_SIG, and__RIGHTPAD.
- Supported are
v1.0.7
- Add built-in macros for converting a string to bytes and push it to the stack.
__BYTES("hello")->PUSH5 0x68656c6c6f- This can also be used here:
__RIGHTPAD(__BYTES("hello")).
v1.0.6
- Allow to use
--debugfor reverting contracts. - Refactored parsing for ABI and build-in argument.
- This is the first step to push more steps into the lexing phase.
- Extend parsing to allow
__FUNC_SIGinside of__RIGHTPAD.- Example:
__RIGHTPAD(__FUNC_SIG('transfer(address,uint256)')).
- Example:
v1.0.5
- Use foundry's debugger for
--debugflag.
v1.0.4
- Rewrite the Huff test module to use
anvilandforgefeatures fromfoundryto fork the mainnet.- This is experimental, and there will be some breaking changes.
- Allow printing logs with
-vvvand call traces for tests with-vvvv. - Add
forgeEVM feature flags for testing.- Known issues: The CLI reports more features than are actually available.
- Breaking: Remove the Huff cheat code for logging.
- The
foundryconsole.logshould now be used.
- The
- Breaking: Remove logs from the test JSON output for now.
- Fix error reporting for invalid literals during lexing in the test command.
- Add
Cancunas an EVM version and make it the default. - Breaking: The
-fflag for formatting the output is now replaced with the fork URL. Please use--formatinstead. - Tokio is now used for the test runner to be able to use the db backend from
foundry.
v1.0.3
- Remove huff-examples submodule
- Fix invalid error mapping for import with unmatched jump labels
- Print unmatched jump labels
v1.0.2
- Use latest stable Rust version 1.84
- Report error for invalid hex literals
0x0x - Improve lexer performance by 1-2% by removing unnecessary cloning
- Allow to use same name for test and macro or fn
v1.0.1
- Validate that a constant hex literal is not longer than 32 bytes
- New flatten source algo to determine spans
- Fix all errors related to invalid source code mapping
- Limit label duplicate check to containing macro and file