File tree 1 file changed +12
-1
lines changed 1 file changed +12
-1
lines changed Original file line number Diff line number Diff line change 1
- /// <reference path="types .ts" />
1
+ /// <reference path="core .ts" />
2
2
3
3
module ts {
4
4
export interface ReferencePathMatchResult {
@@ -575,6 +575,17 @@ module ts {
575
575
return ( < CallExpression > node ) . expression ;
576
576
}
577
577
578
+ function getConstructorWithBody ( member : ClassElement ) : ConstructorDeclaration {
579
+ if ( member . kind === SyntaxKind . Constructor && nodeIsPresent ( ( < ConstructorDeclaration > member ) . body ) ) {
580
+ return < ConstructorDeclaration > member ;
581
+ }
582
+ return undefined ;
583
+ }
584
+
585
+ export function getFirstConstructorWithBody ( node : ClassDeclaration ) : ConstructorDeclaration {
586
+ return forEach ( node . members , getConstructorWithBody ) ;
587
+ }
588
+
578
589
export function isExpression ( node : Node ) : boolean {
579
590
switch ( node . kind ) {
580
591
case SyntaxKind . ThisKeyword :
You can’t perform that action at this time.
0 commit comments