Commit Graph

398 Commits

Author SHA1 Message Date
LianaHus
da47f9df7b style fixes 2015-11-06 20:56:14 +01:00
LianaHus
63060fc1f0 fixed test framework 2015-11-06 18:45:06 +01:00
LianaHus
7eb162c0df fix 2015-11-06 18:45:06 +01:00
LianaHus
79177de80b fixed return valu for resolver 2015-11-06 18:45:06 +01:00
LianaHus
3f726825fb added SourceLocations to error reporting for ReferenceResolver 2015-11-06 18:45:06 +01:00
LianaHus
ff421a9d65 passed SourceLocations instead of nodes to the error reporting function 2015-11-06 18:45:06 +01:00
LianaHus
02d060ea5c fixed build 2015-11-06 18:45:06 +01:00
LianaHus
1a27bf8a39 added errors tu ReferencesResolver 2015-11-06 18:45:06 +01:00
chriseth
907cf28f49 Fix: Cope with non-existing commit hash. 2015-11-02 18:03:04 +01:00
chriseth
a5c227778d Bugfix: Returning literal strings in tuples. 2015-10-31 23:13:45 +01:00
chriseth
56f5d58850 Rename error type. 2015-10-27 17:45:58 +01:00
chriseth
a957322fd7 Preliminary why3 code output. 2015-10-27 00:49:27 +01:00
chriseth
8fb49d85f9 Allow docstrings for statements. 2015-10-26 19:47:25 +01:00
chriseth
af4d687062 Fix indent. 2015-10-26 17:21:32 +01:00
chriseth
b4f561680a Store docstrings in AST annotations. 2015-10-26 15:24:36 +01:00
chriseth
7a9f8d9f35 Merge pull request #171 from LianaHus/sol_change_expected_error_in_parser
Sol change "expected" errors in parser
2015-10-23 13:25:29 +02:00
LianaHus
d8865f9f05 more corrections 2015-10-23 12:56:50 +02:00
chriseth
e48ee59549 Fix override warning. 2015-10-23 12:51:49 +02:00
LianaHus
6e13853421 modified error msg 2015-10-23 12:44:26 +02:00
chriseth
e3dffb611f File reorganisation. 2015-10-21 00:46:01 +02:00
chriseth
87079bd3fd Correctly parse ambiguities like A.B[10] x and x.y[10] = 3. 2015-10-16 16:12:25 +02:00
chriseth
452d473293 Merge pull request #143 from chriseth/loneStructArray
Fix errors when struct array type is used on its own.
2015-10-16 15:20:44 +02:00
chriseth
102114176c Merge pull request #142 from chriseth/fixWarnings
Fix warning.
2015-10-16 15:20:36 +02:00
chriseth
fd8eb2d074 Merge pull request #141 from chriseth/fixExternalTypes
Do not include function in interface list if there are errors.
2015-10-16 15:20:25 +02:00
chriseth
7b56206a98 Do not catch InternalCompilerErrors as part of fatal error handling.
InternalCompilerErrors always have to end the whole compilation process because a serious inconsistency was detected.
2015-10-16 14:52:01 +02:00
chriseth
ead0478f26 Fix errors when struct array type is used on its own. 2015-10-16 14:36:30 +02:00
chriseth
02a3c1d999 Fix warning. 2015-10-16 13:48:46 +02:00
chriseth
cd9132672a Do not include function in interface list if there are errors. 2015-10-16 13:11:16 +02:00
chriseth
52eaa477d4 Merge pull request #132 from chriseth/tupleExpression
Tuple expressions and destructuring assignments
2015-10-16 10:01:34 +02:00
chriseth
2920a32ae8 Fixed indentation. 2015-10-16 10:01:22 +02:00
chriseth
030c868f58 Merge pull request #136 from LianaHus/sol_error_types_refuctoring
changed the way of reporting error during contract checking
2015-10-15 18:30:32 +02:00
LianaHus
ec5b9c2e92 changed the way of reporting error during contract checking 2015-10-15 18:15:52 +02:00
chriseth
1d4219d43d Some fixes taking other pull requests into account. 2015-10-15 18:14:14 +02:00
chriseth
e21df35416 MacOS fix. 2015-10-15 17:38:42 +02:00
chriseth
ae5b12f54b Fix compiler warnings. 2015-10-15 17:38:42 +02:00
chriseth
029b819489 Wildcards. 2015-10-15 17:38:42 +02:00
chriseth
039b2a764f Destructuring assignments. 2015-10-15 17:38:42 +02:00
chriseth
7ebd536e79 Tuple expressions. 2015-10-15 17:38:42 +02:00
chriseth
7ba42f4707 Merge pull request #130 from LefterisJP/dynamic_array_push
Dynamic array push
2015-10-15 17:37:15 +02:00
LianaHus
b2e787b803 missing const 2015-10-15 16:59:38 +02:00
LianaHus
2348a4ef34 indent 2015-10-15 16:56:12 +02:00
LianaHus
656e749b1e added const 2015-10-15 16:51:01 +02:00
LianaHus
162d021c3f some more style fixes 2015-10-15 16:27:26 +02:00
LianaHus
3871e77946 style fixes 2015-10-15 16:13:52 +02:00
LianaHus
68e126dc7d style fixes mostly 2015-10-15 16:08:02 +02:00
LianaHus
cd6262998c removed commit 2015-10-15 15:16:31 +02:00
Lefteris Karapetsas
a823de2d58 push() for byte arrays also properly implemented 2015-10-15 14:37:11 +02:00
LianaHus
771f20b595 mainly style fixes/renaming 2015-10-15 14:36:23 +02:00
Lefteris Karapetsas
9224c1f712 Working implementation of arraypush
ByteArrayPush() gets a test but is ignored for now, since there are
still some issues with its implementation
2015-10-15 13:54:59 +02:00
LianaHus
675aed1edf fixed new tests 2015-10-15 11:50:25 +02:00
LianaHus
7a7a7dcbb5 fixes error after conflict resolving 2015-10-15 11:10:55 +02:00
Lefteris Karapetsas
a521843f6b Implement Dynamic array push and fix test
Still a work in progress. There is a disturbance in the stack at the
moment and that's why there are some cout statements left for debugging.
2015-10-15 10:52:30 +02:00
Lefteris Karapetsas
3287cd464f WIP - Expression compiler for array push 2015-10-15 10:52:30 +02:00
LianaHus
c3491e4469 errors instead of exceptions
Conflicts:
	libsolidity/CompilerStack.cpp
	libsolidity/NameAndTypeResolver.cpp
	libsolidity/NameAndTypeResolver.h
	libsolidity/TypeChecker.cpp
	test/libsolidity/SolidityNameAndTypeResolution.cpp
