MCPcopy
hub / github.com/webpack/webpack / setUsedInUnknownWay

Method setUsedInUnknownWay

lib/ExportsInfo.js:1211–1231  ·  view source on GitHub ↗

* Sets used in unknown way. * @param {RuntimeSpec} runtime only apply to this runtime * @returns {boolean} true, when something changed

(runtime)

Source from the content-addressed store, hash-verified

1209 * @returns {boolean} true, when something changed
1210 */
1211 setUsedInUnknownWay(runtime) {
1212 let changed = false;
1213 if (
1214 this.setUsedConditionally(
1215 (used) => used < UsageState.Unknown,
1216 UsageState.Unknown,
1217 runtime
1218 )
1219 ) {
1220 changed = true;
1221 }
1222 if (this.canMangleUse !== false) {
1223 this.canMangleUse = false;
1224 changed = true;
1225 }
1226 if (this.canInlineUse !== false) {
1227 this.canInlineUse = false;
1228 changed = true;
1229 }
1230 return changed;
1231 }
1232
1233 /**
1234 * Sets used without info.

Callers 7

applyMethod · 0.45
applyMethod · 0.45
setUsedInUnknownWayMethod · 0.45
finishEntryModuleMethod · 0.45
finishEntryModuleMethod · 0.45
finishEntryModuleMethod · 0.45

Calls 1

setUsedConditionallyMethod · 0.95

Tested by

no test coverage detected