feat(di): Add the @Injectable annotation to Compiler

Mark `Compiler` and its dependencies as available to the `Injector`.
This commit is contained in:
Tim Blasi
2015-03-16 14:44:14 -07:00
committed by Misko Hevery
parent b656f63430
commit 57723e1354
18 changed files with 40 additions and 1 deletions

View File

@ -1,3 +1,4 @@
import {Injectable} from 'angular2/di';
import {List, ListWrapper, SetWrapper} from "angular2/src/facade/collection";
import {int, NumberWrapper, StringJoiner, StringWrapper} from "angular2/src/facade/lang";
@ -8,6 +9,7 @@ export const TOKEN_TYPE_STRING = 4;
export const TOKEN_TYPE_OPERATOR = 5;
export const TOKEN_TYPE_NUMBER = 6;
@Injectable()
export class Lexer {
text:string;
tokenize(text:string):List {

View File

@ -1,3 +1,4 @@
import {Injectable} from 'angular2/di';
import {int, isBlank, isPresent, BaseException, StringWrapper, RegExpWrapper} from 'angular2/src/facade/lang';
import {ListWrapper, List} from 'angular2/src/facade/collection';
import {Lexer, EOF, Token, $PERIOD, $COLON, $SEMICOLON, $LBRACKET, $RBRACKET,
@ -32,6 +33,7 @@ var _implicitReceiver = new ImplicitReceiver();
var INTERPOLATION_REGEXP = RegExpWrapper.create('\\{\\{(.*?)\\}\\}');
var QUOTE_REGEXP = RegExpWrapper.create("'");
@Injectable()
export class Parser {
_lexer:Lexer;
_reflector:Reflector;