Find Character Constrained (MEMCHR)

Bound program access

Built-in number for MEMCHR is 22. MEMCHR ( source_string : address of aggregate(*) search_character : signed binary(4) - rightmost byte specifies the search character OR unsigned binary(1) OR aggregate(1) maximum_length : unsigned binary(4) value which specifies the maximum number of characters to search ) : space pointer(16) to the first character in the string that matches the search character. If the character is not found, null pointer value is returned

Description

The string specified by source string is searched for the value specified by search character. The search terminates if the value is found or the number of characters specified by maximum length have been searched. If the value is found, a space pointer to the character is returned. Otherwise, a null pointer value is returned.

If maximum length is 0, a null pointer value is returned.

Authorization Required

Lock Enforcement

Exceptions

06 Addressing

24 Pointer Specification

44 Protection Violation