IMPALA-1350: rework symbol resolution
IMPALA-1350: rework symbol resolution

This passes our current UDF tests, and I manually checked that it
fixes the Impyla issue.

Change-Id: I6591c316e4a479b44057e26bed5892a559edbc85
Reviewed-on: http://gerrit.sjc.cloudera.com:8080/4741
Reviewed-by: Skye Wanderman-Milne <6d4b168ab637b0a20cc9dbf96abb2537f372f946@cloudera.com>
Tested-by: jenkins

placrosse/ImpalaToGo,ImpalaToGo/ImpalaToGo,ImpalaToGo/ImpalaToGo,placrosse/ImpalaToGo,placrosse/ImpalaToGo,placrosse/ImpalaToGo,placrosse/ImpalaToGo,placrosse/ImpalaToGo,ImpalaToGo/ImpalaToGo,ImpalaToGo/ImpalaToGo,ImpalaToGo/ImpalaToGo,ImpalaToGo/ImpalaToGo