Open
Description
Discovered in #15661 (comment)
Description
A reference to a library name in inline assembly triggers an unimplemented feature error. At this point the IR codegen is considered feature-complete so this not being implemented yet is a bug.
Moreover the error does not provide any message for the user.
While we do have this case covered by a syntax test (assignment_from_library.sol
), it went undiscovered until now because we don't run syntax tests via IR. When the bug is fixed, please remember to enable this test on EOF.
Environment
- Compiler version: 0.8.28 (
develop
)
Steps to Reproduce
test.sol
:
library L {}
contract C {
function f() public pure {
assembly {
let x := L
}
}
}
solc test.sol --ir
Error: Unimplemented feature
--> test.sol:5:9:
|
5 | assembly {
| ^ (Relevant source part starts here and spans across multiple lines).
Metadata
Metadata
Assignees
Labels
There is not much implementation work to be done. The task is very easy or tiny.Changes are not very noticeable or potential benefits are limited.Something we consider essential but not enough to prevent us from releasing Solidity 1.0 without it.Error is reported even though it shouldn't. Source is fine.