Permalink
Browse files

Raise Citrus::Error when Proxy cannot resolve

  • Loading branch information...
1 parent 7603b61 commit 044e40c8e024cc5bb1695aec2b81d32e4d6ff891 @mjackson committed Jan 5, 2011
Showing with 3 additions and 4 deletions.
  1. +3 −4 lib/citrus.rb
View
@@ -774,8 +774,7 @@ def resolve!
rule = grammar.rule(rule_name)
unless rule
- raise RuntimeError,
- "No rule named \"#{rule_name}\" in grammar #{grammar.name}"
+ raise Error, "No rule named \"#{rule_name}\" in grammar #{grammar}"
end
rule
@@ -805,8 +804,8 @@ def resolve!
rule = grammar.super_rule(rule_name)
unless rule
- raise RuntimeError,
- "No rule named \"#{rule_name}\" in hierarchy of grammar #{grammar.name}"
+ raise Error,
+ "No rule named \"#{rule_name}\" in hierarchy of grammar #{grammar}"
end
rule

0 comments on commit 044e40c

Please sign in to comment.