This function updates the object that var refers to. If var is
a pointer, that means this function will update that pointer (or the last
pointer in the chain) to point to the given value object. If var
is not a pointer, the result is the same as a setVar (but without updating
any pointer references, see below).

Note this function only updates the object, it does not
update any associated pointers. So it should probably only be
used internally by husk, unless you really know what you are
doing!