Refactor visitVariableExpression and existsProperty

...to resolve properties on its own. Also moves the logic for hasSetter into existsProperty and adds additional generics information