datReset: For compatibility, must return DAT__ACCON if in wrong mode
dat1NewPrim: Move cparm creation earlier

This makes it simpler to add other creation properties to the
list later without having to move the parameter creation
out the ifdef.
Rewrite handling of primitive STATE

Previously an attribute was used which tracked whether the primitive
had been written to or not. Now the attribute has been removed and
we call H5Dget_space_status directly. This seems to behave in the
same way although datReset is now implemented by deleting the
entire primitive and re-creating it empty.
Test datState