operator_compose_ambiguous_bare_name_error
Stable error · Flatten
Tier: stable · Kind: error · Topic: Flatten
| Julia | TypeScript | Python | Rust | Go |
|---|---|---|---|---|
OperatorComposeAmbiguousBareNameError | OperatorComposeAmbiguousBareNameError | OperatorComposeAmbiguousBareNameError | not exported | OperatorComposeAmbiguousBareNameError |
Julia
struct OperatorComposeAmbiguousBareNameError <: EarthSciASTError
OperatorComposeAmbiguousBareNameError(details::String)
OperatorComposeAmbiguousBareNameError(details)
OperatorComposeAmbiguousBareNameError
Raised when the bare-name fallback would unify two STATE variables and the document has not said which spelling survives (esm-libraries-spec §4.7.1 step 3).
The fallback binds A.x to B.x on the strength of a shared local name alone.
When both are states, each carries its own INITIAL CONDITION, and the merge has
to delete one of them — so the choice decides which IC the flattened system
integrates from. Nothing in the document expresses that choice, and picking one
silently is how flipping the entry’s systems order came to change the answer.
So it is refused. The author says what they mean with translate, which names
the surviving spelling outright, or with require_match.
A match where only ONE side is a state is NOT ambiguous: the other carries no initial condition, so the state is the owner and the merge renames onto it.
Fields:
details::String: the entry and the two spellings it tried to unify.
TypeScript
class OperatorComposeAmbiguousBareNameError extends FlattenError
new OperatorComposeAmbiguousBareNameError(message: string): OperatorComposeAmbiguousBareNameError
The bare-name fallback would unify two STATE variables and the document has not said which spelling survives (esm-libraries-spec §4.7.1 step 3).
The fallback binds A.x to B.x on the strength of a shared local name alone.
When both are states, each carries its own INITIAL CONDITION, and the merge has
to delete one of them — so the choice decides which IC the flattened system
integrates from. Nothing in the document expresses that choice, and picking one
silently is how flipping the entry’s systems order came to change the answer.
A match where only ONE side is a state is NOT ambiguous: the other carries no initial condition, so the state is the owner and the merge renames onto it.
Python
class OperatorComposeAmbiguousBareNameError(FlattenError)
A bare-name match unified two STATES and the document did not say which survives.
esm-libraries-spec §4.7.1 step 3. The bare-name fallback binds A.x to
B.x on the strength of a shared local name alone. When both are state
variables, each carries its own INITIAL CONDITION, and the merge has to
delete one of them – so the choice decides which IC the flattened system
integrates from. Nothing in the document expresses that choice, and picking
one silently is how flipping the entry’s systems order came to change the
answer.
So it is refused. The author says what they mean with translate, which
names the surviving spelling outright, or with require_match.
A match where only ONE side is a state is NOT ambiguous: the other carries no initial condition, so the state is the owner and the merge renames onto it.
Rust
Rust does not export this error.
Go
type OperatorComposeAmbiguousBareNameError struct {
// A and B are the entry's two systems, Systems[0] and Systems[1].
A, B string
// BDep and TargetDep are the two spellings the fallback tried to unify.
BDep, TargetDep string
Message string
}
func (e *OperatorComposeAmbiguousBareNameError) DiagnosticCode() string
func (e *OperatorComposeAmbiguousBareNameError) Error() string
OperatorComposeAmbiguousBareNameError reports that the bare-name fallback would unify two STATE variables and the document has not said which spelling survives (esm-libraries-spec §4.7.1 step 3).
The fallback binds A.x to B.x on the strength of a shared local name alone. When both are states, each carries its own INITIAL CONDITION, and the merge has to delete one of them — so the choice decides which IC the flattened system integrates from. Nothing in the document expresses that choice, and picking one silently is how flipping the entry’s systems order came to change the answer.
A match where only ONE side is a state is NOT ambiguous: the other carries no initial condition, so the state is the owner and the merge renames onto it.
Methods
func (e *OperatorComposeAmbiguousBareNameError) DiagnosticCode() string
DiagnosticCode returns the stable diagnostic code (DiagnosticError).
func (e *OperatorComposeAmbiguousBareNameError) Error() string