Commit Graph

23392 Commits

Author SHA1 Message Date
chriseth
07750ea23a More aggressive runtime code exclusion. 2023-02-15 21:33:06 +01:00
Kamil Śliwak
e147654f92
Merge pull request #13971 from ethereum/improve-error-reporting-for-wrong-constructor-arguments
Improve error messages for wrong constructor arguments
2023-02-15 20:39:59 +01:00
Kamil Śliwak
8e652c3aff
Merge pull request #13976 from ethereum/openzeppelin-governor-clock-bug
Skipping flaky openzeppelin tests
2023-02-15 20:30:20 +01:00
Rodrigo Q. Saramago
ceaa7b53da
Skipping flaky openzeppelin tests 2023-02-15 18:54:15 +01:00
Kamil Śliwak
1a981af548 Only suggest removing parentheses from a construction call if they're empty 2023-02-15 14:27:03 +01:00
Kamil Śliwak
73183d3df9 Fix missing base constructor arguments being treated as an unimplemented function 2023-02-15 14:27:03 +01:00
Kamil Śliwak
bc3cbfa18d Add more tests tests for calls to base constructor with missing or wrong arguments 2023-02-15 14:17:55 +01:00
Kamil Śliwak
16bc4c6b5f Fix test for replacing base constructor 2023-02-15 14:17:55 +01:00
Kamil Śliwak
1b0f7af707
Merge pull request #13926 from ethereum/release-checklist-tweaks-and-clarifications
Release checklist tweaks and clarifications
2023-02-14 22:10:51 +01:00
Kamil Śliwak
0aefd15576 ReleaseChecklist: Add more detail to the PPA steps 2023-02-14 14:43:32 +01:00
Kamil Śliwak
0384506e55 ReleaseChecklist: Pre-flight checks and drafts to be prepared before the release 2023-02-14 14:43:32 +01:00
Kamil Śliwak
89c4ee6942 Add a script for generating a list of contributors to paste in release notes 2023-02-14 14:39:55 +01:00
Kamil Śliwak
8b7879c7da ReleaseChecklist: static-z3.sh is actually called static_z3.sh 2023-02-14 14:39:55 +01:00
Kamil Śliwak
7585cd9507 ReleaseChecklist: List packages needed to update the PPA as prerequisites 2023-02-14 14:39:55 +01:00
Daniel
7cd589eee4
Merge pull request #13961 from ethereum/fix-external-test-gp2
gp2 external test workaround
2023-02-13 21:36:36 +01:00
chriseth
91b14174d8
Merge pull request #13702 from ethereum/new_knowledge_engine
Re-implement KnowledgeBase using groups of constantly-spaced variables.
2023-02-13 20:05:47 +01:00
r0qs
e50d56517b
Merge pull request #13947 from ethereum/update-stale-issues
Update stale issues action
2023-02-11 20:26:22 +01:00
Rodrigo Q. Saramago
a5166f0a19
gp2 external test workaround 2023-02-11 17:16:03 +01:00
Rodrigo Q. Saramago
627bbe2ea3
Update stale issues policies 2023-02-11 11:24:14 +01:00
chriseth
29e4becd73 Introduce helpers for VariableOffset. 2023-02-09 16:44:36 +01:00
Leo
59f9ab4dee
Merge pull request #13939 from pgebal/fix_handling_bitwise_operators_when_parsing_z3_call_result
Fixes handling bitwise operators for z3 model checker
2023-02-09 12:16:28 +01:00
chriseth
3ac6edec5b Apply suggestions from code review 2023-02-09 10:47:12 +01:00
chriseth
695b250557 Update gas costs. 2023-02-09 10:47:12 +01:00
chriseth
eec258c2d2 Bugfix. 2023-02-09 10:47:12 +01:00
chriseth
6bbef64034 Optimize in case this is SSA. 2023-02-09 10:47:12 +01:00
chriseth
96e2a6d3fe Keep one instance of KnowledgeBase for UnusedStoreEliminator. 2023-02-09 10:47:12 +01:00
chriseth
47aa1c65ae Re-implement KnowledgeBase using groups of constantly-spaced variables. 2023-02-09 10:47:11 +01:00
Daniel
d33f2734b6
Merge pull request #13952 from ethereum/fix-abstract-nondet
fix abstract nondet exception
2023-02-08 19:39:19 +01:00
Daniel
7b35f44622
Merge pull request #13953 from lemenkov/gcc_12_strings_recognition
Type recognition workaround for some GCC compilers
2023-02-08 19:36:02 +01:00
Pawel Gebal
a38549dc19 Fixes handling bitwise operators for z3 model checker 2023-02-08 18:37:17 +01:00
Peter Lemenkov
603f9f7208 Type recognition workaround for some GCC compilers
Looks like somewhat old GCC compilers, namely 12.2.1, cannot recognize a
string literal sometimes. Let's help it to avoid error logs like this
one:

