Working parser for digital logic expressions.