improved inc guard substitution