Fixes #91. Handles empty grammars now.