copy2symbdel from Unit Strutils generates compiler errror when using compiler directive $codepage
Original Reporter info from Mantis: microtiger
-
Reporter name: alex biasi
Original Reporter info from Mantis: microtiger
- Reporter name: alex biasi
Description:
This compiler error will be generated:
"Got Shortstring, expected Ansistring"
When enabling Ansistring {$H+}, this compiler error is generated:
"Got Program.Ansistring, expected System.Ansistring"
->Same problem with this function from Strutils:
Removeleadingchars
-> No Problem with other functions from Strutils, such as:
Leftstr, Rightstr, Copy2symb, Reversestring
I didn't test other functions.
Steps to reproduce:
{$H+}
{$CODEPAGE cp850}
uses
strutils;
var
a,b: string;
begin
b:='test string';
a:=leftstr(b,10);
a:=copy2symb(b,' ');
a:=copy2symbdel(b,' ');
end.
Mantis conversion info:
- Mantis ID: 23799
- OS: Windows 7
- OS Build: x64
- Platform: Intel
- Version: 2.7.1
- Fixed in version: 3.0.4
- Monitored by: » microtiger (alex biasi), » PaulIsh (Paul Ishenin)
- Target version: 3.0.4