ambiguous-phrase

More than one phrase matches the sentence by its shape.

compile error, shown by synod check.

Exactly one candidate must match. Types never choose between phrases, so a phrase that has the same shape as a language form, such as [a] and [b], makes every use of it ambiguous. The error names both definitions.

Give the phrase a head and words that no language form uses.

Example

Check this program to see the diagnostic.

# package p
Node has
  set ok to false

define Foo and [b: bool]
  result b

define [n: Node] Go
  set n.ok to (Foo and true)

Diagnostic

p/p.synod:9:16: error[ambiguous-phrase]: "Foo and true" matches more than one phrase
  hint: "Foo and [b: bool]" (p/p.synod:5) and the language form "[a] and [b]"

Fix

Rename the phrase so its shape is its own.

# package p
Node has
  set ok to false

define Foo with [b: bool]
  result b

define [n: Node] Go
  set n.ok to (Foo with true)