$ cat c.pl
use Compiler::Lexer;
use Compiler::Parser;
use Compiler::Parser::AST::Renderer;
Compiler::Parser::AST::Renderer->new->render(Compiler::Parser->new()->parse(Compiler::Lexer->new()->tokenize("sub new { bless {} }")));
$ perl c.pl
Stmt |
-----FunctionDecl
-----Function
-----BlockStmt |
----------LeftBrace
----------Expr |
---------------BuiltinFunc
---------------Expr |
--------------------LeftBrace
--------------------RightBrace
----------RightBrace
Assertion failed: (block_node && "syntax error near by irregular function"), function parseIrregularFunction, file src/compiler/parser/Compiler_parser.cpp, line 1636.
zsh: abort perl ~/c.pl
$ perl -v
This is perl 5, version 16, subversion 3 (v5.16.3) built for darwin-thread-multi-2level
Copyright 1987-2012, Larry Wall
Perl may be copied only under the terms of either the Artistic License or the
GNU General Public License, which may be found in the Perl 5 source kit.
Complete documentation for Perl, including FAQ lists, should be found on
this system using "man perl" or "perldoc perl". If you have access to the
Internet, point your browser at http://www.perl.org/, the Perl Home Page.
$ cat c.pl
use Compiler::Lexer;
use Compiler::Parser;
use Compiler::Parser::AST::Renderer;
Compiler::Parser::AST::Renderer->new->render(Compiler::Parser->new()->parse(Compiler::Lexer->new()->tokenize("sub new { bless {} }")));
$ perl c.pl
Stmt |
-----FunctionDecl
-----Function
-----BlockStmt |
----------LeftBrace
----------Expr |
---------------BuiltinFunc
---------------Expr |
--------------------LeftBrace
--------------------RightBrace
----------RightBrace
Assertion failed: (block_node && "syntax error near by irregular function"), function parseIrregularFunction, file src/compiler/parser/Compiler_parser.cpp, line 1636.
zsh: abort perl ~/c.pl
$ perl -v
This is perl 5, version 16, subversion 3 (v5.16.3) built for darwin-thread-multi-2level
Copyright 1987-2012, Larry Wall
Perl may be copied only under the terms of either the Artistic License or the
GNU General Public License, which may be found in the Perl 5 source kit.
Complete documentation for Perl, including FAQ lists, should be found on
this system using "man perl" or "perldoc perl". If you have access to the
Internet, point your browser at http://www.perl.org/, the Perl Home Page.