mirror of
https://github.com/Microsoft/vscode
synced 2024-08-27 21:09:43 +00:00
Fix TS compile errors
This commit is contained in:
parent
bde41475b5
commit
6283645114
|
@ -35,7 +35,7 @@ export class LineStarts {
|
|||
) { }
|
||||
}
|
||||
|
||||
export function createLineStartsFast(str: string, readonly: boolean = true): Uint32Array | number[] {
|
||||
export function createLineStartsFast(str: string, readonly: boolean = true): Uint32Array | Uint16Array | number[] {
|
||||
let r: number[] = [0], rLength = 1;
|
||||
|
||||
for (let i = 0, len = str.length; i < len; i++) {
|
||||
|
|
|
@ -25,7 +25,7 @@ function getDefaultMetadata(topLevelLanguageId: LanguageId): number {
|
|||
) >>> 0;
|
||||
}
|
||||
|
||||
const EMPTY_LINE_TOKENS = new Uint32Array(0);
|
||||
const EMPTY_LINE_TOKENS = (new Uint32Array(0)).buffer;
|
||||
|
||||
class ModelLineTokens {
|
||||
_state: IState;
|
||||
|
|
|
@ -568,7 +568,7 @@ export class SnippetParser {
|
|||
if (marker instanceof Placeholder) {
|
||||
placeholderCount += 1;
|
||||
if (marker.isFinalTabstop) {
|
||||
placeholderDefaultValues.set(0);
|
||||
placeholderDefaultValues.set(0, undefined);
|
||||
} else if (!placeholderDefaultValues.has(marker.index) && marker.children.length > 0) {
|
||||
placeholderDefaultValues.set(marker.index, marker.children);
|
||||
} else {
|
||||
|
|
Loading…
Reference in a new issue