<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <br>
    <blockquote cite="mid:5015C58D.4040101@harvee.org" type="cite">I
      appreciate the help because I believe that once this is working,
      it'll make a significant difference in the ability for disabled
      programmers to write code again as well as be able to integrate
      within existing development team and their naming conventions. </blockquote>
    <p>Did you try to use pygments?<br>
      <br>
      <a class="moz-txt-link-freetext" href="http://pygments.org/docs/api/">http://pygments.org/docs/api/</a><br>
      <br>
      It already contains a lexer for Python source code. You can create
      a Lexer (pygments.lexer.Lexer) then call its get_tokens method.<br>
      <br>
      Then you can use this to identify statements:<br>
      <br>
      <a class="moz-txt-link-freetext" href="http://docs.python.org/reference/simple_stmts.html">http://docs.python.org/reference/simple_stmts.html</a><br>
      <br>
      Fortunately, almost all statements begin with a keyword. There are
      some exceptions:<br>
      <br>
          expression statement<br>
          assignment statement<br>
    </p>
    <p>I would first tokenize the code, then divide it by statement
      keywords. Finally, you just need to find expression/assignment
      statements in the remaining sections. (Maybe there is a better way
      to do it.)<br>
    </p>
    <cite></cite>
  </body>
</html>