Method: Puppet::Pops::Types::PObjectType#check_self_recursion

Defined in:
lib/puppet/pops/types/p_object_type.rb

#check_self_recursion(originator) ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Assert that this type does not inherit from itself



1003
1004
1005
1006
1007
1008
1009
# File 'lib/puppet/pops/types/p_object_type.rb', line 1003

def check_self_recursion(originator)
  unless @parent.nil?
    raise Puppet::Error, "The Object type '#{originator.label}' inherits from itself" if @parent.equal?(originator)

    @parent.check_self_recursion(originator)
  end
end