On Friday 04 November 2005 13:27, Marco van de Voort wrote: ["<>"] > The evil is in > > - using characters instead of modifiers. > - worse, recycling already used characters.
Alright, I completely understand at least the first part, so perhaps they should simply not be overused. :-) Just for the fun and for those who don't know it yet, the previously given example in Ada95-syntax: -- 8< -- snip -- procedure Gen_Test is --------------------------------------------------------------------- package Show is procedure Do_It (i : Integer); procedure Do_It (s : String); end Show; package body Show is procedure Do_It (i : Integer) is begin null; end Do_It; procedure Do_It (s : String) is begin null; end Do_It; end Show; --------------------------------------------------------------------- --------------------------------------------------------------------- generic type T (<>) is private; procedure Dump (Value : T); procedure Dump (Value : T) is use Show; begin Do_It (Value); end Dump; --------------------------------------------------------------------- --------------------------------------------------------------------- procedure My_Dump is new Dump (Integer); procedure My_Dump is new Dump (String); --------------------------------------------------------------------- begin -- Gen_Test My_Dump (42); My_Dump ("foobar"); end Gen_Test;
pgp0x2VjCjF7F.pgp
Description: signature
_______________________________________________ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel