Vote UpVote

E2026 or W1023 – take your pick (:

The Wiert Corner – [WayBack] A compiler curiosity I’ve learned today … – David Berneda – Google+: depending on if TEST is defined or not, you get E1026 or W1023. // This works: {$IF Declared(Test) and (Test>=100)} {$ENDIF} // This not: {$IF Declared(Test)} {$IF Test>=100} // "E2026 Constant expression expected" {$ENDIF} {$ENDIF} The W1023 can be alleviated by replacing 100 with +100. Note that both errors have been documented since at least Delphi 2007: [WayBack] W1023: Comparing signed and unsigned types – widened both operands [WayBack] Constant expression expected (E2026) ...
Favorite? Off-Topic? jpluimers @ 2018-08-08 07:04


Visits: 97
Votes: 0
Favorites: 0
Off-Topic: 0

Visits by Source

User Actions

Users who voted for this posting

Contact us to advertise on DelphiFeeds.com

Community Links

Torry Firebird News


Please login or register to use this functionality.
(click on this box to dismiss)