Commit Graph
867 Commits
Author SHA1 Message Date
Daniel Kirchner 3af43fd350 Extract typing. 2020-04-14 10:59:28 +02:00
chriseth 748afe0edd Merge pull request #8630 from ethereum/encoding-bug-functionCallOption
TypeChecker error when encoding functions with call options; tests
2020-04-08 16:33:24 +02:00
chriseth baefab78d8 Merge pull request #8628 from ethereum/fiximmutableastexport
Export immutability.
2020-04-07 18:37:09 +02:00
hrkrshnn 229587672f TypeChecker error when encoding functions with call options; tests 2020-04-07 21:11:46 +05:30
chriseth 236eff8416 Export immutability. 2020-04-07 17:30:54 +02:00
chriseth 823a119117 Merge pull request #8570 from aarlt/clang-tidy-apply-modernize-use-emplace
clang-tidy: Apply modernize-use-emplace.
2020-04-07 17:28:50 +02:00
chriseth 398c515982 Merge pull request #8618 from mijovic/nextConstructorRefactor
Refactoring nextConstructor by moving it from CompilerContext to ContractDefinition
2020-04-06 19:31:12 +02:00
Djordje Mijovic 8cc16eb128 Refactoring nextConstructor by moving it from CompilerContext to ContractDefinition 2020-04-06 17:35:08 +02:00
chriseth f7aba45457 Merge pull request #8592 from random-internet-cat/ast-visitor-constructor
Delete copy and move operations for ASTVisitor and ASTConstVisitor
2020-04-06 14:16:20 +02:00
Jason Cobb 205063f86b Delete copy and move operations for ASTVisitor and ASTConstVisitor 2020-04-03 23:47:10 -04:00
Jason Cobb 7f5857a146 Delete copy/move on annotation polymorphic bases 2020-04-02 22:33:21 -04:00
Alexander Arlt 90bb1d8a7c Apply modernize-use-emplace. 2020-04-02 17:35:48 -05:00
Leonardo Alt 39ff0deb05 Zero initialize memory arrays 2020-04-02 15:55:18 +02:00
Mathias Baumann ac7b31e559 Validate immutable variables 2020-04-02 13:52:27 +02:00
Mathias Baumann 9a8ca6ca33 Always return this for EventDefinition::resolveVirtual
Instead of asserting.
2020-04-02 13:52:27 +02:00
chriseth 173f234860 Refactor: Replace inheritance hierarchy by most derived contract. 2020-03-26 18:27:39 +01:00
Daniel Kirchner 04d8ad2ae1 Legacy codegeneration for immutable state variables. 2020-03-24 16:45:25 +01:00
Daniel Kirchner fe659ceb41 Anything outside storage is always a pointer. 2020-03-23 15:34:10 +01:00
chriseth fa148f2483 Parsing of immutable state variable. 2020-03-12 17:11:24 +01:00
a3d4 a86c511713 Replaced "assert" with "if" (incorrect contract code is not supposed to trigger asserts). 2020-03-12 14:03:27 +01:00
chriseth 92d4bbb017 Salt should be bytes32. 2020-03-10 22:38:11 +01:00
chriseth a328e940b5 Merge pull request #8429 from ethereum/astJsonImportYulBlock
Fix yul ast import for blocks, switches and string literals.
2020-03-08 17:06:05 +01:00
Daniel Kirchner e58a1de57f Merge pull request #8431 from mijovic/sol2YulSelectorAddress
Adding sol->yul for f.selector and f.address
2020-03-06 22:48:38 +01:00
Djordje Mijovic 092827b7ad Adding sol->yul for f.selector and f.address 2020-03-06 21:43:14 +01:00
Daniel Kirchner 2df5ca0774 Merge pull request #8385 from ethereum/immutable
Immutable state variables (1)
2020-03-06 14:20:13 +01:00
Daniel Kirchner 7f38cbb91d Fix calling unimplemented base function. 2020-03-06 10:51:16 +01:00
Daniel Kirchner 420f57aec3 Fix yul ast import for blocks, switches and string literals. 2020-03-05 14:09:13 +01:00
chriseth 1488a1ceb8 Refactor isConstant to add "immutable". 2020-03-02 14:20:17 +01:00
Jason Cobb 6db0d50094 Don't use identifiers starting with an underscore followed by an uppercase letter 2020-02-17 12:44:39 -05:00
Daniel Kirchner 3c9f18b749 Use IRVariable's in IR code generation and implement tuples. 2020-02-12 12:36:14 +01:00
Daniel Kirchner 6abe0a50b1 Define stack slot names in types. 2020-02-12 12:36:14 +01:00
Erik Kundt f2701db0aa Adds documentation for Solidity source upgrader. 2020-02-05 16:52:54 +01:00
chriseth 7cca036f4c Merge pull request #8224 from a3d4/refactor-sourcelocation
Replaced SourceLocation::isEmpty() with isValid() and hasText().
2020-02-04 22:23:51 +01:00
alex 3416c029cf Relaxed assert in AsmJsonImporter::createAsmNode. 2020-02-04 20:37:51 +01:00
Daniel Kirchner d3cbfb0c5c Allow user-defined types as mapping keys in parser and restrict to contracts during type checking. 2020-02-04 17:22:03 +01:00
alex 211227f50b Modified SourceLocation::hasText() to allow empty source. 2020-02-04 04:19:28 +01:00
alex e4b18e85e6 Replaced SourceLocation::isEmpty() with isValid() and hasText().
The function SourceLocation::isEmpty() had somewhat dual role.
Sometimes it indicates that the SourceLocation is invalid.
Sometimes it means that there is no corresponding source text.

