Make isDefinition required.
For the deprecated getOccurrencesAtPosition, isDefinition is always false.
This commit is contained in:
parent
ac9e617e5e
commit
792b23edc2
|
@ -537,6 +537,7 @@ namespace ts.server {
|
|||
fileName,
|
||||
textSpan: ts.createTextSpanFromBounds(start, end),
|
||||
isWriteAccess: entry.isWriteAccess,
|
||||
isDefinition: false
|
||||
};
|
||||
});
|
||||
}
|
||||
|
|
2
src/server/protocol.d.ts
vendored
2
src/server/protocol.d.ts
vendored
|
@ -308,7 +308,7 @@ declare namespace ts.server.protocol {
|
|||
/**
|
||||
* True if reference is a definition, false otherwise.
|
||||
*/
|
||||
isDefinition?: boolean;
|
||||
isDefinition: boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -1208,7 +1208,7 @@ namespace ts {
|
|||
textSpan: TextSpan;
|
||||
fileName: string;
|
||||
isWriteAccess: boolean;
|
||||
isDefinition?: boolean;
|
||||
isDefinition: boolean;
|
||||
}
|
||||
|
||||
export interface DocumentHighlights {
|
||||
|
@ -5750,7 +5750,8 @@ namespace ts {
|
|||
result.push({
|
||||
fileName: entry.fileName,
|
||||
textSpan: highlightSpan.textSpan,
|
||||
isWriteAccess: highlightSpan.kind === HighlightSpanKind.writtenReference
|
||||
isWriteAccess: highlightSpan.kind === HighlightSpanKind.writtenReference,
|
||||
isDefinition: false
|
||||
});
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue