lib/yard/handlers/base.rb in yard-0.4.0 vs lib/yard/handlers/base.rb in yard-0.5.0

- old
+ new

@@ -148,11 +148,11 @@ include Parser class << self # Clear all registered subclasses. Testing purposes only - # @return [nil] + # @return [void] def clear_subclasses @@subclasses = [] end # Returns all registered handler subclasses. @@ -236,10 +236,12 @@ protected attr_reader :parser, :statement attr_accessor :owner, :namespace, :visibility, :scope + undef owner, owner=, namespace, namespace= + undef visibility, visibility=, scope, scope= def owner; parser.owner end def owner=(v) parser.owner=(v) end def namespace; parser.namespace end def namespace=(v); parser.namespace=(v) end @@ -320,20 +322,24 @@ end objects.size == 1 ? objects.first : objects end def ensure_loaded!(object, max_retries = 1) - return if object == Registry.root + return if object.root? unless parser.load_order_errors if object.is_a?(Proxy) raise NamespaceMissingError, object else nil end end - if RUBY_PLATFORM =~ /java/ - log.warn "JRuby does not implement Kernel#callcc and cannot load files in order. You must specify the correct order manually." + if RUBY_PLATFORM =~ /java/ || defined?(::Rubinius) + unless $NO_CONTINUATION_WARNING + $NO_CONTINUATION_WARNING = true + log.warn "JRuby/Rubinius do not implement Kernel#callcc and cannot " + + "load files in order. You must specify the correct order manually." + end raise NamespaceMissingError, object end retries = 0 context = callcc {|c| c } \ No newline at end of file