Skip to content

updated VRF library to solidity 0.8.x#26

Open
tani404 wants to merge 1 commit intowitnet:masterfrom
tani404:fix/solidity-0.8-support
Open

updated VRF library to solidity 0.8.x#26
tani404 wants to merge 1 commit intowitnet:masterfrom
tani404:fix/solidity-0.8-support

Conversation

@tani404
Copy link

@tani404 tani404 commented Sep 24, 2025

Description:

This pull request updates the VRF Solidity library and its dependencies to be compatible with Solidity version 0.8.x.

Changes made:

  1. Updated pragma solidity statements in:

    • VRF.sol -> ^0.8.0
    • Migrations.sol -> ^0.8.0
    • EllipticCurve.sol (from elliptic-curve-solidity) -> ^ 0.8.0
  2. Modified unsafe type conversion in VRF.sol to match Solidity 0.8.x strict type rules

  3. Updated Truffle to the latest version (v5.11.5) to support modern compiler.

  4. Truffle config updated to use compiler version ^0.8.0 with optimizer enabled.

  5. Verified compilation:

    • All contracts now compile successfully with Solidity 0.8.x.

Why this is needed:

  • The original library was locked to Solidity <0.7.0, which is outdated and incompatible with most modern projects.

Notes for maintainers:

  • This PR only changes the solidity version and minor type adjustments; logic of the contracts remains unchanged.

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