Refactor method generation

Move method body into block on the ProcedureParseNode class, which
simplifies code generation.