Re: [cc65] Need to pass drive number in addition to device number to cbm_opendir

From: Ullrich von Bassewitz <uz1musoftware.de>
Date: 2012-05-27 23:38:50
On Sun, May 27, 2012 at 10:27:27AM -0500, Payton Byrd wrote:
>    However, another deficiency in the cbm_opendir method is the lack of
>    ability to apply a filter to the directory.  The drives have very
>    sophisticated pattern matching and it would be a shame to have to
>    duplicate that in code on the computer side.

I wouldn't call the pattern matching "sophisticated", but I see what you mean.

How about

    unsigned char __fastcall__ cbm_opendir2 (unsigned char lfn,
                                             unsigned char device,
                                             const char* name);

where "name" allows one to specify a unit or pattern or whatever? The nice
thing is that cbm_opendir can then be implemented as a simple wrapper that
supplies "$" as a file name.

Changing the argument list of cbm_opendir may also be an option but not a very
attractive one. People will probably kill me, if I do that :-)

Regards


        Uz


-- 
Ullrich von Bassewitz                                  uz@musoftware.de
----------------------------------------------------------------------
To unsubscribe from the list send mail to majordomo@musoftware.de with
the string "unsubscribe cc65" in the body(!) of the mail.
Received on Sun May 27 23:46:34 2012

This archive was generated by hypermail 2.1.8 : 2012-05-27 23:46:37 CEST