```
[ 75%] Building CXX object libsolidity/CMakeFiles/solidity.dir/codegen/ir/IRGeneratorForStatements.cpp.o
cd /builddir/build/BUILD/solidity-0.8.18/redhat-linux-build/libsolidity && /usr/bin/g++ -DBOOST_ATOMIC_DYN_LINK -DBOOST_ATOMIC_NO_LIB -DBOOST_FILESYSTEM_DYN_LINK -DBOOST_FILESYSTEM_NO_LIB -DBOOST_SYSTEM_DYN_LINK -DBOOST_SYSTEM_NO_LIB -DFMT_HEADER_ONLY=1 -DHAVE_CVC4 -DHAVE_Z3 -I/builddir/build/BUILD/solidity-0.8.18/redhat-linux-build/include -I/builddir/build/BUILD/solidity-0.8.18 -isystem /usr/include/z3 -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fuse-ld=gold -O3 -DNDEBUG -fstack-protector-strong -Wimplicit-fallthrough -fmacro-prefix-map=/builddir/build/BUILD/solidity-0.8.18=/solidity -Wpessimizing-move -Wredundant-move -Wall -Wextra -Werror -pedantic -Wmissing-declarations -Wno-unknown-pragmas -Wsign-conversion -Wconversion -Wextra-semi -Wduplicated-cond -Wlogical-op -fdiagnostics-color -std=c++17 -MD -MT libsolidity/CMakeFiles/solidity.dir/codegen/ir/IRGeneratorForStatements.cpp.o -MF CMakeFiles/solidity.dir/codegen/ir/IRGeneratorForStatements.cpp.o.d -o CMakeFiles/solidity.dir/codegen/ir/IRGeneratorForStatements.cpp.o -c /builddir/build/BUILD/solidity-0.8.18/libsolidity/codegen/ir/IRGeneratorForStatements.cpp
In file included from /usr/include/c++/12/string:40,
                 from /builddir/build/BUILD/solidity-0.8.18/libsolidity/ast/ASTForward.h:27,
                 from /builddir/build/BUILD/solidity-0.8.18/libsolidity/ast/AST.h:26,
                 from /builddir/build/BUILD/solidity-0.8.18/libsolidity/ast/ASTVisitor.h:26,
                 from /builddir/build/BUILD/solidity-0.8.18/libsolidity/codegen/ir/IRGeneratorForStatements.h:24,
                 from /builddir/build/BUILD/solidity-0.8.18/libsolidity/codegen/ir/IRGeneratorForStatements.cpp:22:
In function 'std::char_traits<char>::copy(char*, char const*, unsigned long)',
    inlined from 'std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >::_S_copy(char*, char const*, unsigned long)' at /usr/include/c++/12/bits/basic_string.h:423:21,
    inlined from 'std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >::_M_replace(unsigned long, unsigned long, char const*, unsigned long)' at /usr/include/c++/12/bits/basic_string.tcc:532:22,
    inlined from 'std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >::assign(char const*)' at /usr/include/c++/12/bits/basic_string.h:1647:19,
    inlined from 'std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >::operator=(char const*)' at /usr/include/c++/12/bits/basic_string.h:815:28,
    inlined from '(anonymous namespace)::CopyTranslate::translateReference(solidity::yul::Identifier const&)' at /builddir/build/BUILD/solidity-0.8.18/libsolidity/codegen/ir/IRGeneratorForStatements.cpp:182:13:
/usr/include/c++/12/bits/char_traits.h:431:56: error: 'memcpy' accessing 9223372036854775810 or more bytes at offsets -4611686018427387902 and [-4611686018427387903, 4611686018427387904] may overlap up to 9223372036854775813 bytes at offset -3 [-Werror=restrict]
  431 |         return static_cast<char_type*>(__builtin_memcpy(__s1, __s2, __n));
      |                                        ~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
cc1plus: all warnings being treated as errors
gmake[2]: *** [libsolidity/CMakeFiles/solidity.dir/build.make:695: libsolidity/CMakeFiles/solidity.dir/codegen/ir/IRGeneratorForStatements.cpp.o] Error 1
gmake[2]: *** Waiting for unfinished jobs....
gmake[2]: Leaving directory '/builddir/build/BUILD/solidity-0.8.18/redhat-linux-build'
gmake[1]: *** [CMakeFiles/Makefile2:414: libsolidity/CMakeFiles/solidity.dir/all] Error 2
gmake[1]: Leaving directory '/builddir/build/BUILD/solidity-0.8.18/redhat-linux-build'
gmake: *** [Makefile:139: all] Error 2
```

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>
2023-02-08 17:51:56 +01:00
Leo Alt
db9c11a2a5 fix abstract nondet exception 2023-02-08 16:59:37 +01:00
Daniel
665bf29a84
Merge pull request #12958 from ethereum/yul-fuzzer-bound-memory-accesses
Yul grammar generator: Bound memory accesses.
2023-02-07 15:47:20 +01:00
Daniel
048aabd3ca
Merge pull request #13934 from esaulpaugh/develop
specify "receive" as having no "name"
2023-02-07 15:40:52 +01:00
Daniel
82fdc6fccc
Merge pull request #13932 from lemenkov/redundant_std_move
libsolidity: Redundant std::move
2023-02-07 15:29:41 +01:00
matheusaaguiar
88e44ed5e2
Merge pull request #13941 from ethereum/cleanup-gnosis-test
Cleanup of duplicated line leftover from previous fix
2023-02-06 18:58:25 -03:00
Matheus Aguiar
a5c5e4602a Cleanup of duplicated line leftover from previous fix 2023-02-06 18:10:31 -03:00
Nikola Matić
e48d495fb7
Merge pull request #13940 from ethereum/fix-workaround-gnosis-test
Replace quote marks with quotation marks in workaround of gnosis.sh external test
2023-02-06 21:48:38 +01:00
Leo
7176925a87
Merge pull request #11559 from ethereum/smt_trusted
[SMTChecker] Trusted mode for external calls
2023-02-06 21:39:13 +01:00
Matheus Aguiar
98c011328a Replace quote marks with quotation marks 2023-02-06 16:53:23 -03:00
Nuno Santos
411841cbb5
Tweak wording in value type docs (#13935)
* Update value-types.rst

- User-defined were written inconsistently (with/without hyphen)
- Rewording some sentences for user clarity.

* Update docs/types/value-types.rst

Co-authored-by: chriseth <chris@ethereum.org>

---------

Co-authored-by: chriseth <chris@ethereum.org>
2023-02-06 17:19:48 +00:00
Leo Alt
8d91ccf028 [SMTChecker] Add a new trusted mode which assumes that code that is
available at compile time is trusted.
2023-02-06 17:02:33 +01:00
Evan Saulpaugh
821da895ea
specify "receive" as having no "name" 2023-02-05 16:13:23 -06:00
Peter Lemenkov
b3f35f703a libsolidity: Redundant std::move
This patch suppresses warnings like this one:

```
/builddir/build/BUILD/solidity-0.8.18/libsolidity/ast/AST.h: In constructor 'solidity::frontend::FunctionDefinition::FunctionDefinition(int64_t, const solidity::frontend::ASTNode::SourceLocation&, solidity::frontend::ASTPointer<std::__cxx11::basic_string<char> >&, const solidity::frontend::ASTNode::SourceLocation&, solidity::frontend::Visibility, solidity::frontend::StateMutability, bool, solidity::langutil::Token, bool, solidity::frontend::ASTPointer<solidity::frontend::OverrideSpecifier>&, solidity::frontend::ASTPointer<solidity::frontend::StructuredDocumentation>&, solidity::frontend::ASTPointer<solidity::frontend::ParameterList>&, std::vector<std::shared_ptr<solidity::frontend::ModifierInvocation> >, solidity::frontend::ASTPointer<solidity::frontend::ParameterList>&, solidity::frontend::ASTPointer<solidity::frontend::Block>&)':
/builddir/build/BUILD/solidity-0.8.18/libsolidity/ast/AST.h:926:69: error: redundant move in initialization [-Werror=redundant-move]
  926 |                 CallableDeclaration(_id, _location, _name, std::move(_nameLocation), _visibility, _parameters, _isVirtual, _overrides, _returnParameters),
      |                                                            ~~~~~~~~~^~~~~~~~~~~~~~~
/builddir/build/BUILD/solidity-0.8.18/libsolidity/ast/AST.h:926:69: note: remove 'std::move' call
```

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>
2023-02-05 12:06:19 +01:00
Kamil Śliwak
f2bf23a067
Merge pull request #13929 from jhheider/explicit-copy-init
Fixes minor compilation errors with some clangs
2023-02-05 01:48:08 +01:00
Kamil Śliwak
acc01dadfc
Merge pull request #13919 from lemenkov/explicit_include
libsolutil: Add missing include
2023-02-05 01:46:36 +01:00
Peter Lemenkov
6a6bf303b5 libsolutil: Add missing include
This one is more obscure. It helps suppressing the following error while
compiling:

```
/builddir/build/BUILD/solidity-0.8.18/liblangutil/EVMVersion.h:33:6: error: elaborated-type-specifier for a scoped enum must not use the 'class' keyword [-Werror]
   33 | enum class Instruction: uint8_t;
      | ~~~~ ^~~~~
      |      -----
/builddir/build/BUILD/solidity-0.8.18/liblangutil/EVMVersion.h:33:23: error: found ':' in nested-name-specifier, expected '::'
   33 | enum class Instruction: uint8_t;
      |                       ^
      |                       ::
/builddir/build/BUILD/solidity-0.8.18/liblangutil/EVMVersion.h:33:12: error: 'Instruction' has not been declared
   33 | enum class Instruction: uint8_t;
      |            ^~~~~~~~~~~
/builddir/build/BUILD/solidity-0.8.18/liblangutil/EVMVersion.h:101:24: error: 'solidity::evmasm::Instruction' has not been declared
  101 |         bool hasOpcode(evmasm::Instruction _opcode) const;
      |                        ^~~~~~
/builddir/build/BUILD/solidity-0.8.18/liblangutil/EVMVersion.cpp:29:6: error: no declaration matches 'bool solidity::langutil::EVMVersion::hasOpcode(solidity::evmasm::Instruction) const'
   29 | bool EVMVersion::hasOpcode(Instruction _opcode) const
      |      ^~~~~~~~~~
/builddir/build/BUILD/solidity-0.8.18/liblangutil/EVMVersion.h:101:14: note: candidate is: 'bool solidity::langutil::EVMVersion::hasOpcode(int) const'
  101 |         bool hasOpcode(evmasm::Instruction _opcode) const;
      |              ^~~~~~~~~
/builddir/build/BUILD/solidity-0.8.18/liblangutil/EVMVersion.h:43:7: note: 'class solidity::langutil::EVMVersion' defined here
   43 | class EVMVersion:
      |       ^~~~~~~~~~
cc1plus: all warnings being treated as errors
```

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>
2023-02-04 16:22:18 +01:00
Peter Lemenkov
8f1668ffb8 libsolutil: Add missing include
This helps suppressing the following message during compilation:

```
/builddir/build/BUILD/solidity-0.8.18/libsolutil/Common.h:55:27: error: 'uint8_t' was not declared in this scope
   55 | using bytes = std::vector<uint8_t>;
      |                           ^~~~~~~
/builddir/build/BUILD/solidity-0.8.18/libsolutil/Common.h:49:1: note: 'uint8_t' is defined in header '<cstdint>'; did you forget to '#include <cstdint>'?
   48 | #include <functional>
  +++ |+#include <cstdint>
   49 | #include <string>
```

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>
2023-02-04 16:22:18 +01:00
Jacob Heider
43431eb427
Fixes compilation errors with some clangs
resolves https://github.com/ethereum/solidity/issues/13854
2023-02-03 21:37:50 -05:00
Kamil Śliwak
77640a57c9
Merge pull request #13781 from janisozaur/patch-2
Update debian/compat to version 13
2023-02-03 22:28:20 +01:00