[Overview][Procedures and functions][Index] | Reference for unit 'strings' (#rtl)

# strcomp

Compare 2 null-terminated strings, case sensitive.

## Declaration

Source position: strings.pp line 49

`function strcomp(`
`str1: pchar;`
`str2: pchar`
`):SizeInt;`

## Description

Compares the null-terminated strings S1 and S2. The result is

- A negative SizeInt when S1<S2.
- 0 when S1=S2.
- A positive SizeInt when S1>S2.

For an example, see StrLComp.

## Errors

None.

## See also

StrLComp |  | Compare limited number of characters of 2 null-terminated strings
StrIComp |  | Compare 2 null-terminated strings, case insensitive.
StrLIComp |  | Compare limited number of characters in 2 null-terminated strings, ignoring case.

Documentation generated on: Feb 26 2014