Skip to content

Commit

Permalink
Improve the debug output of generated invokers
Browse files Browse the repository at this point in the history
  • Loading branch information
atrosinenko committed Jan 6, 2024
1 parent bda76ac commit 4cc6d71
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package io.github.atrosinenko.kbdysch.arguments

import io.github.atrosinenko.kbdysch.InvokerConstants._
import io.github.atrosinenko.kbdysch.{Descriptions, SourceFormatter}

final case class Const(value: String, tpe: ArgDescriptionConstructor) extends ArgDescriptionConstructor {
Expand All @@ -20,6 +21,7 @@ private class ConstImpl(value: String, tpe: ArgDescription, val ctx: GenContext)
tpe.requiredLocalVariables()

override def initInstance(formatter: SourceFormatter): Unit = {
formatter.writeLn(s"INVOKER_TRACE(state, $Q Constant: $varName = $value$Q);")
formatter.writeLn(s"$varName = $value;")
}

Expand Down

0 comments on commit 4cc6d71

Please sign in to comment.