In our previous episode, Michael Van Canneyt said: > > Version A repeats redundant information. Of couse TStack<T> is > > generic, it has those angle brackets after the identifier. They > > wouldn't be legal in a type block unless it was a generic declaration. > > Therefore the word generic is redundant. > > Well, in > > Var > A : Integer; > > The 'Var' is strictly speaking also redundant, as the : is used only in > variable declarations. But the 'var' makes it easier to read, and > Pascal is a verbose language. Additionally, the parsing is easier > to do, as you know what to expect next. By that rationale, the 'generic' > keyword was deemed appropriate when FPC made it's implementation.
(Redundancy plays its main role in case of detecting errors and error-recovery. Both in natural as artificial languages. Errormessage quality is one of the main benefits of FPC/Delphi IMHO ) _______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal