Ah, sorry, I didn't notice that part. It's puzzling that that works when your original attempt (just having the field set itself) didn't, since one would think they would produce the same result. Just another one of InfoPath's quirks.
I suggest using the approach I described because it's guaranteed to present an infinite loop error under any condition. A while back, I discovered that if you have a field set itself to a blank value, it will cause an invinite loop in IP 2010, but not in 2007, so new quirks do have a way of cropping up. My approach should help safeguard against that.