gopls/internal/lsp/protocol/generate: restore indentation
CL 545015 tidied the source-level indentation of the
DocumentURI declaration in the generator, but this
added unwanted indentation in the output (which, for
reasons I still haven't investigated, was not fixed
by the final "go fmt" operation done by the generator).
This change restores the old indentation so that the
output is properly formatted.
Change-Id: Iaa3c0cc3930218f6deed3f6de21dde5a0019aaa8
Reviewed-on: https://go-review.googlesource.com/c/tools/+/546657
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Peter Weinberger <pjw@google.com>
diff --git a/gopls/internal/lsp/protocol/generate/output.go b/gopls/internal/lsp/protocol/generate/output.go
index c81076c..c5e0395 100644
--- a/gopls/internal/lsp/protocol/generate/output.go
+++ b/gopls/internal/lsp/protocol/generate/output.go
@@ -240,32 +240,32 @@
}
// base types
types["DocumentURI"] = `
- // A DocumentURI is the URI of a client editor document.
- //
- // Care should be taken to handle encoding in URIs. For
- // example, some clients (such as VS Code) may encode colons
- // in drive letters while others do not. The URIs below are
- // both valid, but clients and servers should be consistent
- // with the form they use themselves to ensure the other party
- // doesn’t interpret them as distinct URIs. Clients and
- // servers should not assume that each other are encoding the
- // same way (for example a client encoding colons in drive
- // letters cannot assume server responses will have encoded
- // colons). The same applies to casing of drive letters - one
- // party should not assume the other party will return paths
- // with drive letters cased the same as it.
- //
- // file:///c:/project/readme.md
- // file:///C%3A/project/readme.md
- //
- // This is done during JSON unmarshalling;
- // see [DocumentURI.UnmarshalText] for details.
- //
- type DocumentURI string
- `
+// A DocumentURI is the URI of a client editor document.
+//
+// Care should be taken to handle encoding in URIs. For
+// example, some clients (such as VS Code) may encode colons
+// in drive letters while others do not. The URIs below are
+// both valid, but clients and servers should be consistent
+// with the form they use themselves to ensure the other party
+// doesn’t interpret them as distinct URIs. Clients and
+// servers should not assume that each other are encoding the
+// same way (for example a client encoding colons in drive
+// letters cannot assume server responses will have encoded
+// colons). The same applies to casing of drive letters - one
+// party should not assume the other party will return paths
+// with drive letters cased the same as it.
+//
+// file:///c:/project/readme.md
+// file:///C%3A/project/readme.md
+//
+// This is done during JSON unmarshalling;
+// see [DocumentURI.UnmarshalText] for details.
+//
+type DocumentURI string
+`
types["URI"] = `// A URI is an arbitrary URL (e.g. https), not necessarily a file.
- type URI = string
- `
+type URI = string
+`
types["LSPAny"] = "type LSPAny = interface{}\n"
// A special case, the only previously existing Or type