title: Unable to put a WITH FUNCTION clause in a BEGIN/END block
body: <p>Why doesn't the below code compile:</p>
  <pre><code>DECLARE
  c number;
  BEGIN
  WITH
  FUNCTION calculate(i IN NUMBER) RETURN NUMBER
  AS
  r number;
  BEGIN
    r := i*i;
    RETURN r;
  END;
  select calculate(1) INTO c from dual;
  END;
  </code></pre>
  <p>giving the following error:</p>
  <pre class="lang-none prettyprint-override"><code>Error report -
  *ORA-06550: line 5, column 10:
  PL/SQL: ORA-00905: missing keyword
  ORA-06550: line 4, column 1:
  PL/SQL: SQL Statement ignored
  </code></pre>
  <p>whereas:</p>
  <pre><code>WITH
  FUNCTION calculate(i IN NUMBER) RETURN NUMBER
  AS
  r number;
  BEGIN
    r := i*i;
    RETURN r;
  END;
  select calculate(1) from dual;
  </code></pre>
  <p>compiles?</p>
  <p><strong>Oracle version information</strong></p>
  <blockquote>
  <p>Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production<br />
  PL/SQL Release 12.1.0.2.0 - Production</p>
  </blockquote>