E3001

E3001#

This source files contains invalid or incomplete tokens.

Erroneous example#

fn main {
  println('3)
}

This example gives the following error on line 2:

Lexing error: unrecognized character u32:0x27

... which indicates that the compiler don't know how to interpret the dangling character ' (ASCII 0x27) on that line as a part of a MoonBit token.

Suggestion#

Change your code to strictly follow the MoonBit syntax rules, so that it only contains valid MoonBit tokens.

In the above example, the missing closing apostrophe should be added:

fn main {
  println('3')
}