code: def validate_prop(value):
      
      if (
              isinstance(value, CLASS_TYPES) and
              issubclass(value, HasProperties)
      ):
          value = Instance('', value)
      if not isinstance(value, basic.Property):
          raise TypeError('Contained prop must be a Property instance or '
                          'HasProperties class')
      if value.default is not utils.undefined:
          warn('Contained prop default ignored: {}'.format(value.default),
               RuntimeWarning)
      return value
docs: Validate Property instance for container items