mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-10-28 02:41:31 +01:00
* ppudump: Output the "default" option for properties.
git-svn-id: trunk@26173 -
This commit is contained in:
parent
c952076699
commit
7e8ce16f6b
@ -2509,6 +2509,8 @@ begin
|
|||||||
write ([space,' OverrideProp : ']);
|
write ([space,' OverrideProp : ']);
|
||||||
readderef('');
|
readderef('');
|
||||||
end;
|
end;
|
||||||
|
if ppo_defaultproperty in propoptions then
|
||||||
|
Include(TPpuPropDef(def).Options, poDefault);
|
||||||
write ([space,' Prop Type : ']);
|
write ([space,' Prop Type : ']);
|
||||||
readderef('',TPpuPropDef(def).PropType);
|
readderef('',TPpuPropDef(def).PropType);
|
||||||
writeln([space,' Index : ',getlongint]);
|
writeln([space,' Index : ',getlongint]);
|
||||||
|
|||||||
@ -279,6 +279,9 @@ type
|
|||||||
constructor Create(AParent: TPpuContainerDef); override;
|
constructor Create(AParent: TPpuContainerDef); override;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
TPpuPropOption = (poDefault);
|
||||||
|
TPpuPropOptions = set of TPpuPropOption;
|
||||||
|
|
||||||
{ TPpuPropDef }
|
{ TPpuPropDef }
|
||||||
TPpuPropDef = class(TPpuContainerDef)
|
TPpuPropDef = class(TPpuContainerDef)
|
||||||
protected
|
protected
|
||||||
@ -286,6 +289,7 @@ type
|
|||||||
public
|
public
|
||||||
PropType: TPpuRef;
|
PropType: TPpuRef;
|
||||||
Getter, Setter: TPpuRef;
|
Getter, Setter: TPpuRef;
|
||||||
|
Options: TPpuPropOptions;
|
||||||
constructor Create(AParent: TPpuContainerDef); override;
|
constructor Create(AParent: TPpuContainerDef); override;
|
||||||
destructor Destroy; override;
|
destructor Destroy; override;
|
||||||
end;
|
end;
|
||||||
@ -456,6 +460,9 @@ const
|
|||||||
ObjOptionNames: array[TPpuObjOption] of string =
|
ObjOptionNames: array[TPpuObjOption] of string =
|
||||||
('abstract','copied');
|
('abstract','copied');
|
||||||
|
|
||||||
|
PropOptionNames: array[TPpuPropOption] of string =
|
||||||
|
('default');
|
||||||
|
|
||||||
ArrayOptionNames: array[TPpuArrayOption] of string =
|
ArrayOptionNames: array[TPpuArrayOption] of string =
|
||||||
('dynamic');
|
('dynamic');
|
||||||
|
|
||||||
@ -807,11 +814,20 @@ end;
|
|||||||
{ TPpuPropDef }
|
{ TPpuPropDef }
|
||||||
|
|
||||||
procedure TPpuPropDef.BeforeWriteItems(Output: TPpuOutput);
|
procedure TPpuPropDef.BeforeWriteItems(Output: TPpuOutput);
|
||||||
|
var
|
||||||
|
opt: TPpuPropOption;
|
||||||
begin
|
begin
|
||||||
inherited BeforeWriteItems(Output);
|
inherited BeforeWriteItems(Output);
|
||||||
PropType.Write(Output, 'PropType');
|
PropType.Write(Output, 'PropType');
|
||||||
Getter.Write(Output, 'Getter');
|
Getter.Write(Output, 'Getter');
|
||||||
Setter.Write(Output, 'Setter');
|
Setter.Write(Output, 'Setter');
|
||||||
|
if Options <> [] then begin
|
||||||
|
Output.WriteArrayStart('Options');
|
||||||
|
for opt:=Low(opt) to High(opt) do
|
||||||
|
if opt in Options then
|
||||||
|
Output.WriteStr('', PropOptionNames[opt]);
|
||||||
|
Output.WriteArrayEnd('Options');
|
||||||
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
constructor TPpuPropDef.Create(AParent: TPpuContainerDef);
|
constructor TPpuPropDef.Create(AParent: TPpuContainerDef);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user