replace cse 1*-1*foo detection with working version