mirror of
https://gitlab.gnome.org/jwestman/blueprint-compiler.git
synced 2025-05-04 15:59:08 -04:00
Apply some of @jwestman's suggestions
This commit is contained in:
parent
455924e22f
commit
f777c531e4
4 changed files with 66 additions and 69 deletions
|
@ -292,18 +292,15 @@ class LanguageServer:
|
|||
return
|
||||
|
||||
try:
|
||||
XmlOutput().emit(open_file.ast)
|
||||
except:
|
||||
printerr(traceback.format_exc())
|
||||
self._send_error(id, ErrorCode.RequestFailed, "Could not compile document")
|
||||
formatted_blp = Format.format(
|
||||
open_file.text,
|
||||
params["options"]["tabSize"],
|
||||
params["options"]["insertSpaces"],
|
||||
)
|
||||
except PrintableError:
|
||||
self._send_error(id, ErrorCode.RequestFailed, "Could not format document")
|
||||
return
|
||||
|
||||
formatted_blp = Format.format(
|
||||
open_file.text,
|
||||
params["options"]["tabSize"],
|
||||
params["options"]["insertSpaces"],
|
||||
)
|
||||
|
||||
lst = []
|
||||
for tag, i1, i2, j1, j2 in SequenceMatcher(
|
||||
None, open_file.text, formatted_blp
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue