From my observation while debugging, local variable inside procedure/functions usually contains garbage value (not initialized).

From: Jürgen Hestermann
Sent: Monday, 9 March 2015 23:30
To: FPC-Pascal users discussions
Reply To: FPC-Pascal users discussions
Subject: [fpc-pascal] Warning "Local variable seems to be not initialized" on dyn array

I get a warning that a local dynamic array variable is not initialized.
Aren't such managed types initialized by default?
On http://wiki.freepascal.org/Dynamic_array it says:

Actually, dynamic arrays are pointers with automatic dereferencing. They are initialized to nil automatically.

So why the warning?

_______________________________________________
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Reply via email to