[fpc-devel] new features and facilities

MohsenTi mohsen.timar at gmail.com
Thu Oct 8 17:37:20 CEST 2015


I know this issue but with changing some of structures, I can implement it
and now I only want testing adding features to compiler and don't care
about backward compatibility,just testing.

I added some changes to compiler functions and classes like
pstatmnt.while_statement and nflw.twhilerepeatnode but need more
information about functions and units.

Mohsen Timar

On Thu, Oct 8, 2015 at 6:28 PM, Michael Van Canneyt <michael at freepascal.org>
wrote:

>
>
> On Thu, 8 Oct 2015, Mohsen wrote:
>
> Hi!
>> I wanna add new features and facilities to pascal like while - else, for
>> - else and inline if statement like python.
>>
>> examples
>>
>> ex1:
>>
>> I:=5;
>> while(I>0) do
>>  begin
>>     Write(I);
>>     I:=I-1;
>> end else Write(' While Else ');
>>
>
> This cannot be implemented without breaking the language.
>
> I:=5:
> If (I<5) then
>  while(I>0) do
>   begin
>      Write(I);
>      I:=I-1;
>  end else
>   Write(' While Else ');
>
> Will not work correctly any more if you want to implement your idea.
>
> So this extension is not possible without breaking backwards compatibility.
>
> Michael.
> _______________________________________________
> fpc-devel maillist  -  fpc-devel at lists.freepascal.org
> http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-devel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-devel/attachments/20151008/34e93263/attachment.html>


More information about the fpc-devel mailing list