76 Commits

Author SHA1 Message Date
Hans Svensson
3dfe1b44fd Bump aebytecode version 2023-06-30 18:29:52 +02:00
Gaith Hallak
c395849684
Introduce debugging symbols (#424)
* Add fann type and to_fann fun

* Add fann() to funcall

* Add fann() to closure

* Add fann() to set_state

* Add fann() to remote_u

* Add fann() to remote

* Add fann() to proj

* Add fann() to set_proj

* Add fann() to def and def_u

* Add fann() to op

* Add fann() to let

* Add fann() to lam

* Add fann() to builtin_u

* Add missing functions specs

* Dead code removal

* Fix the spec for compute_state_layout

* Add fann() to var

* Add fann() to switch

* Add fann() to lit and get_state

* Add fann() to builtin

* Add fann() to con

* Add fann() to tuple

* Add fann() to nil

* Fix missing fann() in tuple fexpr()

* Add dbgloc instruction to fate

* Add instructions lines to the debugging result

* Fix compiler tests

* Fix calldata tests

* Rname Ann to FAnn when the type is fann()

* Add line to fann()

* Change attributes for DBGLOC instruction

* Add file to fann()

* Add file to aeso_syntax:ann()

* Fix dialyzer warning

* Remove fann() from fsplit_pat() and fpat()

* Fill out empty fann() when possible

* Save debug locations for child contracts

* Include DBGLOC instructions in the compiler output

* Return an empty string instead of no_file atom

* Wrap args of DBGLOC in immediate tuple

* Upgrade aebytecode ref in rebar.config

* Add DBG_DEF and DBG_UNDEF

* Do not DBG_DEF vars with % prefix

* Do not use DBG_DEF and DBG_UNDEF on args

* Fix dbg_undef for args

* Rename DBGLOC to DBG_LOC

* Remove column from DBG_LOC

* Add missing dbg_loc in to_scode1

* Keep a single DBG_LOC instruction per line

* Remove col from fann

* Add DBG_LOC op to step at function sig

* Remove the variable-register map from debug output

* Use get_value/3 to handle default

* Use lookup instead of lookup_all

* List only needed attributes

* Make debug ops impure

* Split complicated code and add comment

* Fix annotations

* Fix indenting

* Remove dbg_loc before closure

* Add dbg_loc in to_scode

* Add DBG_CALL and DBG_RETURN

* Separate the split at CALL_T and loop

* Revert "Separate the split at CALL_T and loop"

This reverts commit 4ea823a7ca798c756b20cee32f928f41092c4959.

* Revert "Add DBG_CALL and DBG_RETURN"

This reverts commit c406c6feb09b6a5bb859c38d634f08208c901e5a.

* Disable tail call optimization for better debug call stack

* Rename env.debug to env.debug_info

* Upgrade aebytecode: Add DBG_CONTRACT

* Add DBG_CONTRACT instruction

* Check if a var name is fresh in separate function

* Add DBG_CONTRACT and DBG_LOC before DBG_DEF

* Save fresh names of pattern variables

* Implement fsplit_pat_vars for assign

* Set fann for switches

* Revert "Save fresh names of pattern variables"

This reverts commit d2473f982996336131477df2b2115c04a55a62cb.

* Add DBG_DEF for switch pattern vars

* Fix the inability to pattern match constructors

* Upgrade aebytecode dep

* Upgrade aebytecode dep

* Update the lock file

* Add annotations to fexpr var

* Fix issues with pretty-printing of fexprs

* Use FAnn instead of get_fann(Body)

* Upgrade aebytecode version

* Fix pp_fpat

* Fix pattern matching on fpat

* Update rename when a new rename comes up

* Upgrade aebytecode

* Remove the getopt dep

* Fix calldata tests

* Remove file committed by mistake

* Remove location anns from contract call type
2023-06-13 14:36:48 +03:00
Radosław Rowicki
34b52739fd
Include all functions in the symbols map (#418)
* Include all functions in the symbols map

* .

* remove improper wording

* Use update_symbols exported from aebytecode

* Extract adding child symbols into a separate fun

* Make child contracts symbols optional

* Document include_child_contract_symbols option

Co-authored-by: Gaith Hallak <gaithhallak@gmail.com>
2022-10-07 15:57:37 +03:00
Radosław Rowicki
4dbc9858fb
Prepare 7.0.0 release, upgrade to OTP24 (#402)
* Prepare v7.0.0 release

* OTP25

* Try OTP24

* Update aebytecode

* aeb 3.1.1

* Update CHANGELOG.md

Co-authored-by: Hans Svensson <hanssv@gmail.com>

* Update rebar.lock

Co-authored-by: Hans Svensson <hanssv@gmail.com>
Co-authored-by: Gaith Hallak <gaithhallak@gmail.com>
2022-07-28 21:38:18 +02:00
Sean Hinde
6b46fc268b Use older rebar3 for upgrade 2021-11-10 14:32:29 +01:00
Sean Hinde
30bedad164 Use older rebar3 for upgrade 2021-11-10 14:25:33 +01:00
Sean Hinde
4d6938c741 Update aebytecode dep for otp-24 2021-11-10 14:21:23 +01:00
Radosław Rowicki
e8b32a6875
Call.fee (#313)
* Call.fee

* nice align
2021-05-24 14:30:57 +02:00
Radosław Rowicki
1d9f59fec3
Contract factories and bytecode introspection (#305)
* Support for CREATE, CLONE and BYTECODE_HASH

* Add missing files

* Pushed the clone example through the typechecker

* CLONE compiles

* Fix dependent type in CLONE

* Bytecode hash fixes

* Refactor

* Refactor 2

* move some logic away

* Fixed some error messages. Type inference of child contract still does some random shit\n(mistakes arguments with result type)

* CREATE sometimes compiles and sometimes not

* Fix some scoping/constraint issues

* works, needs cleanup

* cleanup

* Fix some tests. Remove optimization of singleton tuples

* Fix default argument for clone

* Cleanup

* CHANGELOG

* Mention void type

* Address review, fix some dialyzer errors

* Please dialyzer

* Fix failing tests

* Write negative tests

* Docs

* TOC

* missing 'the'

* missing 'the'

* missing 'the'

* missing 'the'

* mention pre-fund

* format

* pre-fund clarification

* format

* Grammar in docs
2021-05-18 12:21:57 +02:00
Ulf Norell
93d2086ddf aebytecode commit 2020-03-02 12:08:41 +01:00
Hans Svensson
e49738c90c New aebytecode reference 2020-02-26 18:23:12 +01:00
Hans Svensson
3da694e798 New aebytecode commit hash 2020-02-25 09:02:18 +01:00
Hans Svensson
b31be6227d Update aebytecode reference 2020-02-11 14:20:41 +01:00
Hans Svensson
bb79e7dd89 Update aebytecode reference 2020-02-03 14:26:13 +01:00
Hans Svensson
1c24a700dc Add BLS12-381 operations (to FATE) 2019-11-27 10:57:24 +01:00
skkw
5c5d3c60ef changed type of client ttl to int option 2019-11-18 16:25:47 +01:00
skkw
126e04ae42 support for AENS.update call 2019-11-12 14:27:46 +01:00
Ulf Norell
a333888fb9 aebytecode commit 2019-09-30 14:47:26 +02:00
Hans Svensson
d455671e24 Prepare v4.0.0-rc3 2019-09-10 15:14:19 +02:00
Ulf Norell
f09198b588 aebytecode commit 2019-09-09 18:40:45 +02:00
Erik Stenman
263c297090
Upgrade aebytecode after eqc fix. (#145) 2019-09-06 15:20:01 +02:00
Erik Stenman
d03cc50e03
Pt 168336524 renumber ops set base gas (#144)
* Use latest aebytecode with new opnumbers and gas.
2019-09-06 14:33:57 +02:00
Ulf Norell
46d244bfb4 aebytecode commit 2019-09-06 09:53:04 +02:00
Hans Svensson
47b3b9bcca Correct error type + new aebytecode 2019-09-05 15:14:17 +02:00
Hans Svensson
f0c728ef1e set aebytecode commit 2019-09-03 13:15:19 +02:00
sennui
1ee5a57924 change aebytecode version, aeserialization and add enacl 2019-09-02 08:54:38 +02:00
Ulf Norell
f27ba528d8 aebytecode commit 2019-08-30 11:21:26 +02:00
Hans Svensson
2dbef80249 aebytecode commit 2019-08-21 11:09:44 +02:00
Hans Svensson
86aeaa40ef Set aebytecode commit 2019-08-19 08:57:31 +02:00
Ulf Norell
956b78fb01 aebytecode commit 2019-08-16 09:14:51 +02:00
Tino Breddin
dd26649f7d [PT-167805291] Add opcode for ecrecover (#122)
* Add opcode for ecrecover

* Update aebytecode

* Extend signature bytes type used for ecrecover

* Add ecrecover to changelog

* Add some type specs

* Please dialyzer
2019-08-14 21:02:46 +02:00
Ulf Norell
3877174acb aebytecode commit 2019-08-13 15:53:49 +02:00
Thomas Arts
6aed5dfacb Upgrade to newer aebytecode version 2019-08-06 13:20:03 +02:00
Ulf Norell
054a5a4867 Update to latest aebytecode 2019-08-05 11:51:10 +02:00
Tobias Lindahl
6f873e45b8 Use a name string rather than a name hash in transfer and revoke 2019-07-01 07:42:08 +02:00
Hans Svensson
a617a6469d Change Chain.block_hash to return option(hash) 2019-06-27 14:19:39 +02:00
Tobias Lindahl
c26ace6c2c Implement aens instructions for fate 2019-06-26 13:24:48 +02:00
Ulf Norell
20085301ef aebytecode commit 2019-06-25 19:58:14 +02:00
Ulf Norell
894ae19435 aebytecode commit 2019-06-24 14:25:08 +02:00
Ulf Norell
592869bf75 aebytecode commit 2019-06-20 15:39:55 +02:00
Thomas Arts
d571993405 Fix type spec 2019-06-20 13:13:25 +02:00
Tobias Lindahl
03c6ae1c74 Add type information to oracle instructions 2019-06-20 09:23:09 +02:00
Tobias Lindahl
990df562e0
Handle oracle operation in FATE (#90)
* Handle oracle operation in FATE

Keep oracle type information on fcode level

Introduce typereps as values

Handle oracle registration

Handle oracle query object and oracle_query op

Handle oracle get question

Handle oracle query fee

Handle oracle get answer

Handle oracle respond

Handle oracle extend

* Address review comment
2019-06-18 14:32:08 +02:00
Hans Svensson
11dc632927 Add handling of auth_tx_hash 2019-06-14 13:14:24 +02:00
Thomas Arts
5513c4de1b New version of aebytecode 2019-06-11 15:24:58 +02:00
Hans Svensson
a14fa93920 Add contract_to_address to FATE 2019-06-11 12:05:58 +02:00
Ulf Norell
7b5db76c13 aebytecode commit 2019-06-05 18:20:20 +02:00
Ulf Norell
a64b72d04b aebytecode commit 2019-06-05 12:11:49 +02:00
Ulf Norell
0409a658b0 Update to new TUPLE instruction
... and minor fixes
2019-05-28 14:18:38 +02:00
Tobias Lindahl
60d9581fae Add missing instructions for FATE 2019-05-28 11:35:24 +02:00