static List<Rule> parseProductionRule(String line) {
        Matcher matcher = PRODUCTION_RULE_PATTERN.matcher(line);
        LinkedList<Rule> rules = new LinkedList<>();

        matcher.find();
        String rulePart = matcher.group(1).replaceAll("[ \t]+->[ \t]", "->");
        String[] rulePairs = rulePart.split("[ \t]+");

        for (String rule : rulePairs) {
            if (rule.trim().length() > 0) {
                String search = rule.split("->")[0];
                String replace = rule.split("->")[1];
                rules.add(new Rule(search, replace));
            }
        }

        return rules;
    }