title: When is EOF needed in ANTLR 4?
body: <p>The <em>TestDriver</em> in ANTLRWorks2 seems kind of finicky about when it'll accept a grammer without and explicit <code>EOF</code> and when it will not. The <em>Hello</em> grammar in the <a href="https://github.com/antlr/antlr4/blob/master/doc/getting-started.md" rel="nofollow noreferrer">ANTLR4 Getting Started Guide</a> doesn't use <code>EOF</code> anywhere, so I inferred that it's better to avoid explicit <code>EOF</code> if possible.</p>
  
  <p>What is the best practice for using <code>EOF</code>? When do you actually need it?</p>