summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGraeme Geldenhuys <graeme@mastermaths.co.za>2012-11-30 17:27:50 +0000
committerGraeme Geldenhuys <graeme@mastermaths.co.za>2012-11-30 17:27:50 +0000
commit55938da8020d526f006a93d6fc32ef79d4386362 (patch)
tree07e92ae2c258d878676d2d799ce8f3433d627043
parentd492dd657c85f3d71389f0968e300a045b151dcc (diff)
downloadfpGUI-55938da8020d526f006a93d6fc32ef79d4386362.tar.xz
Silence the compiler about range checking.
We manualy do the range checking before we access the string array. So disable the compiler range checking around the affected code.
-rw-r--r--src/corelib/fpg_stringutils.pas2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/corelib/fpg_stringutils.pas b/src/corelib/fpg_stringutils.pas
index 900ecd2a..1acd518e 100644
--- a/src/corelib/fpg_stringutils.pas
+++ b/src/corelib/fpg_stringutils.pas
@@ -342,7 +342,9 @@ var
begin
if BytePos > 0 then
begin
+ {$R-} { Disable range-check because we do it manually above }
CharLen := UTF8CharacterLength(@s[BytePos]);
+ {$R+}
aChar := Copy(s, BytePos, CharLen);
Result := BytePos + CharLen;
end else