2015-10-14 20:37:41 +02:00
LianaHus
8f7f22c5a6 some fixes 2015-10-14 20:27:44 +02:00
LianaHus
742e5b259a added Error class for all kind of errors
Conflicts:
	libsolidity/Exceptions.h
2015-10-14 20:27:41 +02:00
LianaHus
95ad872678 added Error class for all kind of errors
Conflicts:
	libsolidity/Exceptions.h

Conflicts:
	libsolidity/ReferencesResolver.cpp
2015-10-14 20:27:30 +02:00
chriseth
72f7792f8e Some further test fixes. 2015-10-13 14:31:24 +02:00
chriseth
13d7bc4ee8 Some more tests and typos fixed. 2015-10-13 12:22:57 +02:00
chriseth
deebc7e860 Multi-variable declarations. 2015-10-13 12:16:23 +02:00
chriseth
a5d12b8761 Introduced tuple type and added multi variable declarations to type
checker.
2015-10-09 19:35:41 +02:00
chriseth
b9a166061b Refactoring to allow multi-variable declarations. 2015-10-08 18:25:44 +02:00
chriseth
35de03626f Check invalid integer constants for functions accepting arbitrary arguments. 2015-10-07 18:13:20 +02:00
chriseth
24d04087d2 Resolve binary dependencies properly. 2015-10-07 17:35:07 +02:00
chriseth
68bf6e60c5 Merge pull request #122 from chriseth/anonymousEventsWithFourIndexedParams
Allow four indexed arguments for anynomous events.
2015-10-07 17:01:37 +02:00
chriseth
8644ad6866 Merge pull request #118 from chriseth/rejectEtherSentToLibrary
Reject ether sent to library.
2015-10-07 16:41:49 +02:00
chriseth
b6ddde9372 Allow four indexed arguments for anynomous events. 2015-10-07 16:40:54 +02:00
chriseth
f3913d6996 Fix boost error. 2015-10-07 12:31:38 +02:00
chriseth
0297a213fe Reject ether sent to library. 2015-10-06 22:55:45 +02:00
chriseth
55af63e463 Add const. 2015-10-06 14:43:09 +02:00
chriseth
99351aebe0 Compiler version stamp. 2015-10-06 14:20:06 +02:00
chriseth
44e42bf52e Add structs to library interface. 2015-10-06 14:20:06 +02:00
chriseth
bf5b387954 Provide access to scoped structs. 2015-10-06 14:20:06 +02:00
chriseth
bc609c55c0 Compute canonical names of types for function signatures. 2015-10-06 14:20:06 +02:00
chriseth
ce25ddfa6a Encode storage items correctly for library calls. 2015-10-06 14:20:06 +02:00
chriseth
421dcf4c1a Tests apart from new one work fine. 2015-10-06 14:20:06 +02:00
chriseth
9cc7402c95 Split external type into ecoding and interface type. 2015-10-06 14:19:56 +02:00
chriseth
da408640ca Store small byte arrays and strings in storage in one slot with their
length.
2015-10-02 13:12:23 +02:00
LianaHus
53d0684cb4 -fixed the warning printing
-style fixes
2015-10-02 12:38:48 +02:00
LianaHus
2706846f43 -added warning case to cl compiler
-modified warning msg
2015-10-02 12:38:48 +02:00
LianaHus
b2fa457327 removed unnecessary function declaration 2015-10-02 12:38:48 +02:00
LianaHus
fe2b9a3b3c added warning for noninitialized references in storage. 2015-10-02 12:38:48 +02:00
LianaHus
6712437e6b style fixes 2015-10-02 12:38:48 +02:00
LianaHus
468d6b6175 style fixes 2015-10-02 12:38:48 +02:00
chriseth
6161ec96ff Bugfix in calldata unpacker.
The offset was not specified correctly if memory activity preceded the
unpacker.
2015-10-01 16:50:11 +02:00
chriseth
e81f4ba45e Provide types for VariableDeclaration. 2015-09-24 12:12:36 +02:00
chriseth
1736fe8015 Merge pull request #95 from chriseth/styleCleanup
Style cleanup.
2015-09-24 11:55:44 +02:00
chriseth
c49e58a201 Style cleanup. 2015-09-24 11:05:04 +02:00
LianaHus
99ec6702df improved overflow check in memorySize for ArrayType 2015-09-24 10:51:06 +02:00
chriseth
52f7e35843 Merge pull request #91 from chriseth/literalStringsToStoragePointer
Literal strings to storage pointer
2015-09-24 10:23:35 +02:00
chriseth
8a9b9e4fdb Do not allow assignment from literal strings to storage pointers.
Fixes #90
2015-09-23 17:34:08 +02:00
LianaHus
c096c3c349 improved the test 2015-09-23 17:31:47 +02:00
LianaHus
5ba559beaf style fix 2015-09-23 17:31:47 +02:00
LianaHus
9547c4563c fixed-sized arrays as return type
Conflicts:
	test/libsolidity/SolidityEndToEndTest.cpp
2015-09-23 17:31:37 +02:00
chriseth
efdea76d5e Merge pull request #85 from chriseth/warnings
Support mulitple errors and warnings.
2015-09-23 14:42:54 +02:00
chriseth
3841d39904 Merge pull request #87 from chriseth/fixVersion
Add libevmasm version string.
2015-09-22 22:54:31 +02:00
chriseth
4d82e3165f Add libevmasm version string. 2015-09-22 16:23:21 +02:00
chriseth
e32a063a10 Style fix. 2015-09-22 12:07:34 +02:00
chriseth
31dc588b55 Build fix for MacOS. 2015-09-22 11:17:54 +02:00
chriseth
42c0009205 Error formatting. 2015-09-21 20:03:53 +02:00
chriseth
39d1e2bc06 Refactored annotations. 2015-09-21 20:03:10 +02:00
chriseth
34a81fd60e Refactoring: Check types outside of AST and recover from some errors. 2015-09-21 20:03:05 +02:00
LianaHus
e50400082b fixed using string as a type for struct member 2015-09-17 15:15:46 +02:00
Marek Kotewicz
352c196eb3 Merge pull request #79 from arkpar/cmake
Per project versioning
2015-09-17 10:34:15 +02:00
arkpar
bda7dbd30a per project versioning 2015-09-16 15:55:25 +02:00
LianaHus
1fb7488671 style 2015-09-16 13:44:07 +02:00
LianaHus
ca08fe50c6 style fixes 2015-09-16 13:25:32 +02:00
LianaHus
279a36b6f8 throw statement implementation 2015-09-16 13:25:32 +02:00
LianaHus
5291467a26 removed unneccessary check from ExpresiionCompiler 2015-09-15 11:40:20 +02:00
LianaHus
dd3b0664c6 style fixes 2015-09-15 11:40:20 +02:00
LianaHus
e17938a2a9 fixed conflict mergeing 2015-09-15 11:40:20 +02:00
LianaHus
e4eb40036b - changed implementation
- style fixes

Conflicts:
	libsolidity/AST.cpp
2015-09-15 11:40:19 +02:00
LianaHus
ede1f4b153 Update ExpressionCompiler.cpp
Conflicts:
	libsolidity/ExpressionCompiler.cpp
2015-09-15 11:40:19 +02:00
LianaHus
b7b16b153b added compile time check for out of bounds access for ordinary arrays
todo: check for dynamicaly sized arrays

