Skip to content
Playground(another site)

bynk.generics.internal_op_annotation

Error A capability operation carries an annotation outside the standard library, or a first-party operation's is not @onUndecodable(miss) or @onUndecodable(fault): the reply policy of a typed read is internal to first-party operations (#3458).

A capability operation's reply policy, @onUndecodable(miss) or @onUndecodable(fault), says what a reply that does not decode as the operation's payload type means. It belongs to the standard library's own operations, where the provider is reviewed with the runtime, so a capability you declare takes no annotation. Remove it.

Example

capability Store {
fn load(id: String) -> Effect[Option[String]] @onUndecodable(miss) // ✗ internal
}
capability Store {
fn load(id: String) -> Effect[Option[String]] // ✓
}

In the Book

See also

  • The grammar rule it governs: capability_op.
  • Every code in its category, Generics, on the diagnostic index.
  • bynk explain bynk.generics.internal_op_annotation shows the same from the installed toolchain, without a network.