Hide time when reducing by steps

master
Mark 2022-11-12 19:31:12 -08:00
parent da997b80c7
commit 09a389857a
Signed by: Mark
GPG Key ID: AD62BB059C2AAEE4
2 changed files with 15 additions and 8 deletions

View File

@ -196,24 +196,31 @@ class Runner:
]
else:
if not self.step_reduction:
out_text += [
("class:ok", f"Runtime: "),
("class:text", f"{time.time() - start_time:.03f} seconds"),
("class:text", "\n")
]
("class:ok", f"\nExit reason: "),
out_text += [
("class:ok", f"Exit reason: "),
stop_reason.value,
("class:text", "\n"),
("class:ok", f"\nMacro expansions: "),
("class:ok", f"Macro expansions: "),
("class:text", f"{macro_expansions:,}"),
("class:text", "\n"),
("class:ok", f"\nReductions: "),
("class:ok", f"Reductions: "),
("class:text", f"{k:,}\t"),
("class:muted", f"(Limit: {self.reduction_limit:,})")
]
if self.full_expansion:
out_text += [
("class:ok", "\nAll macros have been expanded")
("class:text", "\n"),
("class:ok", "All macros have been expanded")
]
if (

View File

@ -15,7 +15,7 @@ lamb = "lamb_engine:main"
[project]
name = "lamb_engine"
description = "A lambda calculus engine"
version = "1.1.7"
version = "1.1.8"
dependencies = [
"prompt-toolkit==3.0.31",
"pyparsing==3.0.9"