On Tuesday 19 March 2013 09:06:31 leledumbo wrote: > > Really? No gain in the beloved readability? > > Not for me, I always initialize code in "executable" section, keeping the > declaration section clean. That's what "readable" to me. > > > And it seems to me a "const" should not be changed by code. ;-) > > Even if it's allowed, you're declaring typed constant, which is not a real > constant and has the same effect as initialized variable (e.g. you can > change the value later on). It only differs (from initialized var) when the > assignment happens inside a routine. > Delphi has {$J-} in order to set them readonly. Another problem with Free Pascal in this context is that it is AFAIK not possible to define forward types which could be used as parameters for procedures used as procedure variables in later type definitions.
Martin _______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal