Added support for unix scripts
All checks were successful
/ test (push) Successful in 29s

This commit is contained in:
Eduard Urbach 2025-07-07 16:54:38 +02:00
parent f6eb30e460
commit 031edd2ffe
Signed by: ed
GPG key ID: 49226B848C78F6C8
9 changed files with 102 additions and 3 deletions

View file

@ -41,6 +41,7 @@ func (s *scanner) scanFile(path string, pkg string) error {
return nil
case token.Invalid:
return errors.New(&InvalidCharacter{Character: tokens[i].String(file.Bytes)}, file, tokens[i].Position)
case token.Script:
default:
return errors.New(&InvalidTopLevel{Instruction: tokens[i].String(file.Bytes)}, file, tokens[i].Position)
}