ExpressibleByBoolLiteral

public protocol ExpressibleByBoolLiteral

Protocol for types that accept a true/false literal.

The init takes a primitive lang.i1 rather than Bool because Bool itself conforms — the literal lowering needs a representation that does not depend on the type being constructed.

Initializers

init(boolLiteral: lang.i1)

Builds an instance from a boolean literal.

Defined in lang/std/core/literals.ks