summaryrefslogtreecommitdiff
path: root/ext/psych/lib/psych/exception.rb
diff options
context:
space:
mode:
Diffstat (limited to 'ext/psych/lib/psych/exception.rb')
-rw-r--r--ext/psych/lib/psych/exception.rb7
1 files changed, 7 insertions, 0 deletions
diff --git a/ext/psych/lib/psych/exception.rb b/ext/psych/lib/psych/exception.rb
index 04a9a906a4..d7469a4b30 100644
--- a/ext/psych/lib/psych/exception.rb
+++ b/ext/psych/lib/psych/exception.rb
@@ -13,6 +13,13 @@ module Psych
end
end
+ # Subclasses `BadAlias` for backwards compatibility
+ class AnchorNotDefined < BadAlias
+ def initialize anchor_name
+ super "An alias referenced an unknown anchor: #{anchor_name}"
+ end
+ end
+
class DisallowedClass < Exception
def initialize action, klass_name
super "Tried to #{action} unspecified class: #{klass_name}"