I get an error with this message
"Exception TEParseError unexpected token in factor Near &".
I use "&" operator to sort a TList. I have to give the address of the function which sorts my list.
The token "&" looks to be not recognized by the jcf.
Is it a work around for this problem?
Thanks in advance
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I get an error with this message
"Exception TEParseError unexpected token in factor Near &".
I use "&" operator to sort a TList. I have to give the address of the function which sorts my list.
The token "&" looks to be not recognized by the jcf.
Is it a work around for this problem?
Thanks in advance
It's possible that there is a problem with this syntax. Can I get a code sample?
The following works fine for me. Is yours more complex?
unit TestAtParam;
interface
implementation
uses Classes;
function aCompare(p1, p2: pointer): integer;
begin
Result := -1;
end;
procedure TestList;
var
myList: TList;
begin
myList := TList.Create();
myList.Sort(@aCompare);
end;