Sign in Join
FPDoc Onlineexperiment

StrLScan function

In unit LazStringUtils

Like StrScan but compares only the specified number of characters in MaxLen.

Declaration

pascal
function StrLScan(P: PChar; c: char; MaxLen: Cardinal): PChar

Arguments

P

Pointer to characters examined in the routine.

c

Character to locate in the specified values.

MaxLen

Maximum number of characters examined in the routine.

Function result

Pointer to the character located in P, or Nil.

Description

The return value is Nil when P is unassigned (contains Nil), or when P contains a terminating null character prior to finding a match for c before comparing the requested number of characters in MaxLen.

When c is located in P, the return value is a PChar pointer to the location where c was located.

An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.