Ugh, as lojic pointed out (thanks for that :)), some sleep-deprived errors in this post. The more correct version:
In ruby, the lack of a ! at the end of a method isn't a guarantee that a function doesn't modiefy state.
And you're right about (+ counter 1). Blindly remembered the example I got in the ruby forum when I was surprised that some method modified state without a warning !.