fix(ivy): keep JIT symbol table and r3_identifiers in sync (#24479)
At runtime in JIT mode, when the compiler writes a reference to a symbol that symbol is resolved through a symbol table named angularCoreEnv in render3/jit/environment. Previously, this symbol table was not kept up-to-date with the Ivy instruction set and the names of symbols the compiler could reference. This change brings the symbol table in sync, and also adds a test that verifies every symbol the compiler can reference is available at runtime in the symbol table. PR Close #24479
This commit is contained in:

committed by
Miško Hevery

parent
f00ae516eb
commit
a45fad3dd9
@ -6,7 +6,7 @@
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
*/
|
||||
|
||||
import {defineInjectable} from '../../di/defs';
|
||||
import {defineInjectable, defineInjector,} from '../../di/defs';
|
||||
import {inject} from '../../di/injector';
|
||||
import {defineNgModule} from '../../metadata/ng_module';
|
||||
import * as r3 from '../index';
|
||||
@ -21,7 +21,9 @@ export const angularCoreEnv: {[name: string]: Function} = {
|
||||
'ɵdefineComponent': r3.defineComponent,
|
||||
'ɵdefineDirective': r3.defineDirective,
|
||||
'defineInjectable': defineInjectable,
|
||||
'defineInjector': defineInjector,
|
||||
'ɵdefineNgModule': defineNgModule,
|
||||
'ɵdefinePipe': r3.definePipe,
|
||||
'ɵdirectiveInject': r3.directiveInject,
|
||||
'inject': inject,
|
||||
'ɵinjectAttribute': r3.injectAttribute,
|
||||
@ -60,18 +62,23 @@ export const angularCoreEnv: {[name: string]: Function} = {
|
||||
'ɵi6': r3.i6,
|
||||
'ɵi7': r3.i7,
|
||||
'ɵi8': r3.i8,
|
||||
'ɵiV': r3.iV,
|
||||
'ɵk': r3.k,
|
||||
'ɵkn': r3.kn,
|
||||
'ɵL': r3.L,
|
||||
'ɵld': r3.ld,
|
||||
'ɵP': r3.P,
|
||||
'ɵp': r3.p,
|
||||
'ɵpb1': r3.pb1,
|
||||
'ɵpb2': r3.pb2,
|
||||
'ɵpb3': r3.pb3,
|
||||
'ɵpb4': r3.pb4,
|
||||
'ɵpbV': r3.pbV,
|
||||
'ɵpD': r3.pD,
|
||||
'ɵPp': r3.Pp,
|
||||
'ɵQ': r3.Q,
|
||||
'ɵqR': r3.qR,
|
||||
'ɵrS': r3.rS,
|
||||
'ɵs': r3.s,
|
||||
'ɵsn': r3.sn,
|
||||
'ɵst': r3.st,
|
||||
|
Reference in New Issue
Block a user