John Cowan wrote:
Brandon J. Van Every scripsit:

  
The platform specific behavior is in library.scm, buried as a primitive:


(define ##sys#pathname-directory-separator
 (let ([st (software-type)])
   (if (and (eq? 'windows st) (not (eq? (build-platform) 'cygwin)))
   #\\
   #\/) ) )


This is wrong for a URL.  I haven't exactly figured it out, but it 
appears that make-pathname is being used for URL construction, which 
ultimately ends up with system-specific behavior when it shouldn't.  
    

IMHO the Right Thing is to use "/" as the pathname directory separator
in all circumstances.  The Windows kernel has accepted both "/" and "\"
as separators since the dark days of DOS 2.0.  It's true that standard
command-line utilities use "/" for options, and the Open File dialogue
box rejects "/" altogether, but when you pass a pathname to a system
call, having a "/" in it is perfectly okay -- I do it all the time when
running Java programs, since Java has no Cygwin build.
  

I'm not inclined to agree, since I believe I've fixed a fair number of bugs where reversing pathname polarity was in fact required.  What clearly should happen, however, is URLs should be formed with forward slashes.


Cheers,
Brandon Van Every

_______________________________________________
Chicken-users mailing list
[email protected]
http://lists.nongnu.org/mailman/listinfo/chicken-users

Reply via email to