Having arrays indexed by enumerations can be nice.
type
TFoo = (foOne, foTwo, foThree);
const
FooStr: array[TFoo] of string = ('One', 'Two', 'Three');
There's no mucking around with implicit or explicit conversions between integers and enumerations. Similarly, you can enumerate through them easily with standard routines:
var i: TFoo;
{ ... }
for i := Low(TFoo) to High(TFoo) do { etc. }
Doing it in C relies on you adding fake enumeration members to stand for counts; and it gets worse in C++, because enumerations are more reluctant to decompose into integers.
Writing scanners (as in, compiler lexers) in Pascal is very convenient with set notation:
{ skip whitespace }
while cp^ in [#1..#32] do Inc(cp);
With a good debugger, it can be nice to use sets instead of bit flags, because you generally get a more reliable symbolic breakdown.
If you write a lot of code that breaks down in a procedural way, having nested routines is very nice. It can limit the scope of functions and procedures to just the code that needs them. In C, one can be tempted to cram it all into a single long function instead.
Practical Pascals like Turbo Pascal and Delphi have a real live module format that works fairly well for independent compilation. Changes to the interface exported by a unit do not necessarily need all dependent units recompiled. The Pascal linker associates versions with all exported symbols (basically, a hash of their signature), and only units whose import symbol versions don't match the export symbol versions need to be recompiled. This also prevents type mismatches that can (albeit rarely in practice) affect C, where if you change the signature of a function or the type of a variable, and fail to recompile clients, you won't get an error from the linker, because C linkers don't usually encode that info.
Writing scanners (as in, compiler lexers) in Pascal is very convenient with set notation:
With a good debugger, it can be nice to use sets instead of bit flags, because you generally get a more reliable symbolic breakdown.If you write a lot of code that breaks down in a procedural way, having nested routines is very nice. It can limit the scope of functions and procedures to just the code that needs them. In C, one can be tempted to cram it all into a single long function instead.
Practical Pascals like Turbo Pascal and Delphi have a real live module format that works fairly well for independent compilation. Changes to the interface exported by a unit do not necessarily need all dependent units recompiled. The Pascal linker associates versions with all exported symbols (basically, a hash of their signature), and only units whose import symbol versions don't match the export symbol versions need to be recompiled. This also prevents type mismatches that can (albeit rarely in practice) affect C, where if you change the signature of a function or the type of a variable, and fail to recompile clients, you won't get an error from the linker, because C linkers don't usually encode that info.