Conflicts:
	libsolidity/ExpressionCompiler.cpp
2015-09-15 11:37:59 +02:00
chriseth
9309b6aa82 Merge pull request #70 from chriseth/sol_libraries2
Commandline interface for linker.
2015-09-14 14:56:01 +02:00
chriseth
4360e04596 Merge pull request #66 from chriseth/sol_libraries
Calling libraries.
2015-09-11 19:35:31 +02:00
chriseth
70c0ed4129 Commandline interface for the linker. 2015-09-11 19:35:01 +02:00
chriseth
147830d1a3 Small fixes to the type system concerning libraries. 2015-09-11 16:36:47 +02:00
chriseth
3c25420b84 Merge pull request #69 from LianaHus/sol_enum_too_many_indexed_args
too many indexed arguments for event
2015-09-11 15:48:43 +02:00
chriseth
d89832fa89 Style. 2015-09-11 15:25:00 +02:00
LianaHus
1d1386a58c add call for EventDefinition::checkTypeRequirements() 2015-09-11 15:24:11 +02:00
chriseth
976c380b61 Possibility to call library functions. 2015-09-11 15:21:37 +02:00
chriseth
a9edc7b1a6 Transition from bytecode to more general linker objects. 2015-09-11 15:21:37 +02:00
chriseth
337fde9d11 Parsing and type checking of libraries without inheritance. 2015-09-11 15:21:37 +02:00
chriseth
c5b6d9d2a9 Merge pull request #65 from LianaHus/sol_Creating_a_contract_from_within_itself
Added error when creating a contract from within itself
2015-09-11 15:19:58 +02:00
LianaHus
d570ab44c8 style fixes 2015-09-11 14:31:00 +02:00
LianaHus
47e42430f2 added type check if the type of the var decl is one of base contract type 2015-09-10 17:17:13 +02:00
LianaHus
845bcf8db0 - added tests to test empty comment
- fixed skipSingleLineComment
- some style fixes
2015-09-10 14:26:34 +02:00
chriseth
9967ae4038 Stylistic corrections. 2015-09-09 16:15:35 +02:00
chriseth
985eb80695 Fix for constant strings. 2015-09-08 16:51:14 +02:00
chriseth
ea981cb0f5 Merge pull request #41 from LianaHus/sol_rename_getters
solidity interface changes. removing get prefix
2015-09-08 16:47:58 +02:00
LianaHus
df8c82bc60 - renamed AST to ast and ABI to abi
- style fixes
2015-09-08 14:30:21 +02:00
LianaHus
02d4198242 removed get prefix
style fixes
2015-09-08 13:12:00 +02:00
LianaHus
1b5e6fc9e7 renamed getter functions 2015-09-08 13:12:00 +02:00
debris
619c91321b changes required to compile solidity in a single project 2015-09-01 15:30:26 +02:00
Gav Wood
91cffa0d5d Merge pull request #24 from LianaHus/sol_fix_error_check
added check for having type in VariableDeclaration::checkTypeRequirem…
2015-08-27 16:54:44 +02:00
debris
1741e89c09 client refactor 2015-08-27 14:28:31 +02:00
Marek Kotewicz
40e65295ff Merge pull request #26 from arkpar/cmake
Refactored CMakeLists for new module system
2015-08-24 15:57:48 +02:00
arkpar
3ea1a62fa9 Refactoreed CMakeLists for new module system 2015-08-24 15:51:52 +02:00
LianaHus
fed363263a added check for having type in VariableDeclaration::checkTypeRequirements() 2015-08-24 12:34:44 +02:00
chriseth
625be53252 Merge pull request #22 from LianaHus/sol_accessors_for_const_state_var
fixed the issue with accessors for constant state variables
2015-08-21 18:17:05 +02:00
LianaHus
1af8ff0121 add tests for state variables accessors. normal and constant
fixed the issue with accessors for constant state variables
2015-08-21 17:57:57 +02:00
chriseth
4128b04253 Propagate exceptions in clone calls. 2015-08-20 20:02:38 +02:00
Gav Wood
289b814670 Merge pull request #7 from chriseth/moreInfoForCommandlineOptions
More information for help screen, some fixes for argument parsing.
2015-08-20 11:02:07 +02:00
chriseth
0906042ce0 More information for help screen, some fixes for argument parsing. 2015-08-20 02:12:37 +02:00
chriseth
8d9eb68307 Modularise CMakeLists files and integrate tests. 2015-08-20 00:55:41 +02:00
Lefteris Karapetsas
27388950dd include Version.h under libsolidity 2015-08-19 16:12:18 +02:00
Lefteris Karapetsas
1690f1c947 Add CMakeLists.txt for libsolidity 2015-08-19 14:57:25 +02:00