Skip to content
This repository was archived by the owner on Dec 5, 2024. It is now read-only.
This repository was archived by the owner on Dec 5, 2024. It is now read-only.

No distinction between uint and int in SolidityType #1184

Closed
@jondoe1337

Description

@jondoe1337

I was investigating a strange decoding behavior as i discovered that in SolidityType#decodeInt (l. 404) is no distincted case for an unsigned int.
Shouldn't the BigInteger constructor call use the signum = 1 param in that case?

Currently byte[] b = [-13, -75, 19, 86, -119, 67, 112, -4, 118, -86, 98, -46, 103, -42, -126, 63, -60, -15, -87, 57, 43, 11, -17, -52, 0, 3, -65, 14, -67, -40, 65, 119]
will get parsed to -5560134246666045367803923210000275923246569538997228521514361932073667116681
instead of 110231954990650150055767061798687631930023415126643335517943222075839462523255.

I can provide a testcase and PR if appreciated.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions