why not just
find . -not -iwholename '*.svn*'
The -not predicate negates everything that has .svn anywhere in the path.
So in your case it would be
find -not -iwholename '*.svn*' -name 'messages.*' -exec grep -Iw uint {} + \;
As follows:
find . -path '*/.svn*' -prune -o -print
Or, alternatively based on a directory and not a path prefix:
find . -name .svn -a -type d -prune -o -print
For searching, can I suggest you look at ack ? It's a source-code aware find, and as such will automatically ignore many file types, including source code repository info such as the above.
find