From a0ef09293b2717483125ef473661246b84d63348 Mon Sep 17 00:00:00 2001 From: Martin Date: Thu, 23 Mar 2023 21:31:11 +0100 Subject: [PATCH] FpDebug: add intrinsic "len" as shortcut for "length" --- components/fpdebug/fppascalparser.pas | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/components/fpdebug/fppascalparser.pas b/components/fpdebug/fppascalparser.pas index a0fd9e895b..e46333319a 100644 --- a/components/fpdebug/fppascalparser.pas +++ b/components/fpdebug/fppascalparser.pas @@ -3036,7 +3036,10 @@ begin Result := ifErrorNotFound; case ALen of 2: if strlicomp(AStart, 'CC', 2) = 0 then Result := ifChildClass; - 3: if strlicomp(AStart, 'POS', 3) = 0 then Result := ifPos; + 3: case AStart^ of + 'l', 'L': if strlicomp(AStart, 'LEN', 3) = 0 then Result := ifLength; + 'p', 'P': if strlicomp(AStart, 'POS', 3) = 0 then Result := ifPos; + end; 5: case AStart^ of 'l', 'L': if strlicomp(AStart, 'LOWER', 5) = 0 then Result := ifLower; 'u', 'U': if strlicomp(AStart, 'UPPER', 5) = 0 then Result := ifUpper;