mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Fix infinite loop when accessing circular constants from inline assembly.
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
==== Source: a ====
|
||||
import "b";
|
||||
uint constant c = d;
|
||||
==== Source: b ====
|
||||
import "a" as M;
|
||||
uint constant b = M.c;
|
||||
uint constant d = b;
|
||||
contract C {
|
||||
uint constant a = b;
|
||||
function f() public returns (uint t) {
|
||||
assembly {
|
||||
t := a
|
||||
}
|
||||
}
|
||||
}
|
||||
// ----
|
||||
// TypeError 3558: (b:178-179): Constant variable is circular.
|
||||
Reference in New Issue
Block a user