Commit Graph

6134 Commits

Author SHA1 Message Date
chriseth
f75b55071e Remove CharStream from SourceLocation. 2021-07-14 15:12:07 +02:00
chriseth
e5ab68ed71 Use unknown file for invalid source index. 2021-07-12 17:35:49 +02:00
Christian Parpart
5e4868d5d6 Adapted tests due to more precise Yul source locations.
Also added support for -1 source index, referencing original scanner's source location.
2021-07-09 11:50:48 +02:00
Christian Parpart
132fa46faa Yul: Adds parsing @src comment in AsmParser to customize the AST's sourcer locations. 2021-07-09 11:48:00 +02:00
chriseth
fec01c112a
Merge pull request #11616 from ethereum/issue-8191-yul
Test yul code blocks in documentation.
2021-07-08 15:37:01 +02:00
Marenz
d844d84b51 Test yul code blocks in documentation. 2021-07-08 14:59:05 +02:00
chriseth
62934b60ca
Merge pull request #11605 from ethereum/issue-8191
isolate_tests: Extract code blocks from documentation using code block header
2021-07-08 14:28:47 +02:00
chriseth
691083c032
Merge pull request #11632 from ethereum/yulNegationFunctionNameCollision
Fix negation function name collision.
2021-07-08 12:20:17 +02:00
Marenz
9a0da17a6d Use more readable and maintainable multiline strings in py test script 2021-07-08 10:49:29 +02:00
Daniel Kirchner
0a6fc89da2 Fix negation function name collision. 2021-07-08 10:47:29 +02:00
Christian Parpart
f9f32c910d Fix source location for `if` statements. 2021-07-07 17:37:01 +02:00
chriseth
46514ffad2
Merge pull request #11520 from ethereum/local-streams-in-command-line-parser
Local output streams in CommandLineParser
2021-07-07 15:07:23 +02:00
Kamil Śliwak
baced5d10e Test for the --help option 2021-07-07 12:53:15 +02:00
Kamil Śliwak
6c33fbcb6a CommandLineParser: Replace global sout/serr streams with class members
- This removes the global variable and prevents stderr/stdout from being printed in tests
2021-07-07 12:53:15 +02:00
chriseth
566537835b
Merge pull request #11627 from ethereum/allowEmptyFileName
Include locations with empty source name.
2021-07-07 12:52:49 +02:00
Kamil Śliwak
ce11ebb687
Merge pull request #11518 from ethereum/command-line-parser
CommandLineParser
2021-07-07 12:51:09 +02:00
chriseth
6ba298c82b Include locations with empty source name. 2021-07-07 12:13:52 +02:00
Kamil Śliwak
ef7abd224d Tests for all input modes in CommandLineParser 2021-07-06 17:17:18 +02:00
Marenz
5291ca2dd4 isolate_tests: Extract code blocks from documentation using code block header 2021-07-06 16:57:05 +02:00
chriseth
8d5e82b406 Fix source location of builtin function calls. 2021-07-06 16:54:29 +02:00
chriseth
09578e7e22
Merge pull request #11550 from ethereum/runs-constant
Constant for default --runs
2021-07-06 10:44:07 +02:00
Kamil Śliwak
105b4b4c8b Update tests 2021-07-05 13:46:53 +02:00
Kamil Śliwak
a72857df03 CommonIO: Replace readStandardInput() with readUntilEnd() with a configurable stream 2021-07-02 14:58:30 +02:00
Kamil Śliwak
e3b345e5f0 Use a simpler stack optimization test to avoid having ICE message with absolute paths as expected output 2021-07-01 17:29:24 +02:00
Kamil Śliwak
753f359157 Replace stack optimization command-line test with Standard JSON ones
- It's not possible to run optimizer with only stack optimization enabled on the CLI.
2021-07-01 16:54:09 +02:00
Kamil Śliwak
9d08b5001f Add sstore to linker tests to prevent the address from being optimized out 2021-07-01 16:54:09 +02:00
Kamil Śliwak
703a73f949 EVMCodeTransformTest: Disable all non-stack optimizations 2021-07-01 16:54:09 +02:00
Alex Beregszaszi
cd60ade472 Improve some Yul object and command line tests to avoid using pop() which can be optimized out 2021-07-01 16:54:09 +02:00
hrkrshnn
b628b115ae Manually enabled gas statistics for erc20 token test. 2021-06-30 16:35:53 +02:00
chriseth
13d1fc9f41
Merge pull request #11579 from ethereum/better-errors-about-bad-paths-in-tests-with-external-sources
Better errors about bad paths in tests with external sources
2021-06-30 11:56:47 +02:00
chriseth
54b1c667f1
Merge pull request #11595 from ethereum/issue-11526
Fix yul codegen bug when using binary negation.
2021-06-30 11:55:42 +02:00
Mathias Baumann
c47d02066c Fix yul codegen bug when using binary negatition. 2021-06-29 17:41:03 +02:00
chriseth
eaac16c779
Merge pull request #11590 from ethereum/disallow-non-hex-zero-and-fix-bytes32-literals-in-bytes-concat
Disallow non-hex zero literals and fix 32-byte hex literals in `bytes.concat()`
2021-06-29 16:34:26 +02:00
Kamil Śliwak
6a50d088a0 Fix ICE for 32-byte hex literals and zero literals in bytes.concat() by disallowing them 2021-06-29 14:48:42 +02:00
Kamil Śliwak
fa3696878b Fix crash when passing empty strings to bytes.concat() 2021-06-29 13:52:01 +02:00
Daniel Kirchner
c341445f8e Maintain disambiguation when generating new functions in StackToMemoryMover. 2021-06-28 18:11:57 +02:00
Daniel Kirchner
bc288aacf5 Have the stack optimization in the code transform only reuse slots that are reachable and fix argument slot reuse on functions without return variables. 2021-06-28 18:11:57 +02:00
Daniel Kirchner
dfce7b667d Move function arguments and return values. 2021-06-28 18:11:57 +02:00
chriseth
22402accfe
Merge pull request #11578 from ethereum/soltest-clearer-error-message-for-std-exception
Clearer error message for `std::exception` in soltest
2021-06-28 16:13:21 +02:00
Kamil Śliwak
19fada966f Do not use \b, \v and \f escapes in string literals in generated Yul code 2021-06-28 14:13:47 +02:00
Kamil Śliwak
6ad6fa2382 Do not hard-code the default 'runs' value as 200 in code that fills out optimizer settings 2021-06-28 14:12:28 +02:00
Kamil Śliwak
ca0b1bf3f3 Fix crash when passing zero to bytes.concat() 2021-06-25 21:26:28 +02:00
Kamil Śliwak
e841479b4b TestCaseReader: Disallow UNC paths along with absolute ones 2021-06-25 18:41:21 +02:00
Kamil Śliwak
34425c351d Tests for readFileAsString() 2021-06-25 18:41:21 +02:00
Kamil Śliwak
8d5eaf400a Create FilesystemUtils with filesystem-related convenience helpers 2021-06-25 18:41:21 +02:00
Kamil Śliwak
65e23ff171 CommonIO: Make readFile() check if the file is not a directory and if not fail with a sensible exception rather than std::length_error 2021-06-25 16:04:58 +02:00
Kamil Śliwak
82b720029d boostTest: Print diagnostic information for std::exception too 2021-06-25 13:25:10 +02:00
Kamil Śliwak
030fb1d9a2 boostTest: Give BOOST_REQUIRE_NO_THROW a smaller block of code to make the error message clearer when a test raises an unexpected exception 2021-06-25 13:22:15 +02:00
Alexander Arlt
8accf420ea [yul] Functions: Remove dependency on AST ID. 2021-06-23 16:15:25 +02:00
chriseth
26598a2603
Merge pull request #11569 from ethereum/fixcalltounimplementedmodifier
Prevent calls to unimplemented modifiers.
2021-06-23 09:25:02 +02:00