Can it be that there is a spurious {$C-} in your app. That will override the compiler debug settings. I can not reproduce your code.
There is an easy way to test this because assertions are local, so you can do this:
{ This code will override any compiler settings regarding assertions }
{$PUSH}// save state
{$C+}// force assertions on
Assert(Assigned(P), 'P is nil');
{$POP}// restore original settings
This code will override any global settings, just for that piece of code.
Btw: I used trunk from today, i.e. 331/399 on Windows11 and dwarf3 debug settings.
But that should not matter: it always worked.
Let us know if it worked: if it does then it is likely that your code contains a directive that turns the assertions off. Either {$C-} or {$assertions off} or {$assertions-}
But beware of dangling pointers: in that case the assert thinks it is valid because P is not nil...
If that is the case, you have my permission to guard P temporalily with the dreaded FreeAndNil, if applicable, and remove that after you have determined the real cause.
( I am one of those that are of the opinion that FreeAndNil is evil because it can hide hard to debug real errors )
Remark: "Trash variables: checked" makes it likely a var is NOT nil.....
So turn that off. As per documentation its use is limited to special cases, usually to investigate stack corruption.