Hence the proposal is to replace it with two functions, isValid() and hasText().

I also removed Scanner::sourceAt(). (Do we have a rule of thumb to remove unused code?)

Since hasText() checks that start and end are valid indices for source, I adjusted a couple of tests to avoid empty source strings.
2020-02-03 08:04:21 +01:00
Erik Kundt 4a179056ed Adds JSON import / export for structured documentation. 2020-01-30 18:26:01 +01:00
Erik Kundt ec27c2e507 Introduce AST node for structured documentation. 2020-01-30 18:25:56 +01:00
Erik Kundt 893fb4d05b Implements AST JSON import for function call options. 2020-01-23 21:20:01 +01:00
Mathias Baumann a3f23d3158 Implement new with CREATE2 and function call options. 2020-01-23 21:20:01 +01:00
Daniel Kirchner ee5ff4df4e Clean up visibility via contract name and fix ICE on calling unimplemented base function. 2020-01-16 19:13:04 +01:00
chriseth c017072bac Merge pull request #8013 from ethereum/warnings
Enable more warnings in the build system
2020-01-15 18:00:14 +01:00
Daniel Kirchner c450b18673 Remove remaining instances of new. 2020-01-15 17:25:08 +01:00
Alex Beregszaszi eafcb42be7 Enable more compiler warnings in the build system
"-pedantic -Wno-unknown-pragmas -Wimplicit-fallthrough"
2020-01-15 14:33:27 +00:00
djudjuu e8556fa1b2 Ast-Import from standard-json 2020-01-14 17:15:53 +01:00
Mathias Baumann adc4774d4a ASTJSON: Export evm version 2020-01-14 12:51:21 +01:00
chriseth a4e34b378a Merge pull request #8105 from ethereum/functionTypeRefactor
Add a new Function Type referring to FunctionDefinition's without calling context and use it to allow selector lookup.
2020-01-09 17:15:46 +01:00
Daniel Kirchner 9535c0f520 Introduce FunctionKind::Declaration and allow accessing function signatures via contract name. 2020-01-09 15:40:41 +01:00
Jason Cobb 3726f7448e Remove now-unused abstractAnnotation helper 2020-01-09 08:44:24 -05:00