less hacky impl with specific >> and |> handling
legalize << as STREAM_LEFT, unless it is followed by - in case it is <<- as usual