GNU bug report logs -
#10474
Building guile 2.x under mingw + msys
Previous Next
Reported by: Andy Wingo <wingo <at> pobox.com>
Date: Tue, 10 Jan 2012 21:59:02 UTC
Severity: normal
Done: Andy Wingo <wingo <at> pobox.com>
Bug is archived. No further changes may be made.
Full log
Message #80 received at 10474 <at> debbugs.gnu.org (full text, mbox):
Andy Wingo <wingo <at> pobox.com> skribis:
> +(let-syntax ((compile-time-case
> + (lambda (stx)
> + (syntax-case stx ()
> + ((_ exp clauses ...)
> + (let ((val (primitive-eval (syntax->datum #'exp))))
> + (let next-clause ((clauses #'(clauses ...)))
> + (syntax-case clauses (else)
> + (()
> + (syntax-violation 'compile-time-case
> + "all clauses failed to match" stx))
> + (((else form ...))
> + #'(begin form ...))
> + ((((k ...) form ...) clauses ...)
> + (if (memv val (syntax->datum #'(k ...)))
> + #'(begin form ...)
> + (next-clause #'(clauses ...))))))))))))
> + ;; emacs: (put 'compile-time-case 'scheme-indent-function 1)
> + (compile-time-case (system-path-convention)
> + ((posix)
> + (define (path-separator? c)
> + (char=? c #\/))
> +
> + (define path-separator-string "/")
> +
> + (define (absolute-path? path)
> + (string-prefix? "/" path)))
I think we must stick to GNU conventions–i.e., write “file name” when
speaking of the name of a file, as above, and “path” when speaking of a
search path.
This is important here because sooner or later someone will ask about
“path separators” (semicolon vs. colon), not to be confused with file
name or directory separators.
WDYT?
(Yes, there are counter-examples in Guile code, but that’s no excuse. ;-))
> + ((windows)
> + (define (path-separator? c)
> + (or (char=? c #\/)
> + (char=? c #\\)))
> +
> + (define path-separator-string "\\")
> +
> + (define (absolute-path? path)
> + (define (unc-path?)
> + ;; Universal Naming Convention (UNC) paths start with \\, and
> + ;; are always absolute.
> + (string-prefix? "\\\\" path))
What about adding here a link to a page that describes “UNC”?
Otherwise, looks good to me, and it’s great that progress is made on
that front!
Ludo’.
This bug report was last modified 12 years and 93 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.