Commit Graph

3328 Commits

Author SHA1 Message Date
chriseth
bb09787bd0
Merge pull request #8378 from mijovic/yulSourceLocations
Adding source location support to AssemblyStack
2020-02-25 22:34:57 +01:00
Djordje Mijovic
ec083c4878 Adding source location support to AssemblyStack and thus debugging Yul sources 2020-02-25 22:19:03 +01:00
chriseth
c5a0a434e2
Merge pull request #8374 from ethereum/writeAccessToSlot
Allow access to ``_slot`` for local storage pointer variables.
2020-02-25 22:11:13 +01:00
chriseth
45041e5d3a Allow access to `_slot` for local storage pointer variables. 2020-02-25 14:28:04 +01:00
Djordje Mijovic
8524e3f48d Standard-JSON-Interface: Fix a bug (#8371) related to empty filenames and imports. 2020-02-25 01:07:36 +01:00
chriseth
c2e22d4cab
Merge pull request #8221 from ethereum/structured-docs-error-locations
[parser] Source locations for structured documentation errors
2020-02-18 14:57:28 +01:00
chriseth
663a9f892f
Merge pull request #8333 from ethereum/fix-8332
Use explicit variant constructor in direct list initializer
2020-02-18 14:46:31 +01:00
chriseth
64f9dc351e
Merge pull request #8337 from mijovic/assembly-multifile
Assembly: Added missing source field to legacy assembly json output
2020-02-18 12:47:19 +01:00
Djordje Mijovic
18dea6b69c Assembly: Added missing source field to legacy assembly json output to complete the source reference 2020-02-18 10:22:34 +01:00
Bhargava Shastry
786c63ec3c Use explicit type for variant constructor that is part of direct list initializer 2020-02-18 10:42:08 +05:30
Jason Cobb
6db0d50094
Don't use identifiers starting with an underscore followed by an uppercase letter 2020-02-17 12:44:39 -05:00
Erik Kundt
b43751d65e Reports source location for structured documentation errors. 2020-02-14 15:21:39 +01:00
chriseth
99f88742d6
Merge pull request #8263 from ethereum/functionSelectorPure
Mark function selectors accessed via declaration as pure.
2020-02-14 12:34:39 +01:00
Daniel Kirchner
9f094d59b9 Mark function selector accesses as pure for pure expressions and mark function accesses via contract name as pure. 2020-02-14 12:33:33 +01:00
Christian Parpart
c92fe69a60 Finishes external call implementation. 2020-02-14 11:59:04 +01:00
Leonardo Alt
3800391a1a [Yul] Support conditionals 2020-02-13 17:02:15 -04:00
Mathias L. Baumann
c635377450
Merge pull request #8313 from ethereum/checkFunctionsExistInIsoltest
Make type error fatal to prevent assert failure at later point
2020-02-13 16:08:13 +01:00
Mathias Baumann
8911b58a6d Make type error fatal to prevent assert failure at later point 2020-02-13 15:16:28 +01:00
Leonardo
2cadf7ec5a
Merge pull request #8307 from ethereum/smt_split_1
[SMTChecker] Some refactoring
2020-02-12 15:25:56 -03:00
chriseth
1ea66fd1f8
Merge pull request #8301 from ethereum/fixPostTypeChecker
PostTypeChecker: ConstStateVarCircularReferenceChecker on function type state variables.
2020-02-12 18:40:19 +01:00
Daniel Kirchner
45f80e9895 Move assertion in PostTypeChecker's ConstStateVarCircularReferenceChecker to account for function type variables 2020-02-12 17:42:27 +01:00
Alexander Arlt
d0eeca8014 Fix CompilerStack::loadMissingSources()
- FatalError Exception was not caught
- fixes #8102
2020-02-12 11:22:11 -05:00
Leonardo Alt
d31a2a8d21 CHC clears indices so that initial is 0 and current is 1 2020-02-12 11:47:58 -03:00
Leonardo Alt
34d64761d9 Extract symbolicArguments function 2020-02-12 11:47:58 -03:00
Leonardo Alt
6451a4d2a0 Move VerificationTarget and add BMCVerificationTarget 2020-02-12 11:47:58 -03:00
Leonardo Alt
ba576bc6c3 Fix new namespaces 2020-02-12 10:35:44 -03:00
Daniel Kirchner
df0873d138 Implement calldata arrays for Yul IR 2020-02-12 14:00:29 +01: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
Daniel Kirchner
e786650bef
Merge pull request #8274 from ethereum/structRecursionMapping
Move mapping key checks to ReferencesResolver and make errors fatal.
2020-02-12 11:19:07 +01:00
Mathias Baumann
80bd0f47cc Unify optimize yul code in CompilerContext/ContractCompiler 2020-02-11 13:55:47 +01:00
Mathias Baumann
1a3998648c Run yul optimizer on user code without refs 2020-02-11 13:55:47 +01:00
Daniel Kirchner
9c3151748e Move mapping key checks to ReferencesResolver and make them fatal. 2020-02-11 13:35:23 +01:00
chriseth
d033c2f767
Merge pull request #8178 from ethereum/internal_revert_strings
Internal reverts with reason in debug mode
2020-02-10 17:35:41 +01:00
Leonardo Alt
36928c7a35 Add reason string for internal reverts 2020-02-10 11:57:20 -03:00
a3d4
b3b8441aa4 Fix printing source for missing pragma. 2020-02-09 02:28:47 +01:00
chriseth
a41f5e91f6
Merge pull request #8251 from a3d4/refactor-currentlocation
Refactor currentlocation
2020-02-06 09:57:41 +01:00
Daniel Kirchner
e07274a96f Disallow libraries as mapping keys. 2020-02-06 09:09:43 +01:00
a3d4
4ec4d23886 Replaced ParserBase::position() and ParserBase::endPosition() with ParserBase::currentLocation().
It might be simpler to pass `SourceLocation` object instead of splitting it into `start` and `end`, and creating another SourceLocation object using the same `start` and `end` later.
2020-02-06 03:34:49 +01:00
Mathias L. Baumann
bd54176c1a
Merge pull request #8248 from ethereum/functionCallOptionFollowUp
Fix function call option parsing and add to grammar.
2020-02-05 18:01:54 +01:00
chriseth
5247a6600e Fix function call option parsing and add to grammar. 2020-02-05 16:59:02 +01:00
Erik Kundt
f2701db0aa Adds documentation for Solidity source upgrader. 2020-02-05 16:52:54 +01:00
chriseth
0b9c842656 Fix abstract without contract. 2020-02-05 12:14:14 +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
af9fc8b634 Mapping getters for Yul IR. 2020-02-04 17:22:03 +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
chriseth
2098dbade9
Merge pull request #7834 from ethereum/docstring-ast-node
[natspec] Introduce AST node for structured documentation
2020-01-30 19:04:52 +01:00