# Convert bnf/yacc grammar definition to syntax package

**URL:** <https://forum.sublimetext.com/t/convert-bnf-yacc-grammar-definition-to-syntax-package/15980>\
**Category:** Plugin Development\
**Created:** [November 20, 2015, 7:52am UTC](https://forum.sublimetext.com/t/convert-bnf-yacc-grammar-definition-to-syntax-package/15980 "2015-11-20T07:52:43Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Inso\_Reiges](https://forum.sublimetext.com/user_avatar/forum.sublimetext.com/inso_reiges/32/64163_2.png) [@Inso\_Reiges](https://forum.sublimetext.com/u/Inso_Reiges)\
**Post date:** [November 20, 2015, 7:52am UTC](https://forum.sublimetext.com/t/convert-bnf-yacc-grammar-definition-to-syntax-package/15980/1 "2015-11-20T07:52:43Z")

</div>

Hi! Is there any tool that can convert BNF or YACC or similar context-free grammar definition to sublime syntax definition so i don’t have to do it by hand? Like a parser generator?  
Also as a more general question, can regex derivative used in sublime syntax definition actually match context-free languages?  
I am not yet familiar with sublime syntax packages, sorry if my questions will sound silly.

---

<div class="post-metadata">

**Author:** ![Arshiacont](https://forum.sublimetext.com/user_avatar/forum.sublimetext.com/arshiacont/32/64088_2.png) [@Arshiacont](https://forum.sublimetext.com/u/Arshiacont)\
**Post date:** [January 17, 2016, 10:07am UTC](https://forum.sublimetext.com/t/convert-bnf-yacc-grammar-definition-to-syntax-package/15980/2 "2016-01-17T10:07:34Z")

</div>

Did you manage to solve your problem? Just wondering if I have to do my Sublime Syntax definitions by ‘hand’ or if there’s anything that would take a Flex/Yacc definition and convert it… .
