E07880: a function or function delegate is not required here
What went wrong
You've provided a function/delegate where one isn't needed.
Worked examples
Compilable examples demonstrating this error and the correct fix:
- ek9 -q 813 (How do call and async work in EK9 stream pipelines?)
How to fix it
- Remove the function/delegate argument
- Provide the expected value type instead
Common causes
- Extra function argument
- Wrong context interpretation
See also
Examples
Every example is compiled by the EK9 compiler: the first fails exactly as captioned, the others fix it.
Fails with E07880: a function or function delegate is not required here
#!ek9 defines module error.e07880.bad defines function greeting() <- rtn as String: "hello" greetAll() stdout <- Stdout() //call calls the functions flowing through it; it takes none of its own cat [greeting] | call greeting > stdout
Fixed: Write 'call' on its own
#!ek9 defines module error.e07880.good defines function greeting() <- rtn as String: "hello" greetAll() stdout <- Stdout() cat [greeting] | call > stdout
Questions and answers
These Q&A entries show E07880 and its fix:
Found a problem?
If EK9 reported E07880 for a program you think is valid, or did not report it where it should have, use the compiler form with the smallest program that shows it. If this page is wrong or unclear, use the documentation form. Both are at github.com/ek9lang/ek9-issues.