012 reject pub proc

✓ Passing Passing: the compiler rejects this program as expected.

Code

input.kz

Actual compiler output

error[PARSE003]: 'pub' is not valid on proc declarations - only events can be public
  --> tests/regression/000_CORE_LANGUAGE/020_EVENTS_FLOWS/020_012_reject_pub_proc/input.kz:8:1
    |
  8 | ~pub proc greet {
    | ^

Frontend must reject with:

CONTAINS error[PARSE003
CONTAINS not valid on proc declarations

Expected compiler error

error[PARSE003]: 'pub' is not valid on proc declarations - only events can be public
  --> tests/regression/000_CORE_LANGUAGE/020_EVENTS_FLOWS/020_012_reject_pub_proc/input.kz:8:1
    |
  8 | ~pub proc greet {
    | ^

Test Configuration

MUST_ERROR LANGUAGES: zig cs