mirror of
https://gitlab.gnome.org/jwestman/blueprint-compiler.git
synced 2025-05-04 15:59:08 -04:00
Separate output into its own module
This commit is contained in:
parent
8cf793023d
commit
a24f16109f
33 changed files with 407 additions and 291 deletions
|
@ -25,7 +25,7 @@ from .errors import PrintableError, report_bug, MultipleErrors
|
|||
from .lsp import LanguageServer
|
||||
from . import parser, tokenizer, decompiler, interactive_port
|
||||
from .utils import Colors
|
||||
from .xml_emitter import XmlEmitter
|
||||
from .outputs import XmlOutput
|
||||
|
||||
VERSION = "uninstalled"
|
||||
LIBDIR = None
|
||||
|
@ -141,7 +141,9 @@ class BlueprintApp:
|
|||
if len(ast.errors):
|
||||
raise MultipleErrors(ast.errors)
|
||||
|
||||
return ast.generate(), warnings
|
||||
formatter = XmlOutput()
|
||||
|
||||
return formatter.emit(ast), warnings
|
||||
|
||||
|
||||
def main(version, libdir):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue