33 Commits
Author SHA1 Message Date
Christian Parpart d67322a186 Introduce namespace langutil in liblangutil directory.
Also:
- Use {}-style list initialisation for SourceLocation construction
- Introduce new system includes
- Changes the API of the Scanner to take source as value (with move) as opposed to as a reference
2018-11-21 19:13:44 +00:00
Christian Parpart 87821c53c3 Isolating files shared between Yul- and Solidity language frontend. 2018-11-21 18:58:12 +00:00
Erik Kundt 75a92b0ffd Warns if modifier uses msg.value in non-payable function. 2018-09-03 18:35:57 +02:00
Erik Kundt b5ecfbe5bc Enforces visibility specifier and updates docs. 2018-07-17 17:44:51 +02:00
Leonardo Alt 8202d512e0 Enforcing error on msg.gas and block.blockhash() 2018-07-04 11:42:05 +02:00
Daniel Kirchner 9aefe2f118 Remove trailing whitespace in missing visibility warning. 2018-07-02 13:14:58 +02:00
Alex Beregszaszi a17059573f Disallow raw callcode (was deprecated in 0.4.12) 2018-06-19 19:31:07 +02:00
Daniel Kirchner be37e3a912 Stricter check for member access to "this" in constructor. 2018-04-13 15:57:13 +02:00
Daniel Kirchner daa69df447 Error on invalid arithmetic with constant expressions. 2018-04-11 21:17:10 +02:00
Daniel Kirchner b2753aa053 Static Analyzer: Fix non-deterministic order of unused variable warnings. 2018-04-06 18:10:26 +02:00
Erik Kundt f9efa41749 Makes visibility warning more concise. 2018-04-03 11:16:50 +02:00
bitshift 8fe1cfb12e Defaults to external visibility for interfaces. 2018-04-03 11:16:44 +02:00
bitshift 2c56e53046 Changes deprecation and adjusts tests. 2018-03-27 03:30:03 +01:00
Daniel Kirchner 91b13b734d Use StaticAnalyzer to deprecate msg.gas instead of conditionally removing it in MagicType. 2018-03-05 23:16:26 +01:00
Alex Beregszaszi 10677125ae Turn usage of callcode into an error as experimental 0.5.0 feature 2017-10-19 02:20:30 +01:00
chriseth 3f3bcc4f8a Merge pull request #2848 from ethereum/checkViewPure
Enforce view and pure.
2017-09-13 18:29:13 +02:00
Suman 10d290cb9b Display helpful warning for unused function arguments/return parameters 2017-09-12 15:35:03 +01:00
chriseth eacee5b25c Remove previous warning about pureness not being enforced. 2017-09-06 13:50:49 +02:00
Alex Beregszaszi 5668377c72 Introduce pure specifier on functions 2017-08-24 13:46:18 +01:00
chriseth da3ac86403 Warn about large storage structures. 2017-08-11 20:57:57 +02:00
Rhett Aultman a2a759f792 Migrate over to ErrorReporter 2017-07-19 07:19:21 -07:00
Alex Beregszaszi b3db1c361c Warn if this is used in constructor 2017-07-19 06:47:36 -07:00
chriseth 044058276e Warn about callcode. 2017-06-30 16:37:32 +02:00
Rhett Aultman 89b60ffbd4 Refactor error reporting
This commit introduces ErrorReporter, a utility class which consolidates
all of the error logging functionality into a common set of functions.
It also replaces all direct interactions with an ErrorList with calls to
an ErrorReporter.

This commit resolves issue #2209
2017-05-30 07:28:31 -07:00
Rhett Aultman f735207732 Drop the inline asm includes from StaticAnalyzer 2017-05-23 06:38:17 -07:00
Rhett Aultman 621c3fa22f Analyze InlineAssembly for variable use
The unused variable checker in StaticAnalyzer did not conssider
InlineAssembly objects.  This commit introduces that missing feature.
2017-05-21 15:23:05 -07:00
chriseth 230f51efb7 Cleanup, style and additional test. 2017-05-03 11:26:21 +02:00
chriseth e0266b79f3 Refactor: Combine bool and function pointer. 2017-05-03 11:26:21 +02:00
Rhett Aultman a6faa5acf3 Treat returns with expressions as return param use
There are many cases of code where the return parameters exist mostly
as a form of documentation.  This change ensures that they do not have
to be used in the function body so long as there is a return supplying
values
2017-05-03 11:26:21 +02:00
Rhett Aultman a40c8cfb68 Warn on unused local variables
Analyze functions for all local variables, parameters, and named
return variables which are never used in the function, and issue
a warning.
2017-05-03 11:26:21 +02:00
chriseth 937695bfdc Change error message. 2017-04-21 15:04:03 +02:00
chriseth 9bc9fe6af7 Warn about side-effect free statements. 2017-04-21 11:36:38 +02:00
Federico Bond 05139500fb Warn about using msg.value in non-payable function 2016-12-08 16:22:13 -03:00