Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal / 2026-09

is not and not in

1 message · 1 person ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Mattias Gaertner

Hi all,

fpc main now supports "not in" and "is not":

They can be enabled with $modeswitch ReorderedOperators and are enabled by default in mode delphi and delphiunicode.

Examples:

if aControl is not TForm then ...
// instead of
if not (aControl is TForm) then ...

if FormStyle not in [fsMDIForm, fsMDIChild] then ... // instead of
if not (FormStyle in [fsMDIForm, fsMDIChild]) then ...

Mattias