[CM] Suggested r7rs.scm change for get-environment-variable

Michael Mee mike at eggheadgames.com
Fri Jun 10 23:45:45 PDT 2022


It appears there was a 6 may 22 change to `getenv` to make it more 
compatible with r7rs.

Accordingly, perhaps the current r7rs.scm file can be modified from:

(define (get-environment-variable x)
    (let ((val ((*libc* 'getenv) x)))
      (and (string? val)
       (> (length val) 0)
       val)))

to:

(define get-environment-variable getenv)

I could be missing some subtlety here, but I came across this today and 
thought it best to mention it.

Cheers, Michael

PS: Thanks as always for s7 and the ongoing efforts!


More information about the Cmdist mailing list