Some new syntax has to be introduced to avoid the warning. Something like:
type
TMyRec = record
record procedure Print;
end;
record procedure TMyRec.Print;
begin
writeln('foo');
end;
thanks,
Dmitry
P.S. this message is not as straight forward as it might seem.
Am 30.12.2013 20:08 schrieb "Marcos Douglas" :
>
> Hi,
>
> I'm using FPC 2.6.2 and {advancedrecords}.
> The compiler shows a warning when I use a record variable. IMO this is
> a bug because record variables need not be initialized, right?
Managed types (strings, interfaces, dynamic arrays) inside
Hello All,
I don't know if I'm the only people having problems with the fp IDE of the rc1 from the win32 package
under winxp 32 bits...
The complier works fine. But when I have an error in the source code of a program, I can't jump to the
location of the error after the compilation attempt us
On Mon, 30 Dec 2013, Torsten Bonde Christiansen wrote:
On 2013-12-30 14:33, Michael Van Canneyt wrote:
On Mon, 30 Dec 2013, Michael Van Canneyt wrote:
On Mon, 30 Dec 2013, Torsten Bonde Christiansen wrote:
Bug reported as:
http://bugs.freepascal.org/view.php?id=25469
Including patch a
On Tue, 31 Dec 2013, Juha Manninen wrote:
On Mon, Dec 30, 2013 at 9:17 PM, Mattias Gaertner
wrote:
if FindInvalidUTF8Character(PChar(Pointer(s)),length(s))<0 then
// UTF-8
Uhhh! I will be totally screwed when I must do a unicode conversion myself.
What was this "PChar(Pointer(s))" again?
On Mon, Dec 30, 2013 at 9:17 PM, Mattias Gaertner
wrote:
> if FindInvalidUTF8Character(PChar(Pointer(s)),length(s))<0 then
> // UTF-8
Uhhh! I will be totally screwed when I must do a unicode conversion myself.
What was this "PChar(Pointer(s))" again? PChar is a pointer, why does
it need a doubl
On 12/30/2013 4:55 AM, Marco van de Voort wrote:
In our previous episode, Michael Van Canneyt said:
procedure t(S : String);
begin
if typeinfo(s)=typeinfo(shortstring) then
Writeln('ShortString')
else
Writeln('Ansistring');
end;
begin
t('');
end.
Thank you, I saved it
On 2013-12-30 14:33, Michael Van Canneyt wrote:
On Mon, 30 Dec 2013, Michael Van Canneyt wrote:
On Mon, 30 Dec 2013, Torsten Bonde Christiansen wrote:
Bug reported as:
http://bugs.freepascal.org/view.php?id=25469
Including patch and program with test.
Thank you, I will have a look ASAP.
On Mon, 30 Dec 2013 19:19:20 +0200
Juha Manninen wrote:
> On Mon, Dec 30, 2013 at 2:35 PM, Marcos Douglas wrote:
> > Is possible to know what string type of a variable (AnsiString,
> > UTF8String, RawByteString, etc)?
>
> When UTF-8 encoded string is stored in AnsiString (as in LCL), this
> tes
Hi,
I'm using FPC 2.6.2 and {advancedrecords}.
The compiler shows a warning when I use a record variable. IMO this is
a bug because record variables need not be initialized, right?
project1.lpr(20,3) Warning: Variable "r" does not seem to be initialized
=== BEGIN ===
program Project1;
{$mode ob
On Mon, Dec 30, 2013 at 2:19 PM, Juha Manninen
wrote:
> On Mon, Dec 30, 2013 at 2:35 PM, Marcos Douglas wrote:
>> Is possible to know what string type of a variable (AnsiString,
>> UTF8String, RawByteString, etc)?
>
> When UTF-8 encoded string is stored in AnsiString (as in LCL), this
> test shou
On Mon, Dec 30, 2013 at 2:35 PM, Marcos Douglas wrote:
> Is possible to know what string type of a variable (AnsiString,
> UTF8String, RawByteString, etc)?
When UTF-8 encoded string is stored in AnsiString (as in LCL), this
test should tell you if it actually is UTF-8 string:
if Length(s) <> UT
On Mon, Dec 30, 2013 at 11:47 AM, Michael Van Canneyt
wrote:
>
>
>>> No. You make a wrong assumption.
>>>
>>> TypeInfo will return the DECLARED type of S.
>>>
>>> Not the type that was actually passed when calling the routine:
>>> That has been converted to the declared type of S by the compiler e
No. You make a wrong assumption.
TypeInfo will return the DECLARED type of S.
Not the type that was actually passed when calling the routine:
That has been converted to the declared type of S by the compiler even
before the routine ShowType is called.
You're right.
Well is there another way
On Mon, Dec 30, 2013 at 11:08 AM, Michael Van Canneyt
wrote:
>
>
> On Mon, 30 Dec 2013, Marcos Douglas wrote:
>
>> On Mon, Dec 30, 2013 at 9:48 AM, Marcos Douglas wrote:
>>>
>>> On Mon, Dec 30, 2013 at 9:41 AM, Michael Van Canneyt
>>> wrote:
On Mon, 30 Dec 2013, Marcos Douglas wro
On Mon, 30 Dec 2013, Marcos Douglas wrote:
On Mon, Dec 30, 2013 at 9:48 AM, Marcos Douglas wrote:
On Mon, Dec 30, 2013 at 9:41 AM, Michael Van Canneyt
wrote:
On Mon, 30 Dec 2013, Marcos Douglas wrote:
Hi,
Is possible to know what string type of a variable (AnsiString,
UTF8String, RawB
On 2013-12-30 14:33, Michael Van Canneyt wrote:
On Mon, 30 Dec 2013, Michael Van Canneyt wrote:
On Mon, 30 Dec 2013, Torsten Bonde Christiansen wrote:
And if you provide fixes, make sure the testsuite still runs OK.
I am not sure this case was tested at all - should i try
implementing a
On Mon, Dec 30, 2013 at 9:48 AM, Marcos Douglas wrote:
> On Mon, Dec 30, 2013 at 9:41 AM, Michael Van Canneyt
> wrote:
>>
>>
>> On Mon, 30 Dec 2013, Marcos Douglas wrote:
>>
>>> Hi,
>>>
>>> Is possible to know what string type of a variable (AnsiString,
>>> UTF8String, RawByteString, etc)?
>>
>>
On Mon, 30 Dec 2013, Michael Van Canneyt wrote:
On Mon, 30 Dec 2013, Torsten Bonde Christiansen wrote:
And if you provide fixes, make sure the testsuite still runs OK.
I am not sure this case was tested at all - should i try implementing a
new test or just advide what must
be tested. I a
On Mon, 30 Dec 2013, Torsten Bonde Christiansen wrote:
And if you provide fixes, make sure the testsuite still runs OK.
I am not sure this case was tested at all - should i try implementing a
new test or just advide what must
be tested. I ask because i'm not at all familiar with the testing
On 2013-12-30 13:26, Michael Van Canneyt wrote:
On Mon, 30 Dec 2013, Torsten Bonde Christiansen wrote:
On 2013-12-30 13:01, Michael Van Canneyt wrote:
On Mon, 30 Dec 2013, Torsten Bonde Christiansen wrote:
On 2013-12-19 21:23, Marco van de Voort wrote:
Hello
We have placed the first re
In our previous episode, Michael Van Canneyt said:
>
> procedure t(S : String);
>
> begin
>if typeinfo(s)=typeinfo(shortstring) then
> Writeln('ShortString')
>else
> Writeln('Ansistring');
> end;
>
> begin
>t('');
> end.
Thank you, I saved it to my obfuscated Pascal mailf
On Mon, Dec 30, 2013 at 9:41 AM, Michael Van Canneyt
wrote:
>
>
> On Mon, 30 Dec 2013, Marcos Douglas wrote:
>
>> Hi,
>>
>> Is possible to know what string type of a variable (AnsiString,
>> UTF8String, RawByteString, etc)?
>
>
> You can try
>
> if TypeInfo(S)=TypeInfo(AnsiString) then
>
> etc.
>
On Mon, 30 Dec 2013, Marcos Douglas wrote:
Hi,
Is possible to know what string type of a variable (AnsiString,
UTF8String, RawByteString, etc)?
You can try
if TypeInfo(S)=TypeInfo(AnsiString) then
etc.
The following program
procedure t(S : String);
begin
if typeinfo(s)=typeinfo(short
Hi,
Is possible to know what string type of a variable (AnsiString,
UTF8String, RawByteString, etc)?
Eg:
=== BEGIN ===
procedure foo(s: string);
begin
// if S is AnsiString then do something;
// if S is UTF8String then do something;
end;
var
AStr: AnsiString;
U8Str: UTF8String;
foo(ASt
On Mon, 30 Dec 2013, Torsten Bonde Christiansen wrote:
On 2013-12-30 13:01, Michael Van Canneyt wrote:
On Mon, 30 Dec 2013, Torsten Bonde Christiansen wrote:
On 2013-12-19 21:23, Marco van de Voort wrote:
Hello
We have placed the first release candidate of the Free Pascal Compiler
versi
On 2013-12-30 13:01, Michael Van Canneyt wrote:
On Mon, 30 Dec 2013, Torsten Bonde Christiansen wrote:
On 2013-12-19 21:23, Marco van de Voort wrote:
Hello
We have placed the first release candidate of the Free Pascal Compiler
version 2.6.4 on our ftp servers.
You can help improve the upco
On Mon, 30 Dec 2013, Torsten Bonde Christiansen wrote:
On 2013-12-19 21:23, Marco van de Voort wrote:
Hello
We have placed the first release candidate of the Free Pascal Compiler
version 2.6.4 on our ftp servers.
You can help improve the upcoming 2.6.4 release by downloading and
testing thi
On 2013-12-30 12:54, Torsten Bonde Christiansen wrote:
On 2013-12-19 21:23, Marco van de Voort wrote:
Hello
We have placed the first release candidate of the Free Pascal Compiler
version 2.6.4 on our ftp servers.
You can help improve the upcoming 2.6.4 release by downloading and
testing this r
On 2013-12-19 21:23, Marco van de Voort wrote:
Hello
We have placed the first release candidate of the Free Pascal Compiler
version 2.6.4 on our ftp servers.
You can help improve the upcoming 2.6.4 release by downloading and
testing this release. If you want you can report what you have done he
30 matches
Mail list logo