aboutsummaryrefslogtreecommitdiffstats
path: root/accounts/abi/abi.go
Commit message (Collapse)AuthorAgeFilesLines
* accounts/abi: fixed unpacking in to already slice interfacesJeffrey Wilcke2016-05-111-30/+29
| | | | | | | | | | | | | | | | Previously it was assumed that wheneven type `[]interface{}` was given that the interface was empty. The abigen rightfully assumed that interface slices which already have pre-allocated variable sets to be assigned. This PR fixes that by checking that the given `[]interface{}` is larger than zero and assigns each value using the generic `set` function (this function has also been moved to abi/reflect.go) and checks whether the assignment was possible. The generic assignment function `set` now also deals with pointers (useful for interface slice mentioned above) by dereferencing the pointer until it finds a setable type.
* accounts/abi: fixed string and fixed size bytes packingJeffrey Wilcke2016-04-281-4/+4
|
* accounts/abi: added unpacking "anything" in to interface{}Jeffrey Wilcke2016-04-281-0/+2
|
* accounts/abi: fixed strict go-like unpackingJeffrey Wilcke2016-04-281-5/+26
|
* accouns/abi: refactored ABI packageJeffrey Wilcke2016-04-201-47/+10
| | | | | | | | | | | | | | | | | Refactored the abi package parsing and type handling. Relying mostly on package reflect as opposed to most of our own type reflection. Our own type reflection is still used however for cases such as Bytes and FixedBytes (abi: bytes•). This also inclused several fixes for slice handling of arbitrary and fixed size for all supported types. This also further removes implicit type casting such as assigning, for example `[2]T{} = []T{1}` will fail, however `[2]T{} == []T{1, 2}` (notice assigning *slice* to fixed size *array*). Assigning arrays to slices will always succeed if they are of the same element type. Incidentally also fixes #2379
* abi: removed implicit type casting & refactored type parsingJeffrey Wilcke2016-04-051-1/+1
|
* abi: accept output slices of all supported typesJeffrey Wilcke2016-04-051-1/+71
|
* abi: accept input slices of all supported typesJeffrey Wilcke2016-04-051-4/+3
|
* accounts/abi/bind: constructor, auth utils and various backendsPéter Szilágyi2016-03-241-19/+27
|
* accounts/abi/bind, cmd/abigen: Go API generator around an EVM ABIPéter Szilágyi2016-03-241-22/+2
|
* Merge pull request #2348 from obscuren/abi-variable-inputPéter Szilágyi2016-03-171-2/+21
|\ | | | | accounts/abi: Fixed bytes input accept []byte and variable input support
| * accounts/abi: Fixed bytes input accept []byte and variable input supportJeffrey Wilcke2016-03-151-2/+21
| | | | | | | | | | | | | | | | | | Fixed up `[]byte` slice support such that `function print(bytes input)` accepts `[]byte` as input and treats it as 1 element rather than a slice of multiple elements. Added support for variable length input parameters like `bytes` and `strings`.
* | accounts/abi: handle the "constant" modifier for functionsPéter Szilágyi2016-03-161-7/+7
|/
* accounts/abi: support for typed arrayJeffrey Wilcke2016-02-151-12/+39
| | | | | Added support for fixed size and arbitrary length byte arrays to be marshallable in fixed size (typed) byte slices.
* accounts/abi: fixed return tuple and string, bytes return type parsingJeffrey Wilcke2016-02-111-30/+120
| | | | | | | | | | | | | Removed old unmarshalling of return types: `abi.Call(...).([]byte)`. This is now replaced by a new syntax: ``` var a []byte err := abi.Call(&a, ...) ``` It also addresses a few issues with Bytes and Strings and can also handle both fixed and arbitrary sized byte slices, including strings.
* account/abi: implements event parsingJeffrey Wilcke2016-02-021-4/+28
| | | | | | Implementation of basic event parsing and its input types. This separates methods and events and fixes an issue with go type parsing and validation.
* accounts/abi: added output parsing & added call mechanismJeffrey Wilcke2015-11-251-77/+69
| | | | Added calling mechanism and return value parsing
* accounts/abi: ABI fixes & added typesJeffrey Wilcke2015-10-301-6/+6
| | | | | | | Changed field `input` to new `inputs`. Addad Hash and Address as input types. Added bytes[N] and N validation
* all: fix license headers one more timeFelix Lange2015-07-241-1/+1
| | | | I forgot to update one instance of "go-ethereum" in commit 3f047be5a.
* all: update license headers to distiguish GPL/LGPLFelix Lange2015-07-231-4/+4
| | | | | All code outside of cmd/ is licensed as LGPL. The headers now reflect this by calling the whole work "the go-ethereum library".
* all: update license informationFelix Lange2015-07-071-0/+16
|
* Implemented contract ABIobscuren2015-01-271-0/+155