_trueTypeOf = function(something) {
  'use strict';
  let result = typeof something;
  try {
    switch (result) {
      case 'string':
        break;
      case 'boolean':
        break;
      case 'number':
        break;
      case 'object':
        if (something == null) {
          result = 'null';
          break;
        }
      case 'function':
        let foundConstructor = false;
        for (let i = 0; i < PRIMITIVE_TRUE_TYPES.length; i++) {
          // NOTE: this cannot be a for-of loop because it's used from Rhino
          // without the necessary Array.prototype[Symbol.iterator] polyfill.
          const trueType = PRIMITIVE_TRUE_TYPES[i];
          if (something.constructor === goog.global[trueType]) {
            result = trueType;
            foundConstructor = true;
            break;
          }
        }
        // Constructor doesn't match any of the known "primitive" constructors.
        if (!foundConstructor) {
          const m =
              something.constructor.toString().match(/function\s*([^( ]+)\(/);
          if (m) {
            result = m[1];
          }
        }
        break;
    }
  } catch (e) {
  } finally {
    result = result.slice(0, 1).toUpperCase() + result.slice(1);
  }
  return result;
}
@type {!Object<string, function(?, ?, number): boolean>}
@private