Skip to content

Instantly share code, notes, and snippets.

@jamesladd
Created January 26, 2011 21:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jamesladd/797477 to your computer and use it in GitHub Desktop.
Save jamesladd/797477 to your computer and use it in GitHub Desktop.
ANTLR grammar for smalltalk chunks
program returns [Program n]
: (chunk)* EOF
;
chunk returns [Chunk n]
: sequence EOF
| sequence '!'
| '!' sequence '!'
| messagePattern sequence '! !'
;
messagePattern returns [MessagePattern n]
: NAME
| KEYWORD NAME
;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment