1. 06 6月, 2016 1 次提交
    • T
      accounts/abi: Negative numbers not properly converted in ABI encoding · 89c6c5bb
      Thomas Bocek 提交于
      When converting a negative number e.g., -2, the resulting ABI encoding
      should look as follows:
      fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe.
      However, since the check of the type is for an uint instead of an
      int, it results in the following ABI encoding:
      0101010101010101010101010101010101010101010101010101010101010102. The
      Ethereum ABI
      (https://github.com/ethereum/wiki/wiki/Ethereum-Contract-ABI) says,
      that signed integers are stored in two's complement which should be
      of the form ffffff.... and not 01010101..... for e.g. -1. Thus, I
      removed the type check in numbers.go as well as the function S256
      as I don't think they are correct. Or maybe I'm missing something?
      89c6c5bb
  2. 20 4月, 2016 1 次提交
    • J
      accouns/abi: refactored ABI package · 5127ec10
      Jeffrey Wilcke 提交于
      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
      5127ec10
  3. 05 4月, 2016 1 次提交
  4. 15 3月, 2016 1 次提交
  5. 25 11月, 2015 1 次提交
  6. 24 7月, 2015 1 次提交
  7. 23 7月, 2015 1 次提交
  8. 07 7月, 2015 1 次提交
  9. 16 3月, 2015 1 次提交
  10. 27 1月, 2015 1 次提交