bison - Custom scripting language -
bison - Custom scripting language -
i kind new writing custom languages. before diving flex,bison based lexers,parsers,compilers inquire if possible before begin research maybe after week work realize that's impossible. goal create scripting language translated c language not compiled farther until machine code because of code goes embedded platform , needs compiled differently normal languages. point create this: written script -> parser translates code c code based on rules -> compiles embedded machine code.
so maybe suggest me way this. reading flex & bison based custom languages compiled machine code think isn't need.
you might read literature concerning domain specific languages, e.g. dsl2011 , before proceedings.
don't focus much on lexing , parsing. of work , issues in defining language semantics , implementation.
making dsl translated c not easy task. see instance dsl2011 paper on melt.
read books on language semantics , pragmatics, e.g. programming language pragmatics scott.
read garbage collection handbook (jones, hosking, moss).
at last, read edition of c.queinnec lisp in little pieces, notably covers translating dynamically typed language c.
be aware lexing , parsing easy task in work.
did consider embedding existing scripting language e.g. lua, python or guile or using existing vms parrot or nekovm
don't forget study several different domain specific or scripting or programming languages. need know much more one!
i suggest making implementation freely available in source form. quite hard attract users new dsl, , providing free implementation lowers barrier.
bison flex-lexer
Comments
Post a Comment