Djordje Mijovic
e404b6e7a6
Refactoring yul source locations.
2021-05-04 16:05:23 +02:00
chriseth
5071709b25
Remove FunctionCall from ElementaryOperation.
2020-12-03 17:47:47 +01:00
Alex Beregszaszi
baa7251f1d
More clean up
2020-12-03 17:14:49 +01:00
Alex Beregszaszi
75e0057388
Rename parseElementaryOperation to parseLiteralOrIdentifier
2020-12-03 17:14:49 +01:00
Alex Beregszaszi
a22077f736
Rename AsmData -> AST
...
Also attempt to only include ASTForward where appropriate.
2020-11-25 17:58:02 +00:00
Alex Beregszaszi
24bb6252ac
Merge Parser::instructions() into EVMDialect
2020-07-29 13:15:54 +01:00
Sachin Grover
b7adb2aa42
Add SPDX license identifier if not present already in source file
...
Fixes : #9220
2020-07-17 20:24:12 +05:30
Alex Beregszaszi
65c50b14c8
Remove unused instructionNames() function in AsmParser
2020-07-06 16:48:28 +01:00
chriseth
eb923af09c
Do not set source locations for small internal assembly routines.
2020-05-27 18:26:46 +02: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
a3d4
7fecab07a8
Simplified Parser::createWithLocation().
...
In all but one case the function was called with the default argument value.
And when it was location, the location should be valid (see Parser::parseElementaryOperation()).
2020-02-06 03:34:48 +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
cameel
642653ea04
Make yul::Parser::parse() return unique_ptr rather than shared_ptr
...
- unique_ptr is more flexible and generally recommended for factory methods. It gets automatically converted to shared_ptr if necessary. Returning shared_ptr, on the other hand, forces the caller to use shared_ptr because a conversion to unique_ptr is not possible.
2020-01-29 20:07:08 +01:00
Christian Parpart
6b23412fae
C++ namespace cleanup (except tests).
2020-01-07 15:51:50 +01:00
chriseth
7db88cfedd
Remove yul::Instruction
.
2019-12-19 23:22:19 +01:00
Leonardo Alt
389da5228e
Merge remote-tracking branch 'origin/develop' into merge_develop_060
2019-11-20 12:27:40 +01:00
Leonardo Alt
be849b3c47
Replace boost::variant by std::variant in libyul
2019-11-19 17:23:18 +01:00
chriseth
ceb8ee9124
[Yul] leave statement.
2019-10-29 14:32:16 +01:00
chriseth
46d9df7574
Add EVM opcodes as builtins.
2019-05-20 16:46:31 +02:00
chriseth
4bdb981224
Make dialect const& and allocate single instances statically.
2019-05-17 12:54:24 +02:00
chriseth
570db164c9
Make Dialect const.
2019-05-16 21:51:54 +02:00
chriseth
b6bb3ae482
Merge pull request #6555 from sifmelcara/break-for-loop
...
[Yul] Disallow function definitions inside for loop init blocks
2019-04-25 11:20:44 +02:00
chriseth
0af8d758a5
Prevent instructions to be generated as names.
2019-04-24 14:35:21 +02:00
mingchuan
5d93c492fe
[Yul] More accurate error messages for break/continue
2019-04-23 10:15:19 +02:00
chriseth
2308904f68
Remove "using namespace" from header and move Instruction to dev::eth.
2019-03-28 13:48:11 +01:00
Christian Parpart
05e2d362c8
[Yul] Adds break/continue statements and some general tests for for-loop syntax.
2019-03-11 15:05:05 +01:00
chriseth
fb3a0ac1c7
Codegen for object access.
2018-12-11 19:24:44 +01:00
chriseth
99db4e3ff4
Introduce the concept of builtin functions.
2018-12-04 12:06:33 +01:00
chriseth
e5582ffea0
Use YulString also in expectAsmIdentifier.
2018-12-03 17:54:25 +01:00
Christian Parpart
c48a5264be
liblangutil: SourceLocation: adds (shared) pointer to underlying CharStream source, eliminating sourceName
...
Also, adapted affecting code to those changes.
2018-11-30 17:07:12 +01:00
Christian Parpart
ec47c8946b
Isolating libyul library API into its own namespace yul
.
2018-11-23 14:29:00 +01:00
Christian Parpart
0f4ed52a71
Rewrite header paths to adapt to recent git mv
of libsolidity/inlineasm to libyul
2018-11-23 11:18:57 +01:00
Christian Parpart
10e6d2897d
Moving files from libsolidity/inlineasm/*.{cpp,h} to libyul/.
2018-11-23 11:16:52 +01:00