sc-forks/solidity-coverage

extraneous input after successful compilation

hexpaydaydev opened this issue · 1 comments

hi there, it seems like this may be happening on a separate layer from the compiler itself as hardhat does not seem to have a problem
line in question (key)

mapping(bytes32 key => uint256) public authorization;

build (compile) is successful

➜  stake-manager git:(master) ✗ yarn run build
yarn run v1.22.15
$ solhint 'contracts/**/*.sol' && hardhat compile

Generating typings for: 47 artifacts in dir: artifacts/types for target: ethers-v5
Successfully generated 108 typings!
Compiled 36 Solidity files successfully
✨  Done in 14.43s.

vs coverage

➜  stake-manager git:(master) ✗ npx hardhat coverage 

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

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

> AuthorizationManager.sol
Error in plugin solidity-coverage: Error: Could not instrument: AuthorizationManager.sol. (Please verify solc can compile this file without errors.) extraneous input 'key' expecting '=>' (13:18)

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

Resolved in 0.8.4