mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-26 09:59:04 +02:00

rtl: add enumerators to the basic classes tests: add enumerators test which compiles and work both by fpc and dcc compiler: + start for-in loop implementation: implement for-in loop for types (enumerations and ranges), strings, arrays and sets. todo: perform type checking, optimize array and string loops - use temp for expression, implement for-in loop for classes test: + add a simple test for the 'for-in' loop compiler: fix string for-in loop. now it uses a temp variable to store string expression result complier: fix for-in array loop. use a temp variable for the loop expression only if loop is not an open array loop complier: continue enumerator implementation: + add operator enumerator which give an ability to add enumerator for an existent type (for example to override builtin string enumerator) + add class enumerator support via delphi compatible GetEnumerator method + enumerator class/object template (function MoveNext: Boolean; property Current) + tests compiler: fix for-in loop for arrays. delphi does not copy arrays to a temp variable and it is possible to change array during loop. + test compiler: add reference for the enumerator operator when it is used + another test for operator enumerator for a class compiler: add reference for the enumerator operator when it is used + another test for operator enumerator for a class compiler: enumerator directive support: + allow to mark methods and properties by 'enumerator MoveNext' and 'enumerator Current' modifiers. Parser checks return types and duplicates. + prefer *marked* by enumerator directive methods and properties than GetEnumerator and Current builtin symbols + increase ppu version + test rtl: add IEnumerator and IEnumerable interfaces declarations tests: for-in loop tests: + add small comment at the top of test program compiler: allow 'enumerator MoveNext' for the interface function declaration + test compiler: move all for-in loop helpers to the nflw unit compiler: don't allow the compiler to choose the non-valid enumerator operator for the for-in loop git-svn-id: trunk@14008 -
82 lines
2.5 KiB
XML
82 lines
2.5 KiB
XML
<?xml version="1.0"?>
|
|
<CONFIG>
|
|
<ProjectOptions>
|
|
<PathDelim Value="\"/>
|
|
<Version Value="7"/>
|
|
<General>
|
|
<Flags>
|
|
<MainUnitHasUsesSectionForAllUnits Value="False"/>
|
|
<MainUnitHasCreateFormStatements Value="False"/>
|
|
<MainUnitHasTitleStatement Value="False"/>
|
|
<LRSInOutputDirectory Value="False"/>
|
|
</Flags>
|
|
<SessionStorage Value="InProjectDir"/>
|
|
<MainUnit Value="0"/>
|
|
<TargetFileExt Value=".exe"/>
|
|
<Title Value="pp"/>
|
|
</General>
|
|
<PublishOptions>
|
|
<Version Value="2"/>
|
|
<IncludeFileFilter Value="*.(pas|pp|inc|lfm|lpr|lrs|lpi|lpk|sh|xml)"/>
|
|
<ExcludeFileFilter Value="*.(bak|ppu|ppw|o|so);*~;backup"/>
|
|
</PublishOptions>
|
|
<RunParams>
|
|
<local>
|
|
<FormatVersion Value="1"/>
|
|
<CommandLineParams Value="-MObjFPC -Scgi -O1 -gl -vewnhi -l -FuC:\programming\mytest\fpctest\enumerators\ -Fu. -FUC:\programming\mytest\fpctest\enumerators\lib\i386-win32\ -oproject1.exe C:\programming\mytest\fpctest\enumerators\tforin1.pp"/>
|
|
<LaunchingApplication PathPlusParams="/usr/X11R6/bin/xterm -T 'Lazarus Run Output' -e $(LazarusDir)/tools/runwait.sh $(TargetCmdLine)"/>
|
|
</local>
|
|
</RunParams>
|
|
<Units Count="2">
|
|
<Unit0>
|
|
<Filename Value="pp.pas"/>
|
|
<IsPartOfProject Value="True"/>
|
|
<UnitName Value="pp"/>
|
|
</Unit0>
|
|
<Unit1>
|
|
<Filename Value="x86\aasmcpu.pas"/>
|
|
<IsPartOfProject Value="True"/>
|
|
<UnitName Value="aasmcpu"/>
|
|
</Unit1>
|
|
</Units>
|
|
</ProjectOptions>
|
|
<CompilerOptions>
|
|
<Version Value="8"/>
|
|
<PathDelim Value="\"/>
|
|
<Target>
|
|
<Filename Value="C:\programming\fpc_features\bin\i386-win32\pp.exe"/>
|
|
</Target>
|
|
<SearchPaths>
|
|
<IncludeFiles Value="i386\"/>
|
|
<OtherUnitFiles Value="i386\;x86\;systems\"/>
|
|
<UnitOutputDirectory Value="i386\lazbuild"/>
|
|
</SearchPaths>
|
|
<Parsing>
|
|
<SyntaxOptions>
|
|
<CStyleOperator Value="False"/>
|
|
<AllowLabel Value="False"/>
|
|
<CPPInline Value="False"/>
|
|
</SyntaxOptions>
|
|
</Parsing>
|
|
<Linking>
|
|
<Debugging>
|
|
<GenerateDebugInfo Value="True"/>
|
|
<UseHeaptrc Value="True"/>
|
|
</Debugging>
|
|
</Linking>
|
|
<Other>
|
|
<Verbosity>
|
|
<ShowWarn Value="False"/>
|
|
<ShowNotes Value="False"/>
|
|
<ShowHints Value="False"/>
|
|
</Verbosity>
|
|
<ConfigFile>
|
|
<StopAfterErrCount Value="50"/>
|
|
</ConfigFile>
|
|
<CustomOptions Value="-di386
|
|
"/>
|
|
<CompilerPath Value="$(CompPath)"/>
|
|
</Other>
|
|
</CompilerOptions>
|
|
</CONFIG>
|