implement addVariableRef to allow push-reference version of addVariable
(issue #15)