Skip to content

Commit

Permalink
remove print refs list
Browse files Browse the repository at this point in the history
  • Loading branch information
ftomassetti committed Jul 4, 2023
1 parent 84c65d9 commit f21d1eb
Showing 1 changed file with 0 additions and 25 deletions.
25 changes: 0 additions & 25 deletions core/src/main/kotlin/com/strumenta/kolasu/codegen/PrinterOutput.kt
Original file line number Diff line number Diff line change
Expand Up @@ -168,17 +168,6 @@ class PrinterOutput(
}
}

fun <T : PossiblyNamed> printRefsList(elements: List<ReferenceByName<T>>, separator: String = ", ") {
var i = 0
while (i < elements.size) {
if (i != 0) {
print(separator)
}
print(elements[i].name)
i += 1
}
}

fun <T : Node> printList(
prefix: String,
elements: List<T>,
Expand All @@ -193,20 +182,6 @@ class PrinterOutput(
}
}

fun <T : PossiblyNamed> printRefsList(
prefix: String,
elements: List<ReferenceByName<T>>,
postfix: String,
printEvenIfEmpty: Boolean = false,
separator: String = ", "
) {
if (elements.isNotEmpty() || printEvenIfEmpty) {
print(prefix)
printRefsList(elements, separator)
print(postfix)
}
}

fun printOneOf(vararg alternatives: Node?) {
val notNull = alternatives.filterNotNull()
if (notNull.size != 1) {
Expand Down

0 comments on commit f21d1eb

Please sign in to comment.