def plus
import bolt@1.27.0.0/src/rules/suspicious/concat.bend as Concatimport Base
import bolt@1.27.0.0/src/syntax/tree.bend as Tree
import bolt@1.27.0.0/src/rules/calls.bend as Calls
253# does a parameter's chain open with `+`?
254def plus(pp: Tree.Node) -> Bool:
255 match pp:
256 case Tree.NCons{+h, rest}:
257 Bool.and(Calls.kind.leaf(~Calls.kind.oper, h), String.eq(Calls.leaf.text(h), "+"))
258 case other:
259 False{}