Copyright (C) 1994, Digital Equipment Corp.
RTTypeFP
provides runtime access to type fingerprints.
\index{fingerprint!of type}
\index{type!fingerprint of}
A type's fingerprint is a 64-bit checksum computed from its declaration.
The probability of distinct types having the same fingerprint is very
small. See the Fingerprint
interface for more details.
Typecodes may vary between executions of a program but fingerprints do not. Fingerprints are portable across multiple runs of a single program and across all programs compiled by the same compiler.
INTERFACERTTypeFP ; IMPORT Fingerprint; FROM RTType IMPORT Typecode; PROCEDURE ToFingerprint(tc: Typecode): Fingerprint.T;
Return the fingerprint corresponding totc
. It is a checked runtime error iftc
is not proper or does not name a traced reference type.
PROCEDURE FromFingerprint(READONLY fp: Fingerprint.T) : Typecode;
Return the typecode that corresponds tofp
. If no such typecode exists, returnsRTType.NoSuchType
.
END RTTypeFP.