File: utils.lisp

package info (click to toggle)
cl-lml2 1.6.6-4.1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, sid
  • size: 184 kB
  • sloc: lisp: 1,316; makefile: 39
file content (32 lines) | stat: -rw-r--r-- 939 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
;;;; -*- Mode: Lisp; Syntax: ANSI-Common-Lisp; Base: 10 -*-
;;;; *************************************************************************
;;;; FILE IDENTIFICATION
;;;;
;;;; Name:          utils.lisp
;;;; Purpose:       General purpose utilities
;;;; Author:        Kevin M. Rosenberg
;;;; Date Started:  June 2002
;;;;
;;;; $Id$
;;;;
;;;; This file, part of LML2, is copyrighted and open-source software.
;;;; Rights of modification and redistribution are in the LICENSE file.
;;;;
;;;; *************************************************************************

(in-package #:lml2)


(defun lml-quit (&optional (code 0))
  "Function to exit the Lisp implementation."
  (kmrcl:quit code))

(defun lml-cwd ()
  "Returns the current working directory."
  (kmrcl:cwd))

(defmacro fformat (stream control-string &rest args)
  (if stream
      `(funcall (formatter ,control-string) ,stream ,@args)
      `(format nil ,control-string ,@args)))