John Darrington <[EMAIL PROTECTED]> writes: > On Sun, Jun 18, 2006 at 07:22:03PM -0700, Ben Pfaff wrote: > > SORT is kind of a special case. If you just want to sort a > casefile, you can use the sort_execute() function. Pass it a > casereader and some criteria and it'll return a new casefile that > contains the same data sorted according to those criteria. > > Is there a good reason why sort is a special case ? > Could it not be implemented as a procedure like any other ?
Sorting is an operation that lots of code wants to do, so it is separated into a library of its own. SORT CASES is just one of the clients of the sorting code. The sorting library allows it to boil down to just a bit of parsing followed by a single call to sort_active_file_in_place. I imagine that other procedures will want to broken apart this way too. At least, you'll have the choice of either doing that or causing the GUI to emit SPSS syntax that the procedures then consume. I don't know which is the better choice. -- "In the PARTIES partition there is a small section called the BEER. Prior to turning control over to the PARTIES partition, the BIOS must measure the BEER area into PCR[5]." --TCPA PC Specific Implementation Specification _______________________________________________ pspp-dev mailing list [email protected] http://lists.gnu.org/mailman/listinfo/pspp-dev
