plus

operator fun plus(entry: <Error class: unknown class><String, Directive>): DirectiveRegistry

register as an operator: DirectiveRegistry.Default + ("${'$'}feature" to gate). Strict like register — a duplicate marker throws; use override to replace.


operator fun plus(entries: Iterable<<Error class: unknown class><String, Directive>>): DirectiveRegistry

register for several directives at once, left to right.


merge under MergePolicy.ERROR as an operator: base + extras. Strict for the same reason plus is — silently picking a side would make which pack won depend on argument order. Call merge directly to choose another policy.

Build the right-hand pack from Empty, not Default: two registries that both carry the default pack conflict on every marker in it.