Re:Yacc is not dead
by barrkel on Saturday March 12, 2011 @09:45PM
(#2318142)
Parsing is a very small part of the problem; and classical compiler-compilers introduce an extra indirection in your build process. Defining a type system (which may be compile-time, run-time, or both) and coherent semantics is more work.
Additionally, compiler-compilers exist in a particular zone of complexity. Your language has to be complex enough that it needs a dedicated parser rather than ad-hoc regex or recursive descent (and this needs to get over the hump of complicating your build process, which doesn't play well with modern IDEs, what with mixed source languages etc. (actions in rules)), yet not so complex or needing good error messages, recovery etc. that it again needs ad-hoc recursive-descent / operator precedence parsers. Most commercial compilers don't use yacc or anything like it; they instead usually use hand-written recursive descent.
Additionally, compiler-compilers exist in a particular zone of complexity. Your language has to be complex enough that it needs a dedicated parser rather than ad-hoc regex or recursive descent (and this needs to get over the hump of complicating your build process, which doesn't play well with modern IDEs, what with mixed source languages etc. (actions in rules)), yet not so complex or needing good error messages, recovery etc. that it again needs ad-hoc recursive-descent / operator precedence parsers. Most commercial compilers don't use yacc or anything like it; they instead usually use hand-written recursive descent.