E4085

E4085#

This has no parameter with the given label.

This error happens when:

  • You made a typo in the label name;

  • You mistakenly treat a positional argument as a labelled argument.

  • You provide extra labelled arguments to the function.

Erroneous Example#

///|
pub fn f(name : String) -> Unit {
  println("Hello, \{name}")
}

///|
test {
  f("John", age=20)
}

Suggestion#

Check the signature of the function and provide the correct label name or remove the extra labelled argument.

///|
pub fn f(name : String) -> Unit {
  println("Hello, \{name}")
}

///|
test {
  f("John")
}