Commit Graph
100 Commits
Author SHA1 Message Date
Kamil Śliwak 29c8f282e4 Merge pull request #11419 from ethereum/sc-inline
Properly support inliner in settings.optimizer.details
2021-05-21 17:51:39 +02:00
Kamil Śliwak 4a2080b3aa TemporaryDirectory: Use boost::filesystem::equivalent() instead of == in path comparisons 2021-05-20 00:07:42 +02:00
Kamil Śliwak 828b15b34f Implement TemporaryWorkingDirectory test helper 2021-05-20 00:07:42 +02:00
Kamil Śliwak d85cc6c06a Fix dangling reference produced by temporary passed to TestFileParser going out of scope
- This fixes the `stack-use-after-scope` error reported by asan.
2021-05-19 23:27:41 +02:00
Kamil Śliwak 752483b92f Minor style tweaks in test TestFileParser (names and wrapping) 2021-05-19 23:27:41 +02:00
Kamil Śliwak cdebbb0dbb TemporaryDirectory: Expose boost::filesystem::path in class interface 2021-05-12 18:08:17 +02:00
Kamil Śliwak 5619702d31 Extract TemporaryDirectory test helper from yulPhaser's tests into a more general location 2021-05-12 17:16:29 +02:00
Kamil Śliwak 563160e5b3 Hard-code archlinux image version to base-20210131.0.14634 to work around runc/glibc bug 2021-04-29 19:16:09 +02:00
Kamil Śliwak 09283a6db4 Switch from archlinux/base to archlinux:base in CI
- archlinux/base seems to be gone
- archlinux:base comes from a different repo but seems to also be an official Arch Linux image
2021-04-29 18:29:21 +02:00
Kamil Śliwak 43de99dee5 Use 'optimizationPreset: none' for objectCompiler tests that rely on things that could get optimized out 2021-04-27 14:07:04 +02:00
Kamil Śliwak a51d72fb89 ObjectCompilerTest: Replace 'optimize' setting with 'optimizationPreset' 2021-04-27 14:06:56 +02:00
Kamil Śliwak 9c6f8c011f TestCaseReader: Add enumSetting() 2021-04-27 14:06:56 +02:00
Kamil Śliwak 5023cef382 OptimiserSettings: Add preset() and OptimisationPreset enum 2021-04-27 14:06:44 +02:00
Kamil Śliwak 28b9d27fae SoltestErrors: Qualify runtime_error with std:: to make it possible to use in in headers 2021-04-27 13:43:07 +02:00
Kamil Śliwak 173a511809 Merge pull request #11303 from ethereum/noncopyable
Remove the usage of boost::noncopyable
2021-04-23 22:38:49 +02:00
Kamil Śliwak 9439ff8b02 Merge pull request #11301 from ra-phael/docs-clarify-init-value
[Docs] Clarify initialisation value of state variables
2021-04-23 22:37:59 +02:00
Kamil Śliwak f479aceb4c 0.7.0 breaking changes: There were no external constructors 2021-04-22 21:57:20 +02:00
Kamil Śliwak 0d4871ad10 Prevent adding '-' CLI flag to allowed paths as if it was an actual file
- This resulted in a bug where using stdin was effectively disabling allowed path checks.
2021-04-19 16:58:48 +02:00
Kamil Śliwak 2abd3073d4 Merge pull request #11235 from ethereum/cmdline-tests-for-stdin
Allow using stdin in cmdlineTests
2021-04-19 16:21:43 +02:00
Kamil Śliwak e76ef821a7 osx_install_dependencies.sh: Update brew explicitly to workaround auto-update issue on CircleCI
- Old versions have problems with binaries hosted on bintray. We need an up-to-date one.
- It automatically updates itself when we install boost but apparently there's a problem with that on CircleCI. An explicit update works.
2021-04-19 16:08:50 +02:00
Kamil Śliwak 1c556d0aaa osx_install_dependencies.sh: Use set -ue to fail fast on errors 2021-04-19 16:06:49 +02:00
Kamil Śliwak 30cda36d9a Create a bundle with all bytecode reports when comparison fails in CI 2021-04-15 17:14:33 +02:00
Kamil Śliwak f14a80cbcf Don't print full diff when bytecode comparison fails in CI 2021-04-15 17:14:33 +02:00
Kamil Śliwak 7b467a49d7 Disable assertion that gives non-deterministic results in in slice tests for SMTChecker 2021-04-15 17:14:21 +02:00
Kamil Śliwak 59ef75cf5a cmdlineTests: Allow providing content of the standard input when not testing via Standard JSON 2021-04-13 13:37:12 +02:00
Kamil Śliwak 4e4f46cde5 cmdlineTests: Allow tests with no input file 2021-04-13 13:37:12 +02:00
Kamil Śliwak cc65b426d0 Merge pull request #11237 from ethereum/fix-wrong-exit-code-update-in-cmdline-tests
Fix exit code update in cmdlineTests
2021-04-13 13:34:57 +02:00
Kamil Śliwak 0922d60ba6 FileReader: More accurate description of FileReader::readFile() and its arguments 2021-04-13 13:26:01 +02:00
Kamil Śliwak 6a41b417a3 FileReader: Store files loaded by the callback under their source unit name 2021-04-13 13:25:59 +02:00
Kamil Śliwak b9b483a0c3 cmdlineTests.sh: Make regex for stripping version from test output match even if there's no whitespace after colon 2021-04-13 13:25:32 +02:00
Kamil Śliwak 7d37e37d95 cmdlineTests.sh: Fix error code update using the wrong value 2021-04-10 22:58:49 +02:00
Kamil Śliwak b85ace0c30 Merge pull request #10972 from ethereum/docs_seo
[DOCS] Create robots.txt / Avoid search results showing docs of old Solidity versions
2021-04-06 15:57:32 +02:00
Kamil Śliwak 879f1b3e26 docs: Mention that low-level calls do not have an extcodesize check 2021-03-30 18:10:00 +02:00
Kamil Śliwak 8c6bbf607f docs: Explain that public library functions cannot be called internally from the outside 2021-03-30 18:10:00 +02:00
Kamil Śliwak e1464fa4fb docs: Clarify how modifiers can affect function arguments and return values 2021-03-30 18:10:00 +02:00
Kamil Śliwak 67dea6c4f1 docs: Clarify which functions can be assigned to function variables 2021-03-30 14:31:51 +02:00
Kamil Śliwak 36f769662b docs: Add selector to the index 2021-03-30 14:31:51 +02:00
Kamil Śliwak 4053805356 docs: Yul create() and create2() return zero address on failure 2021-03-30 14:31:51 +02:00
Kamil Śliwak 797554668c docs: Newly allocated arrays are initialized with default values 2021-03-30 14:31:51 +02:00
Kamil Śliwak 259bf3f23a docs: The default visibility level for state variables is internal 2021-03-30 14:31:51 +02:00
Kamil Śliwak 60090fb4a9 docs: Calldata arguments are no longer limited to external functions 2021-03-30 14:31:51 +02:00
Kamil Śliwak 93bfc76216 docs: Mention explicitly that bitwise operators do not perform overflow/underflow checks 2021-03-30 14:31:51 +02:00
Kamil Śliwak 03a0998b5b solc-bin: Validate version reported by the compiler in the bytecode PR check 2021-03-29 20:17:45 +02:00
Kamil Śliwak d68d4727eb Fix bytecode PR check ignoring TOP_REF and always using HEAD as the end of the commit range 2021-03-29 17:48:49 +02:00
Kamil Śliwak d4e95a76e4 bytecode_reports_for_modified_binaries.sh: Add a helper for exiting with an error message 2021-03-29 17:48:38 +02:00
Kamil Śliwak c37bf89384 Merge pull request #11180 from ethereum/fix-trace-diff-fp
Fix false positive caused by early termination due to nested expressi…
2021-03-26 23:00:42 +01:00
Kamil Śliwak 855a806a5b Rewrite get_version.sh to make it work on macOS 2021-03-25 13:29:32 +01:00
Kamil Śliwak e7ac2fce81 Merge pull request #11108 from ethereum/remove-remains-of-shellcheck-ignore-list
Remove remains of shellcheck ignore list
2021-03-15 21:05:52 +01:00
Kamil Śliwak 14adb7df3b Really remove shellcheck ignore list 2021-03-15 20:02:42 +01:00
Kamil Śliwak 5376a3deb6 Merge pull request #10879 from ethereum/silence-remaining-shellcheck-warnings-and-remove-ignore-list
Silence remaining shellcheck warnings and remove ignore list
2021-03-15 19:58:42 +01:00
Kamil Śliwak b8979a939c Remove shellcheck ignore list 2021-03-15 12:16:43 +01:00
Kamil Śliwak 8e44b59251 Disable shellcheck in the remaining situations where it's either wrong or the problem is not worth fixing 2021-03-15 12:16:43 +01:00
Kamil Śliwak 008d648af3 Fix or disable find/ls related warnings 2021-03-15 12:16:43 +01:00
Kamil Śliwak 7929175db6 Add shellcheck source directive in places where it can't find sourced files on its own 2021-03-15 12:16:43 +01:00
Kamil Śliwak 978c25f1a4 Fix typos in isolate_tests.py 2021-03-10 20:42:46 +01:00
Kamil Śliwak 093ea4612b Merge pull request #10586 from ethereum/shellcheck-fixes-part1
Fixes for shellcheck warnings, part 1
2021-03-05 17:13:46 +01:00
Kamil Śliwak cf94c3f7df Remove scripts that now have no warnings from shellcheck ignore list 2021-03-04 16:57:25 +01:00
Kamil Śliwak c8fc241be5 Avoid using $? in conditions and do && exit 1 instead if ! 2021-03-04 16:57:25 +01:00
Kamil Śliwak 87f9eba1cf docs_version_pragma_check.sh: Set SOLC only for the duration of compileFull
- This is a global variable and would be better to just make it a parameter. At least this makes shellcheck shut up
2021-03-04 16:57:25 +01:00
Kamil Śliwak e8a70e8e4b Prefix globs with ./ or use -- to make commands safe with files named like command-line options 2021-03-04 16:57:25 +01:00
Kamil Śliwak 04302d4828 Use glob match instead of regex match when not actually using a regex 2021-03-04 16:57:25 +01:00
Kamil Śliwak 7d845c0289 Don't use globs in command names 2021-03-04 16:57:25 +01:00
Kamil Śliwak 62bf467fc2 Fix warnings about constructions that have no effect 2021-03-04 16:53:05 +01:00
Kamil Śliwak 4e3ebda0f4 Don't use negative exit codes 2021-03-04 16:53:05 +01:00
Kamil Śliwak dbfd3db038 Use mapfile instead of () for reading multiple lines as separate array items 2021-03-04 16:53:05 +01:00
Kamil Śliwak a05f3a608d Don't use $ on variables inside (()) 2021-03-04 16:53:05 +01:00
Kamil Śliwak 2784135c37 Use read with the -r option 2021-03-04 16:53:05 +01:00
Kamil Śliwak d14c4288ec Make scripts fail on non-zero return codes and undefined variables where possible 2021-03-04 16:53:05 +01:00
Kamil Śliwak 75b87d159d Declare variables separately when assigning the result of $() 2021-03-04 16:53:05 +01:00
Kamil Śliwak 1c7cc376d1 Use "$@" instead of $* 2021-03-04 16:53:05 +01:00
Kamil Śliwak 4c186321c8 Replace some older shell syntax with newer and/or more reliable equivalents 2021-03-04 16:53:05 +01:00
Kamil Śliwak 8c57c7cb35 Explicitly use Bash in scripts that actually use non-POSIX features or do not have a shebang at all 2021-03-04 16:53:05 +01:00
Kamil Śliwak 186d14d97f FunctionCallGraph: Tests for constants, immutables and accessing function selectors 2021-02-25 16:00:53 +01:00
Kamil Śliwak e87cd0afdf Check that there is an interface type before querying validity of location. 2021-02-24 11:22:40 +01:00
Kamil Śliwak cf2847afc4 Remove duplicate syntax tests for functions taking internal struct types 2021-02-23 16:46:49 +01:00
Kamil Śliwak fc7a091bfb Move several tests related to function types from nameAndTypeResolution/ to more specific directories 2021-02-23 16:46:49 +01:00
Kamil Śliwak f58b64800f Fix 'switch' style in FunctionCallGraph 2021-02-23 14:02:35 +01:00
Kamil Śliwak 7a85516b82 Remove contract reference from the call graph 2021-02-23 14:01:20 +01:00
Kamil Śliwak 01f8005d04 Remove the last remains of --ast-json option 2021-02-23 12:39:19 +01:00
Kamil Śliwak 781f00771c Remove IRGenerator::verifyCallGraphs and make generate() verify the graphs automatically 2021-02-23 10:47:02 +01:00
Kamil Śliwak 54eb34d6fd Move call graphs from CompilerStack to ContractDefinitionAnnotation 2021-02-23 10:47:02 +01:00
Kamil Śliwak 6c28120f19 Move CallGraph structure to a separate module 2021-02-23 10:47:02 +01:00
Kamil Śliwak 769a7687c6 Make CompilerStack::contractDefinition() public 2021-02-23 10:47:02 +01:00
Kamil Śliwak 051995a373 Test suite for FunctionCallGraph 2021-02-23 10:46:28 +01:00
Kamil Śliwak 74ef7dd790 FunctionCallGraph: operator<< for printing nodes in an unambiguous way 2021-02-23 10:46:28 +01:00
Kamil Śliwak 529495c530 CompilerStack: Typo in a comment 2021-02-23 10:29:12 +01:00
Kamil Śliwak e27afe93a9 CompilerStack: Fix style on local variable name 2021-02-23 10:29:12 +01:00
Kamil Śliwak 13a9d21d88 FunctionType: Add assertions against missing type annotations
- This should make it easier to realize that one of the analysis phases has not been executed.
2021-02-23 10:29:12 +01:00
Kamil Śliwak 9d762f381f Merge pull request #10932 from ssi91/add-sha256-field-to-the-docs
add sha256 field ot the docs
2021-02-15 17:48:02 +01:00
Kamil Śliwak 887f27fbbf Merge pull request #10897 from DragonDev1906/patch-1
Fix formatting in "Implicit Conversions"
2021-02-04 02:41:47 +01:00
Kamil Śliwak 800c338534 Scripts for generating and comparing bytecode reports for solc-bin binaries 2021-02-03 19:15:52 +01:00
Kamil Śliwak 67fe5fb145 prepare_report.py: Print some statistics about contracts and errors 2021-02-02 16:16:28 +01:00
Kamil Śliwak 4576b1ec89 prepare_report.py: --exit-on-error option 2021-02-02 16:16:28 +01:00
Kamil Śliwak acaab18a0a prepare_report.py: More information on stdout, with verbosity control 2021-02-02 16:16:28 +01:00
Kamil Śliwak 96fd9051ed prepare_report.py: Add --report-file option 2021-02-02 16:16:28 +01:00
Kamil Śliwak 7bebcb7871 prepare_report.js: Print ERROR in case of an exception during compilation instead of failing
- Our v0.4.11 release raises an exception on some LLL snippets containing returnlll (extracted from its end-to-end tests).
- The report comparison will fail anyway because emscripten prints an abort code to stdout in that case but at least we'll be able to continue if we're comparing multiple versions.
2021-02-02 16:16:14 +01:00
Kamil Śliwak 17fe96c4d0 prepare_report.py: Don't use --metadata option with compiler versions that do not support it
- Before 0.4.3 the option was unavailable but ignored.
- Between 0.4.3 and 0.4.6 an attempt to use that option causes an error.
2021-02-02 16:16:14 +01:00
Kamil Śliwak 49aede680b prepare_report.py: Add --force-no-optimize-yul flag to work around a bug in solc 0.6.0/0.6.1 2021-02-02 16:16:14 +01:00
Kamil Śliwak 7e48aeb848 prepare_report.py: Make parsing more lax to handle output from older compiler versions 2021-02-02 16:16:14 +01:00
Kamil Śliwak b06de9a2d5 prepare_report: Add command-line options for switching between SMT pragma stripping and only disabling the SMT checker 2021-02-02 16:16:14 +01:00