internal/lsp: Make Text in DidSave at *string rather than a string

Fix code.ts to match CL 210780.

Change-Id: Iaaa1f8b78d483e4281e6d513cf4d20ae44e46cb7
Reviewed-on: https://go-review.googlesource.com/c/tools/+/210783
Run-TryBot: Peter Weinberger <pjw@google.com>
Reviewed-by: Rebecca Stambler <rstambler@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
This commit is contained in:
Peter Weinberger 2019-12-10 14:26:03 -05:00
parent 0bd90eac95
commit 1bcf67c9cb
1 changed files with 8 additions and 2 deletions

View File

@ -482,9 +482,15 @@ function goInterface(d: Data, nm: string) {
// There's a difference between a nil Range and a zero Range (at the
// beginning of files)
if (d.name == 'TextDocumentContentChangeEvent' &&
n.name.getText() == 'range')
n.name.getText() == 'range') {
gt = '*' + gt;
if (d.name == 'CodeAction' && n.name.getText() == 'command') gt = '*' + gt;
}
if (d.name == 'CodeAction' && n.name.getText() == 'command') {
gt = '*' + gt;
}
if (d.name == 'DidSaveTextDocumentParams' && n.name.getText() == 'text') {
gt = '*' + gt;
}
ans = ans.concat(`${goName(n.name.getText())} ${gt}`, json, '\n')
};
d.properties.forEach(g)