We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1f042c6 commit e82e45fCopy full SHA for e82e45f
src/compiler.ts
@@ -10028,10 +10028,10 @@ export class Compiler extends DiagnosticEmitter {
10028
10029
/** Check if possible to optimize the active initialization away if it's zero */
10030
canOptimizeZeroInitialization(valueExpr: ExpressionRef): bool {
10031
- if ((this.options.runtime != Runtime.Incremental) && (this.options.runtime != Runtime.Stub)) {
10032
- return false;
10033
- }
10034
- return isConstZero(valueExpr);
+ const runtime = this.options.runtime;
+ return (runtime == Runtime.Incremental || runtime == Runtime.Stub)
+ ? isConstZero(valueExpr)
+ : false;
10035
}
10036
10037
/** Makes a constant zero of the specified type. */
0 commit comments