better doc and tests for struct template hash