refactor: dart

This commit is contained in:
Victor Berchet
2016-07-30 21:44:04 -07:00
parent 106db0aba8
commit 2dfc9c653b
18 changed files with 8 additions and 411 deletions

View File

@ -9,14 +9,9 @@
import {Injectable} from './di/decorators';
import {print, warn} from './facade/lang';
// Note: Need to rename warn as in Dart
// class members and imports can't use the same name.
let _warnImpl = warn;
@Injectable()
export class Console {
log(message: string): void { print(message); }
// Note: for reporting errors use `DOM.logError()` as it is platform specific
warn(message: string): void { _warnImpl(message); }
warn(message: string): void { warn(message); }
}

View File

@ -884,8 +884,6 @@ export class ComponentMetadata extends DirectiveMetadata implements ComponentMet
* In CommonJS, this can always be set to `module.id`, similarly SystemJS exposes `__moduleName`
* variable within each module.
*
* In Dart, this can be determined automatically and does not need to be set.
*
* ## Simple Example
*

View File

@ -19,8 +19,6 @@ function _reflector(): Reflector {
return reflector;
}
var __unused: Type; // prevent missing use Dart warning.
const _CORE_PLATFORM_PROVIDERS: Array<any|Type|Provider|any[]> = [
PlatformRef_, {provide: PlatformRef, useExisting: PlatformRef_},
{provide: Reflector, useFactory: _reflector, deps: []},