Skip to content

igorw/ilias

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Ilias

Naive LISP implementation in PHP. For something more complete, check out Lisphp.

Check out the s-expression blog posts explaining the implementation of Ilias.

Usage

use Igorw\Ilias\Program;
use Igorw\Ilias\Lexer;
use Igorw\Ilias\Reader;
use Igorw\Ilias\FormTreeBuilder;
use Igorw\Ilias\Walker;
use Igorw\Ilias\Environment;

$program = new Program(
    new Lexer(),
    new Reader(),
    new FormTreeBuilder(),
    new Walker()
);

$env = Environment::standard();
$value = $program->evaluate($env, '(+ 1 2)');
var_dump($value);

will output:

int(3)

About

Naive LISP implementation in PHP.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages