Change visibility from [] to []
@@ -11255,6 +11255,18 @@ goog.debug.fnNameCache_ = {};
goog.debug.fnNameResolver_;
+/**
+ * Private internal function to support goog.debug.freeze.
+ * @param {T} arg
+ * @return {T}
+ * @template T
+ * @private
+ */
+goog.debug.freezeInternal_ = goog.DEBUG && Object.freeze || function(arg) {
+ return arg;
+};
+
+
/**
* Freezes the given object, but only in debug mode (and in browsers that
* support it). Note that this is a shallow freeze, so for deeply nested
@@ -11263,8 +11275,15 @@ goog.debug.fnNameResolver_;
* @return {T}
* @template T
*/
-goog.debug.freeze = goog.DEBUG && Object.freeze || function(arg) {
- return arg;
+goog.debug.freeze = function(arg) {
+ // NOTE: this compiles to nothing, but hides the possible side effect of
+ // freezeInternal_ from the compiler so that the entire call can be
+ // removed if the result is not used.
+ return {
+ valueOf: function() {
+ return goog.debug.freezeInternal_(arg);
+ }
+ }.valueOf();
};
//javascript/closure/i18n/uchar.js
