Skip to content

ParserError solidity-coverage: v0.8.5 Solidity 0.8.19 #821

Closed
@ohaponiuk

Description

@ohaponiuk

PoC:

// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.9;

contract Test {
    function test() external {
        int i = 0;
        if (false) {} else i == 0 ? i = 0 : i--;
    }
}

Result:

❯ npx hardhat coverage

Version
=======
> solidity-coverage: v0.8.5

Instrumenting for coverage...
=============================

> Test.sol

Compilation:
============

ParserError: Expected ',' but got ';'
  --> contracts/Test.sol:22:51:
   |
22 |             else {((c_e76f6567(0x46bcacc667e80bd0); /* branch */ 
   |                                                   ^


Error in plugin solidity-coverage: HardhatError: HH600: Compilation failed

For more info run Hardhat with --show-stack-traces

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