From da2880d7c495022405102f89b8c641b23516388d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mi=C5=A1ko=20Hevery?= Date: Fri, 11 Jan 2019 16:07:01 -0800 Subject: [PATCH] fixup! fix(ivy): add missing @nocollapse annotation to __NG_ELEMENT_ID__ fields (#28050) (#28066) PR Close #28066 --- packages/core/src/di/injectable.ts | 3 ++- packages/core/src/di/injector.ts | 4 +++- packages/core/src/di/injector_compatibility.ts | 3 ++- packages/core/src/di/interface.ts | 15 --------------- packages/core/src/di/interface/index.ts | 11 ----------- packages/core/src/di/r3_injector.ts | 4 +++- packages/core/src/di/reflective_injector.ts | 2 +- packages/core/src/di/reflective_provider.ts | 2 +- packages/core/src/di/util.ts | 2 +- packages/core/src/render3/interfaces/injector.ts | 2 +- packages/core/src/render3/ng_module_ref.ts | 3 ++- packages/core/src/view/refs.ts | 2 +- 12 files changed, 17 insertions(+), 36 deletions(-) delete mode 100644 packages/core/src/di/interface.ts delete mode 100644 packages/core/src/di/interface/index.ts diff --git a/packages/core/src/di/injectable.ts b/packages/core/src/di/injectable.ts index 131cfad4fc..d5247b2df4 100644 --- a/packages/core/src/di/injectable.ts +++ b/packages/core/src/di/injectable.ts @@ -10,7 +10,8 @@ import {Type} from '../interface/type'; import {compileInjectable as render3CompileInjectable} from '../render3/jit/injectable'; import {TypeDecorator, makeDecorator} from '../util/decorators'; -import {ClassSansProvider, ConstructorSansProvider, ExistingSansProvider, FactorySansProvider, InjectableDef, InjectableType, StaticClassSansProvider, ValueSansProvider, defineInjectable, getInjectableDef} from './interface'; +import {ClassSansProvider, ConstructorSansProvider, ExistingSansProvider, FactorySansProvider, StaticClassSansProvider, ValueSansProvider,} from './interface/provider'; +import {InjectableType, defineInjectable, getInjectableDef, InjectableDef} from './interface/defs'; import {convertInjectableProviderToFactory} from './util'; diff --git a/packages/core/src/di/injector.ts b/packages/core/src/di/injector.ts index 22b2b28b2c..3690f12d83 100644 --- a/packages/core/src/di/injector.ts +++ b/packages/core/src/di/injector.ts @@ -13,7 +13,9 @@ import {stringify} from '../util/stringify'; import {resolveForwardRef} from './forward_ref'; import {InjectionToken} from './injection_token'; import {inject} from './injector_compatibility'; -import {ConstructorProvider, ExistingProvider, FactoryProvider, InjectFlags, StaticClassProvider, StaticProvider, ValueProvider, defineInjectable} from './interface'; +import {defineInjectable} from './interface/defs'; +import {InjectFlags} from './interface/injector'; +import {ConstructorProvider, ExistingProvider, FactoryProvider, StaticClassProvider, StaticProvider, ValueProvider} from './interface/provider'; import {Inject, Optional, Self, SkipSelf} from './metadata'; export const SOURCE = '__source'; diff --git a/packages/core/src/di/injector_compatibility.ts b/packages/core/src/di/injector_compatibility.ts index 0a2b2aca04..f314afce57 100644 --- a/packages/core/src/di/injector_compatibility.ts +++ b/packages/core/src/di/injector_compatibility.ts @@ -11,7 +11,8 @@ import {stringify} from '../util/stringify'; import {InjectionToken} from './injection_token'; import {Injector} from './injector'; -import {InjectFlags, InjectableDef, getInjectableDef} from './interface'; +import {InjectableDef, getInjectableDef} from './interface/defs'; +import {InjectFlags} from './interface/injector'; import {Inject, Optional, Self, SkipSelf} from './metadata'; diff --git a/packages/core/src/di/interface.ts b/packages/core/src/di/interface.ts deleted file mode 100644 index 25dd59c37a..0000000000 --- a/packages/core/src/di/interface.ts +++ /dev/null @@ -1,15 +0,0 @@ -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * Use of this source code is governed by an MIT-style license that can be - * found in the LICENSE file at https://angular.io/license - */ - -/** - * This file should not be necessary because node resolution should just default to `./di/index`! - * - * However it does not seem to work and it breaks web tests. - */ - -export * from './interface/index'; diff --git a/packages/core/src/di/interface/index.ts b/packages/core/src/di/interface/index.ts deleted file mode 100644 index 680be40252..0000000000 --- a/packages/core/src/di/interface/index.ts +++ /dev/null @@ -1,11 +0,0 @@ -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * Use of this source code is governed by an MIT-style license that can be - * found in the LICENSE file at https://angular.io/license - */ - -export * from './injector'; -export * from './defs'; -export * from './provider'; diff --git a/packages/core/src/di/r3_injector.ts b/packages/core/src/di/r3_injector.ts index bbf6f490e0..4f99f872cd 100644 --- a/packages/core/src/di/r3_injector.ts +++ b/packages/core/src/di/r3_injector.ts @@ -14,7 +14,9 @@ import {resolveForwardRef} from './forward_ref'; import {InjectionToken} from './injection_token'; import {INJECTOR, Injector, NullInjector, THROW_IF_NOT_FOUND, USE_VALUE} from './injector'; import {inject, injectArgs, setCurrentInjector} from './injector_compatibility'; -import {ClassProvider, ConstructorProvider, ExistingProvider, FactoryProvider, InjectFlags, InjectableDef, InjectableType, InjectorType, InjectorTypeWithProviders, Provider, StaticClassProvider, StaticProvider, TypeProvider, ValueProvider, getInjectableDef, getInjectorDef} from './interface'; +import {InjectableDef, InjectableType, InjectorType, InjectorTypeWithProviders, getInjectableDef, getInjectorDef} from './interface/defs'; +import {InjectFlags} from './interface/injector'; +import {ClassProvider, ConstructorProvider, ExistingProvider, FactoryProvider, StaticClassProvider, StaticProvider, TypeProvider, ValueProvider} from './interface/provider'; import {APP_ROOT} from './scope'; diff --git a/packages/core/src/di/reflective_injector.ts b/packages/core/src/di/reflective_injector.ts index 76ee5b811d..8ce87b226f 100644 --- a/packages/core/src/di/reflective_injector.ts +++ b/packages/core/src/di/reflective_injector.ts @@ -7,7 +7,7 @@ */ import {Injector, THROW_IF_NOT_FOUND} from './injector'; -import {Provider} from './interface'; +import {Provider} from './interface/provider'; import {Self, SkipSelf} from './metadata'; import {cyclicDependencyError, instantiationError, noProviderError, outOfBoundsError} from './reflective_errors'; import {ReflectiveKey} from './reflective_key'; diff --git a/packages/core/src/di/reflective_provider.ts b/packages/core/src/di/reflective_provider.ts index 28a4248f4c..f9a8c26e7b 100644 --- a/packages/core/src/di/reflective_provider.ts +++ b/packages/core/src/di/reflective_provider.ts @@ -11,7 +11,7 @@ import {reflector} from '../reflection/reflection'; import {resolveForwardRef} from './forward_ref'; import {InjectionToken} from './injection_token'; -import {ClassProvider, ExistingProvider, FactoryProvider, Provider, TypeProvider, ValueProvider} from './interface'; +import {ClassProvider, ExistingProvider, FactoryProvider, Provider, TypeProvider, ValueProvider} from './interface/provider'; import {Inject, Optional, Self, SkipSelf} from './metadata'; import {invalidProviderError, mixingMultiProvidersWithRegularProvidersError, noAnnotationError} from './reflective_errors'; import {ReflectiveKey} from './reflective_key'; diff --git a/packages/core/src/di/util.ts b/packages/core/src/di/util.ts index 40f7c9e1ac..de0294beb7 100644 --- a/packages/core/src/di/util.ts +++ b/packages/core/src/di/util.ts @@ -11,7 +11,7 @@ import {ReflectionCapabilities} from '../reflection/reflection_capabilities'; import {getClosureSafeProperty} from '../util/property'; import {inject, injectArgs} from './injector_compatibility'; -import {ClassSansProvider, ConstructorSansProvider, ExistingSansProvider, FactorySansProvider, StaticClassSansProvider, ValueProvider, ValueSansProvider} from './interface'; +import {ClassSansProvider, ConstructorSansProvider, ExistingSansProvider, FactorySansProvider, StaticClassSansProvider, ValueProvider, ValueSansProvider} from './interface/provider'; const USE_VALUE = getClosureSafeProperty({provide: String, useValue: getClosureSafeProperty}); diff --git a/packages/core/src/render3/interfaces/injector.ts b/packages/core/src/render3/interfaces/injector.ts index 3fb9533d72..f93fd5f18a 100644 --- a/packages/core/src/render3/interfaces/injector.ts +++ b/packages/core/src/render3/interfaces/injector.ts @@ -7,7 +7,7 @@ */ import {InjectionToken} from '../../di/injection_token'; -import {InjectFlags} from '../../di/interface'; +import {InjectFlags} from '../../di/interface/injector'; import {Type} from '../../interface/type'; import {TElementNode} from './node'; diff --git a/packages/core/src/render3/ng_module_ref.ts b/packages/core/src/render3/ng_module_ref.ts index 4607cf78e3..17727997c3 100644 --- a/packages/core/src/render3/ng_module_ref.ts +++ b/packages/core/src/render3/ng_module_ref.ts @@ -7,7 +7,8 @@ */ import {INJECTOR, Injector} from '../di/injector'; -import {InjectFlags, StaticProvider} from '../di/interface'; +import {InjectFlags} from '../di/interface/injector'; +import {StaticProvider} from '../di/interface/provider'; import {createInjector} from '../di/r3_injector'; import {Type} from '../interface/type'; import {ComponentFactoryResolver as viewEngine_ComponentFactoryResolver} from '../linker/component_factory_resolver'; diff --git a/packages/core/src/view/refs.ts b/packages/core/src/view/refs.ts index 6c4b2e0b90..6253f93f52 100644 --- a/packages/core/src/view/refs.ts +++ b/packages/core/src/view/refs.ts @@ -9,7 +9,7 @@ import {ApplicationRef} from '../application_ref'; import {ChangeDetectorRef} from '../change_detection/change_detection'; import {Injector} from '../di/injector'; -import {InjectFlags} from '../di/interface'; +import {InjectFlags} from '../di/interface/injector'; import {Type} from '../interface/type'; import {ComponentFactory, ComponentRef} from '../linker/component_factory'; import {ComponentFactoryBoundToModule, ComponentFactoryResolver} from '../linker/component_factory_resolver';