NAME
Language::Expr::Interpreter::default - A default interpreter for Language::Expr
VERSION
This document describes version 0.29 of Language::Expr::Interpreter::default (from Perl distribution Language-Expr), released on 2016-07-03.
SYNOPSIS
use Language::Expr::Interpreter::default;
my $itp = Language::Expr::Interpreter::default->new;
$itp->vars->{a} = 'A';
say $itp->eval(q["$a b" . "c"]); # "A b c"
DESCRIPTION
Interprets Language::Expr expression. Some notes:
Uses boolean module.
Follows Perl's notion of true and false.
That is, this expression ' "" || "0" || 2 ' will result to 2 because Perl thinks "" and "0" are false.
BUGS/TODOS
Currently subexpression (map/grep/usort) doesn't work yet.
ATTRIBUTES
vars => {NAME => VAL, ...}
Store variables.
funcs => {NAME => CODEREF, ...}
List known functions.
level => INT
Current recursion level.
METHODS
HOMEPAGE
Please visit the project's homepage at https://metacpan.org/release/Language-Expr.
SOURCE
Source repository is at https://github.com/sharyanto/perl-Language-Expr.
BUGS
Please report any bugs or feature requests on the bugtracker website https://rt.cpan.org/Public/Dist/Display.html?Name=Language-Expr
When submitting a bug or request, please include a test-file or a patch to an existing test-file that illustrates the bug or desired feature.
AUTHOR
perlancar <perlancar@cpan.org>
COPYRIGHT AND LICENSE
This software is copyright (c) 2016 by perlancar@cpan.org.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.