Skip to content

Conversation

@janndriessen
Copy link
Collaborator

Summary of Changes

  • Fixes the ABI encoding of int and uint which was not taking the bits parameter into account

Test Data or Screenshots

  • Fixes and updates tests in ABIEncoderTest
By submitting this pull request, you are confirming the following:
  • I have reviewed the Contribution Guidelines.
  • I have performed a self-review of my own code.
  • I have updated my repository to match the develop branch.
  • I have included test data or screenshots that prove my fix is effective or that my feature works.
  • I have checked that all tests work and swiftlint is not throwing any errors/warnings.

// First 32 bytes are the first value from the array
XCTAssertEqual(hexData?[0..<64], "0000000000000000000000000000000000000000000000000000000000000001")
XCTAssertEqual(hexData, "0000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000030000000000000000000000000000000000000000000000000000000000000004")
// XCTAssertEqual(hexData?[0..<32], "0000000000000000000000000000000000000000000000000000000000000001")
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wasn't sure about this line. @JeneaVranceanu @yaroslavyaroslav

Is it actually needed or could it be deleted? Because of the bug fix of uint bits this hex string is now signficantly shorter.

@yaroslavyaroslav yaroslavyaroslav force-pushed the develop branch 4 times, most recently from a0218ff to 8c152f5 Compare December 10, 2024 18:12
@yaroslavyaroslav yaroslavyaroslav force-pushed the develop branch 9 times, most recently from a31d891 to e215270 Compare December 29, 2024 15:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant