Remove unused VSHIFT variable
Remove obsolete comment
Fix default value for repchar attribute
Initialize all global variables explicitly

Also mark complicated cases as such