fixed substitution order