mirror of
https://github.com/lightbend/config.git
synced 2025-02-23 09:41:01 +08:00
add check to SimpleConfigList that resolveStatus is correct
This commit is contained in:
parent
7844f13dfa
commit
fb17706961
@ -34,6 +34,11 @@ final class SimpleConfigList extends AbstractConfigValue implements ConfigList {
|
||||
super(origin);
|
||||
this.value = value;
|
||||
this.resolved = status == ResolveStatus.RESOLVED;
|
||||
|
||||
// kind of an expensive debug check (makes this constructor pointless)
|
||||
if (status != ResolveStatus.fromValues(value))
|
||||
throw new ConfigException.BugOrBroken(
|
||||
"SimpleConfigList created with wrong resolve status: " + this);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
Loading…
Reference in New Issue
Block a user