I don't see where this is used, but this is too simplistic. This is the parser's responsibility. What if a pipe appears in a literal String?