@@ -54,8 +54,8 @@ internal fun <T> List<ParserStructure<T>>.concat(): ParserStructure<T> {
5454 * Merges pending operations (base operations, number span, and unconditional modifications)
5555 * with a simplified parser structure.
5656 *
57- * Invariant: this function should only be called when ` simplifiedParserStructure.operations`
58- * is non-empty. If the structure consists solely of alternatives (empty operations with
57+ * Invariant: this function should only be called when [ simplifiedParserStructure.operations]
58+ * is non-empty. If the structure consists only of alternatives (empty operations with
5959 * non-empty followedBy), this function should NOT be called.
6060 *
6161 * @param baseOperations Operations to prepend (already processed operations from this parser)
@@ -149,7 +149,7 @@ internal fun <T> List<ParserStructure<T>>.concat(): ParserStructure<T> {
149149 // Recursively process alternatives, appending [other] and flattening nested structures
150150 val mergedTails = followedBy.flatMap {
151151 val simplified = it.simplifyAndAppend(other)
152- // parser `ParserStructure(emptyList(), p)` is equivalent to `p`,
152+ // Parser `ParserStructure(emptyList(), p)` is equivalent to `p`,
153153 // unless `p` is empty. For example, ((a|b)|(c|d)) is equivalent to (a|b|c|d).
154154 // As a special case, `ParserStructure(emptyList(), emptyList())` represents a parser that recognizes an empty
155155 // string. For example, (|a|b) is not equivalent to (a|b).
0 commit comments