Silverfrost Logo About Us | Contact Us
 

ASSOCIATED

Platform

x64, Win32, .NET

Purpose

To determine whether or not a pointer is associated or is associated with a given target.

Class

Inquiry function.

Syntax

LOGICAL FUNCTION ASSOCIATED(POINTER [,TARGET])

Description

POINTER is a pointer of any type whose status has been set as associated or disassociated (not undefined). TARGET is optional and is a pointer or a target. TARGET has the same type, type parameters, and rank as POINTER. If it is a pointer then its status must not be undefined .

Return value

The ISO standard defines the result as:

  1. If TARGET is absent, the result is true if POINTER is currently associated with a target and false if it is not.

  2. If TARGET is present and is a scalar target, the result is true if TARGET is not a zero-sized storage sequence and the target associated with POINTER occupies the same storage units as TARGET. Otherwise, the result is false. If POINTER is disassociated, the result is false.

  3. If TARGET is present and is an array target, the result is true if the target associated with POINTER and TARGET have the same shape, are neither of size zero nor arrays whose elements are zero-sized storage sequences, and occupy the same storage units in array element order. Otherwise, the result is false. If POINTER is disassociated, the result is false.

  4. If TARGET is present and is a scalar pointer, the result is true if the target associated with POINTER and the target associated with TARGET are not zero-sized storage sequences and they occupy the same storage units. Otherwise, the result is false. If either POINTER or TARGET is disassociated, the result is false.

  5. If TARGET is present and is an array pointer, the result is true if the target associated with POINTER and the target associated with TARGET have the same shape, are neither of size zero nor arrays whose elements are zero-sized storage sequences, and occupy the same storage units in array element order. Otherwise, the result is false. If either POINTER or TARGET is disassociated, the result is false.

 

 

Copyright © 1999-2017 Silverfrost Limited