When creating an Element with a ref from inside of a constructor an error is thrown in production mode, but not in dev mode.

Here is a minimal sample:
https://jsfiddle.net/84v837e9/35/

An error, "Only a ReactOwner can have refs", should happen in dev and production modes.

This is happening in React 15.4
if (__DEV__) {
      renderedElement = measureLifeCyclePerf(
        () => inst.render(),
        this._debugID,
        'render',
      );
    } else {
      renderedElement = inst.render();
    }
    if (__DEV__) {
      
      if (renderedElement === undefined && inst.render._isMockFunction) {
        
        
        renderedElement = null;
      }
    }
    return renderedElement;
  },
  /**
   * @private
   */
  _renderValidatedComponent: function() {
    var renderedElement;
    if (
      __DEV__ ||
      this._compositeType !== ReactCompositeComponentTypes.StatelessFunctional
    ) {
      ReactCurrentOwner.current = this;
      if (__DEV__) {