diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/ChangeLog | 7 | ||||
-rw-r--r-- | src/boot/tokens.boot | 1 | ||||
-rw-r--r-- | src/interp/nlib.lisp | 12 | ||||
-rw-r--r-- | src/interp/sys-utility.boot | 10 |
4 files changed, 18 insertions, 12 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index 173cc693..3a3cf20a 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,4 +1,9 @@ -2013-05-26 Gabriel Dos Reis <gdr@cse.tamu.edu> +2013-05-26 Gabriel Dos Reis <gdr@integrable-solutions.net> + + * interp/nlib.lisp (MAKE-FULL-NAMESTRING): Move to sys-utility.boot. + Rename to makeFullFilePath. Adjust callers. + +2013-05-26 Gabriel Dos Reis <gdr@integrable-solutions.net> * algebra/boolean.spad.pamphlet (IndexedBits)[<]: Define in Spad. * interp/bits.lisp: Remove. diff --git a/src/boot/tokens.boot b/src/boot/tokens.boot index 8cea63a1..c8b29ebb 100644 --- a/src/boot/tokens.boot +++ b/src/boot/tokens.boot @@ -305,6 +305,7 @@ for i in [ _ ["lowerCase?", "LOWER-CASE-P"], _ ["makeFilePath", "MAKE-PATHNAME"] , _ ["makeSymbol", "INTERN"] , _ + ["mergeFilePaths", "MERGE-PATHNAMES"] , _ ["mkpf", "MKPF"] , _ ["newVector", "MAKE-ARRAY"], _ ["nil" ,NIL ] , _ diff --git a/src/interp/nlib.lisp b/src/interp/nlib.lisp index 7a69738f..317eaf4a 100644 --- a/src/interp/nlib.lisp +++ b/src/interp/nlib.lisp @@ -56,8 +56,7 @@ (get-index-table-from-stream stream) stream))) ((equal (elt (string mode) 0) #\O) - ;;(setq fullname (make-full-namestring (cdr file) 'LISPLIB)) - (setq fullname (make-full-namestring (cdr file) 'NIL)) + (setq fullname (|makeFullFilePath| (cdr file) 'NIL)) (case (|directoryp| fullname) (-1 (|checkMkdir| fullname)) (0 (error (format nil "~s is an existing file, not a library" fullname))) @@ -242,9 +241,6 @@ (putindextable ctable filearg)) -(defun make-full-namestring (filearg &optional (filetype nil)) - (namestring (merge-pathnames (|makeFilename| filearg filetype)))) - (defun get-directory-list (ft) (let ((cd (get-current-directory))) (cond ((member ft '("NRLIB" "DAASE" "EXPOSED") :test #'string=) @@ -271,7 +267,7 @@ (return newfn))) (|probeReadableFile| filename)))) -(defun $FILEP (&rest filearg) (make-full-namestring filearg)) +(defun $FILEP (&rest filearg) (|makeFullFilePath| filearg)) (define-function '$OUTFILEP #'$FILEP) ;;temporary bogus def (defun $findfile (filespec filetypelist) @@ -285,8 +281,8 @@ ;; (rename-file namestring1 namestring2)) (defun $FCOPY (filespec1 filespec2) - (let ((name1 (make-full-namestring filespec1)) - (name2 (make-full-namestring filespec2))) + (let ((name1 (|makeFullFilePath| filespec1)) + (name2 (|makeFullFilePath| filespec2))) (if (library-file name1) (copy-lib-directory name1 name2) (copy-file name1 name2)))) diff --git a/src/interp/sys-utility.boot b/src/interp/sys-utility.boot index 6c7afa17..164b435e 100644 --- a/src/interp/sys-utility.boot +++ b/src/interp/sys-utility.boot @@ -203,12 +203,12 @@ probeReadableFile file == ++ original version returned 0 on success, and 1 on failure ++ ??? fix that to return -1 on failure. $ERASE(:filearg) == - -removeFile MAKE_-FULL_-NAMESTRING filearg + -removeFile makeFullFilePath filearg ++ $REPLACE(filespec1,filespec2) == - $ERASE(filespec1 := MAKE_-FULL_-NAMESTRING filespec1) - renameFile(MAKE_-FULL_-NAMESTRING filespec2, filespec1) + $ERASE(filespec1 := makeFullFilePath filespec1) + renameFile(makeFullFilePath filespec2, filespec1) ++ checkMkdir path == @@ -445,3 +445,7 @@ makeFilename(filearg,filetype==nil) == ft := rest symbolAssoc(filetype,$FILETYPE_-TABLE) or filetype ft = nil => toString filearg strconc(toString filearg,'".",toString ft) + +makeFullFilePath(filearg,filetype==nil) == + filePathString mergeFilePaths makeFilename(filearg,filetype) + |