ethereum / solidity

Solidity, the Smart Contract Programming Language
https://soliditylang.org
GNU General Public License v3.0
23.38k stars 5.78k forks source link

[Sol->Yul] ICE because IR generator cannot parse location specification #13653

Open bshastry opened 2 years ago

bshastry commented 2 years ago

Repro:

  1. Create a file called p @src 0: as follows
$ cat <<EOF > p\ \@src\ 0:
contract C { }
EOF
  1. Compile said file via IR
$ solc p\ @src\ 0\: --ir

throws

https://github.com/ethereum/solidity/blob/84cdcec2cfb1fe9d4a9171d3ed0ffefd6107ee42/libsolidity/codegen/ir/IRGenerator.cpp#L112

NunoFilipeSantos commented 2 years ago

@bshastry what is the priority of this bug (High, Medium, Low)?

bshastry commented 2 years ago

@bshastry what is the priority of this bug (High, Medium, Low)?

I would say Low because a legitimate user is unlikely to name a source file as in the original report.