small change to diagonal loop