This aims to address #600, this will raise an exception when a resolved variable contains a reference to the variable.