Quantcast
Channel: ReScript Forum - Latest posts
Viewing all articles
Browse latest Browse all 1794

Weird error with module type

$
0
0

I’m getting this error and I do not understand why, made this minimal repro:

module M: {
  let f: (~a: option<int>=?) => unit
} = {
  let f = (~a: option<int>=?) => {
    ()
  }
}

which gives this error:

  Signature mismatch:
  ...
  Values do not match:
    let f: (~a: int=?) => unit
  is not included in
    let f: (~a: option<int>=?) => unit

what am I doing wrong and what is it trying to tell me?


Viewing all articles
Browse latest Browse all 1794

Trending Articles