Record which promise set each variable.

Preparation for fixing Redmine 1492: keep track of which Promise set a
variable, so that we can ask whether a later setting is by the same
promise (on a later pass) or a different one; in the former case we'll
always allow this, but the latter is only allowed when policy is free.
Add RvalWriteParts() for when we have only a const pointer for item.

When the item we have is a const void * (or other const pointer), we'd
have to cast away its constness in order to put it into an Rval to
pass to RvalWrite(), despite the fact that RvalWrite() only uses it as
a const pointer.  Also, RvalWrite() delegates unpacking of .item to
functions which do nothing else but check the type is right, which we
know it *is* because our calls to them are in relevant cases of a
switch on type; so we really don't need to pack the item into an Rval.