Changeset 4046
- Timestamp:
- 09/25/03 01:07:49 (20 years ago)
- Location:
- trunk/j/src/org/armedbear/lisp
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/j/src/org/armedbear/lisp/Autoload.java
r4033 r4046 3 3 * 4 4 * Copyright (C) 2003 Peter Graves 5 * $Id: Autoload.java,v 1.7 3 2003-09-23 16:32:35piso Exp $5 * $Id: Autoload.java,v 1.74 2003-09-25 01:07:49 piso Exp $ 6 6 * 7 7 * This program is free software; you can redistribute it and/or … … 231 231 autoload("unexport", "PackageFunctions"); 232 232 autoload("unuse-package", "PackageFunctions"); 233 autoload("user-homedir-pathname", "Pathname"); 233 234 autoload(PACKAGE_SYS, "%define-condition", "define_condition"); 234 235 autoload(PACKAGE_SYS, "%defpackage", "PackageFunctions"); -
trunk/j/src/org/armedbear/lisp/Pathname.java
r3894 r4046 3 3 * 4 4 * Copyright (C) 2003 Peter Graves 5 * $Id: Pathname.java,v 1.1 4 2003-09-19 14:44:10piso Exp $5 * $Id: Pathname.java,v 1.15 2003-09-25 01:07:26 piso Exp $ 6 6 * 7 7 * This program is free software; you can redistribute it and/or … … 200 200 } 201 201 }; 202 203 // ### user-homedir-pathname 204 // user-homedir-pathname &optional host => pathname 205 private static final Primitive USER_HOMEDIR_PATHNAME = 206 new Primitive("user-homedir-pathname") 207 { 208 public LispObject execute(LispObject[] args) throws ConditionThrowable 209 { 210 switch (args.length) { 211 case 0: { 212 String s = System.getProperty("user.home"); 213 // For compatibility with SBCL and ACL (and maybe other 214 // Lisps), we want the namestring of a directory to end 215 // with a '/' on Unix. 216 // FIXME Do we need to do something similar on Windows? 217 if (s.startsWith("/") { 218 // Unix. 219 if (!s.endsWith("/")) 220 s = s.concat("/"); 221 } 222 return new Pathname(s); 223 } 224 case 1: 225 return NIL; 226 default: 227 throw new ConditionThrowable(new WrongNumberOfArgumentsException(this)); 228 } 229 } 230 }; 202 231 }
Note: See TracChangeset
for help on using the changeset viewer.