mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-10-01 03:19:31 +02:00
compiler: don't create set constants from arrays with high bound > 255 if elements of array are lower than 255
git-svn-id: trunk@17372 -
This commit is contained in:
parent
1bcc41c8c6
commit
901a9a974e
@ -365,8 +365,7 @@ implementation
|
||||
constsetlo:=tenumdef(def).min;
|
||||
{ for constant set elements, delphi allows the usage of elements of enumerations which
|
||||
have value>255 if there is no element with a value > 255 used }
|
||||
if (maybetruncenumrange) and
|
||||
(m_delphi in current_settings.modeswitches) then
|
||||
if (maybetruncenumrange) then
|
||||
begin
|
||||
if constsethi>255 then
|
||||
constsethi:=255;
|
||||
|
Loading…
Reference in New Issue
Block a user