Ada Programming/Attributes/'Has Same Storage
Appearance
Description
[edit | edit source]Returns True if the representation of X2 occupies exactly the same bits as the representation of X and the objects occupy at least one bit.
For a prefix X that denotes an object:
X'Has_Same_Storage denotes a function with the following specification:
function X'Has_Same_Storage (Arg : any_type) return Boolean
The actual parameter shall be a name that denotes an object. The object denoted by the actual parameter can be of any type. This function evaluates the names of the objects involved. It returns True if the representation of the object denoted by the actual parameter occupies exactly the same bits as the representation of the object denoted by X and the objects occupy at least one bit; otherwise, it returns False.
Example
[edit | edit source]X’Has_Same_Storage (X2:any_type) return Boolean