Waiting on a Switch to Stop Moving

Intermittent sounds like a floating input and sure enough, we have this:

        digitalWrite(pinList, HIGH);

Which however, doesn't compile in 1.0 and John has correct in his post above. Can you clarify what the latest code is?