Exception: Pione::Lang::UnboundError
- Inherits:
-
BindingError
- Object
- StandardError
- LangError
- BindingError
- Pione::Lang::UnboundError
- Defined in:
- lib/pione/lang/lang-exception.rb
Overview
UnboundError is raised when unbound variable, rule, or package was referred.
Instance Method Summary collapse
-
#initialize(ref) ⇒ UnboundError
constructor
A new instance of UnboundError.
- #message ⇒ Object
Methods inherited from BindingError
Constructor Details
#initialize(ref) ⇒ UnboundError
Returns a new instance of UnboundError.
103 104 105 |
# File 'lib/pione/lang/lang-exception.rb', line 103 def initialize(ref) @ref = ref end |
Instance Method Details
#message ⇒ Object
107 108 109 110 111 112 113 114 |
# File 'lib/pione/lang/lang-exception.rb', line 107 def case @ref when Variable, RuleExpr "%s in package %s is unbound%s" % [name, @ref.package_id, @ref.pos.format] when PackageExpr "package &%s is unknown" % @ref.package_id end end |