mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2026-02-04 08:54:53 +01:00
+ added directive {$HUGEPOINTERARITHMETICNORMALIZATION} to control the
cs_hugeptr_arithmetic_normalization local setting
+ added the cs_hugeptr_comparison_normalization local setting and corresponding
directive {$HUGEPOINTERCOMPARISONNORMALIZATION} to set it
* the {HUGEPOINTERNORMALIZATION} changed to set both of the huge pointer
normalization settings, according to the specified compiler type ('BORLANDC',
'MICROSOFTC' or 'WATCOMC')
git-svn-id: trunk@28151 -
This commit is contained in:
parent
a3b48b79cb
commit
63305cc2e6
@ -146,7 +146,8 @@ interface
|
||||
cs_zerobasedstrings,
|
||||
{ i8086 specific }
|
||||
cs_force_far_calls,
|
||||
cs_hugeptr_arithmetic_normalization
|
||||
cs_hugeptr_arithmetic_normalization,
|
||||
cs_hugeptr_comparison_normalization
|
||||
);
|
||||
tlocalswitches = set of tlocalswitch;
|
||||
|
||||
|
||||
@ -1573,15 +1573,55 @@ unit scandir;
|
||||
end;
|
||||
|
||||
procedure dir_hugepointernormalization;
|
||||
var
|
||||
hs : string;
|
||||
begin
|
||||
if target_info.system<>system_i8086_msdos then
|
||||
begin
|
||||
Message1(scanner_w_directive_ignored_on_target, 'HUGEPOINTERNORMALIZATION');
|
||||
exit;
|
||||
end;
|
||||
current_scanner.skipspace;
|
||||
hs:=current_scanner.readid;
|
||||
case hs of
|
||||
'BORLANDC':
|
||||
begin
|
||||
recordpendinglocalswitch(cs_hugeptr_arithmetic_normalization,'+');
|
||||
recordpendinglocalswitch(cs_hugeptr_comparison_normalization,'+');
|
||||
end;
|
||||
'MICROSOFTC':
|
||||
begin
|
||||
recordpendinglocalswitch(cs_hugeptr_arithmetic_normalization,'-');
|
||||
recordpendinglocalswitch(cs_hugeptr_comparison_normalization,'-');
|
||||
end;
|
||||
'WATCOMC':
|
||||
begin
|
||||
recordpendinglocalswitch(cs_hugeptr_arithmetic_normalization,'-');
|
||||
recordpendinglocalswitch(cs_hugeptr_comparison_normalization,'+');
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure dir_hugepointerarithmeticnormalization;
|
||||
begin
|
||||
if target_info.system<>system_i8086_msdos then
|
||||
begin
|
||||
Message1(scanner_w_directive_ignored_on_target, 'HUGEPOINTERARITHMETICNORMALIZATION');
|
||||
exit;
|
||||
end;
|
||||
do_localswitch(cs_hugeptr_arithmetic_normalization);
|
||||
end;
|
||||
|
||||
procedure dir_hugepointercomparisonnormalization;
|
||||
begin
|
||||
if target_info.system<>system_i8086_msdos then
|
||||
begin
|
||||
Message1(scanner_w_directive_ignored_on_target, 'HUGEPOINTERCOMPARISONNORMALIZATION');
|
||||
exit;
|
||||
end;
|
||||
do_localswitch(cs_hugeptr_comparison_normalization);
|
||||
end;
|
||||
|
||||
procedure dir_weakpackageunit;
|
||||
begin
|
||||
end;
|
||||
@ -1686,6 +1726,8 @@ unit scandir;
|
||||
AddDirective('HPPEMIT',directive_all, @dir_hppemit);
|
||||
AddDirective('HUGECODE',directive_all, @dir_hugecode);
|
||||
AddDirective('HUGEPOINTERNORMALIZATION',directive_all,@dir_hugepointernormalization);
|
||||
AddDirective('HUGEPOINTERARITHMETICNORMALIZATION',directive_all,@dir_hugepointerarithmeticnormalization);
|
||||
AddDirective('HUGEPOINTERCOMPARISONNORMALIZATION',directive_all,@dir_hugepointercomparisonnormalization);
|
||||
AddDirective('IEEEERRORS',directive_all,@dir_ieeeerrors);
|
||||
AddDirective('IOCHECKS',directive_all, @dir_iochecks);
|
||||
AddDirective('IMAGEBASE',directive_all, @dir_imagebase);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user