[Lazarus] CodeTools error when using 'section' keyword

Michael Ring mail at michael-ring.org
Thu Oct 23 21:57:28 CEST 2014


Unfortunately the fix does not work for me. I still get the same error 
message

I added some debugging:

   //if UpAtomIs('EXTERNAL') then
   //  debugln(['TPascalParserTool.ReadVariableType 
',CurNode.Parent.Parent.DescAsString,' ',CurNode.Parent.DescAsString,' 
',CurNode.DescAsString]);
   //if UpAtomIs('SECTION') then
     debugln(['TPascalParserTool.ReadVariableType 
',CurNode.Parent.Parent.DescAsString,' ',CurNode.Parent.DescAsString,' 
',CurNode.DescAsString]);

when the 'if' line is uncommented I do not get any output.

when it's commented out I see :

TPascalParserTool.ReadVariableType Interface Section Var Section Var
popping up several times.

This is my test program:

program hello;
const
   DEVCFG3_DEFAULT=1;
const
   devcfg3: longWord = DEVCFG3_DEFAULT; section '.devcfg3';
   devcfg2: longWord = DEVCFG3_DEFAULT; section '.devcfg2';

begin
end.

Am 23.10.14 um 09:51 schrieb Mattias Gaertner:
>> Michael Ring <mail at michael-ring.org> hat am 22. Oktober 2014 um 09:38
>> geschrieben:
>>
>>   I did a little digging, Sven is right, this is only for embedded targets; I
>> found the following in systems.pas:
>>
>>          { all embedded systems }
>>          systems_embedded = [system_i386_embedded,system_m68k_embedded,
>>                              system_alpha_embedded,system_powerpc_embedded,
>>                              system_sparc_embedded,system_vm_embedded,
>>                              system_iA64_embedded,system_x86_64_embedded,
>>                              system_mips_embedded,system_arm_embedded,
>>                              system_powerpc64_embedded,system_avr_embedded,
>>                             
>> system_jvm_java32,system_mipseb_embedded,system_mipsel_embedded];
>>
>>          { all systems that allow section directive }
>>          systems_allow_section = systems_embedded;
>>
>>   I found the first occurence of this in the sources of fpc 2.4.0
> Thanks. I added it. Please test.
>
> Mattias
>
> --
> _______________________________________________
> Lazarus mailing list
> Lazarus at lists.lazarus.freepascal.org
> http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus





More information about the Lazarus mailing list