fixes for msvc (supports grammars for 3 rules only for now)