Artifact Content
Not logged in

Artifact abe7fd96d97ab5fa6a7933814908367cb8d86c0b


polemy.ast

polemy.ast

Authors:
k.inaba

License:
NYSL 0.9982 http://www.kmonos.net/nysl/

Syntax tree for Polemy programming language.

abstract class AST ;


immutable LexPosition pos ;


class Int : polemy.ast.AST;
AST node for integer literal

BigInt data ;


class Str : polemy.ast.AST;
AST node for string literal

string data ;


class Var : polemy.ast.AST;
AST node for variable reference

string name ;


class Lay : polemy.ast.AST;
AST node for @layered(expression)

Layer layer ;


AST expr ;


class Let : polemy.ast.AST;
AST node for variable declaration

string name ;


Layer layer ;


AST init ;


AST expr ;


class App : polemy.ast.AST;
AST node for function application

AST fun ;


AST[] args ;


class Parameter ;


string name ;


string[] layers ;


class Fun : polemy.ast.AST;
AST node for function literal

Parameter[] params ;


AST funbody ;


alias ListOfASTTypes ;
List of AST Types

template EasyAST ()
Handy Generator for AST nodes. To use this, mixin EasyAst;

template genEast (T)


alias strl ;


alias intl ;


funp (Parameter[] xs, AST ps);


alias var ;


alias lay ;


alias let ;


alias call ;


param (string name, string[] lay...);


Page was generated with on Wed Nov 24 21:12:49 2010