File tree Expand file tree Collapse file tree
modules/angular2/src/reflection Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -48,12 +48,21 @@ export class ReflectionCapabilities {
4848 }
4949
5050 _zipTypesAndAnnotaions ( paramTypes , paramAnnotations ) : List < List < any > > {
51- var result = ListWrapper . createFixedSize ( paramTypes . length ) ;
51+ var result ;
52+
53+ if ( typeof paramTypes === 'undefined' ) {
54+ result = ListWrapper . createFixedSize ( paramAnnotations . length ) ;
55+ } else {
56+ result = ListWrapper . createFixedSize ( paramTypes . length ) ;
57+ }
58+
5259 for ( var i = 0 ; i < result . length ; i ++ ) {
5360 // TS outputs Object for parameters without types, while Traceur omits
5461 // the annotations. For now we preserve the Traceur behavior to aid
5562 // migration, but this can be revisited.
56- if ( paramTypes [ i ] != Object ) {
63+ if ( typeof paramTypes === 'undefined' ) {
64+ result [ i ] = [ ] ;
65+ } else if ( paramTypes [ i ] != Object ) {
5766 result [ i ] = [ paramTypes [ i ] ] ;
5867 } else {
5968 result [ i ] = [ ] ;
You can’t perform that action at this time.
0 commit comments