HDTenEightyP/NetNews huggingface dataset:
From: bill@cambridge.apple.com (Bill St. Clair)
Newsgroups: comp.lang.lisp.mcl
Subject: Re: screen dump - can MCL call fkeys?
Date: 6 Jan 93 20:36:20 GMT

>Date: Mon, 4 Jan 1993 14:36:09 -0400
>To: info-mcl@cambridge.apple.com, gwer1@cislabs.pitt.edu (Gerhard Werner)
>From: Robert A. Cassels <cassels@cambridge.apple.com>
>X-Sender: cassels@ministry.cambridge.apple.com
>Subject: Re: screen dump
>
>At 10:13 AM 1/4/93 -0500, Gerhard Werner wrote:
>>In the old Allegro Lisp running in operating system 6 versions, one
>>could freeze a picture of the screen for printing, using a program called
>>screendump. How can one copy a picture of the screen running MCL in
>>system 7 ?
>
>In System 7, Command-shift-3 takes a snapshot of the whole screen.  (See
>the "Finder Shortcuts" window, page 5.)  As straz mentioned, there are
>various shareware programs that give more fine-grained control over what's
>in the picture.

>Date: Mon, 4 Jan 93 15:59:29 -0500
>To: straz@cambridge.apple.com (Steve Strassmann)
>From: steele (Oliver Steele)
>X-Sender: steele@cambridge.apple.com
>Subject: Re: screen dump - can MCL call fkeys?
>Cc: bug-mcl
>
>At  1:44 PM 1/4/93 -0500, Steve Strassmann wrote:
>>Can MCL invoke an fkey? If so, how? He can simply call one of the
>>dozen or so screen capture fkeys out there.
>
>Load the FKEY resource, lock it, jsr to it, and release it.

; press-fkey.lisp
;
; Code to invoke an FKEY from MCL.

(defun press-fkey (number)
  (flet ((reserr ()
           (let ((errnum (#_ResError)))
             (unless (eql 0 errnum)
               (ccl::%err-disp errnum)))))
    (let ((resource (#_GetResource :FKEY number)))
      (reserr)
      (when (%null-ptr-p resource)
        (error "No FKEY number ~s" number))
      (#_LoadResource resource)
      (reserr)
      (with-pointers ((p resource))
        (ff-call p)))))

#|
; To take a snapshot of the screen(s) in System 7:
(press-fkey 3)

; The result appears as a TeachText file named "Picture <n>" at
; top level of your system volume. You can use TeachText to copy a
; rectangular region for pasting into any application that supports
; PICT scraps.
|#
From: jwbaxter@halcyon.halcyon.com
Newsgroups: comp.lang.lisp.mcl
Subject: Balloon help descenders missing
Date: 5 Jan 93 07:57:32 GMT

In this sequence:
1. Launch MCL 2.0p1
2. Bring up one of the various dialogs (first seen with the dialog posed by
the Environment... item in the Tools menu)
3. Turn on balloon help.

In help balloons related to the content area of the active MCL window,
descenders are cut off the characters.  Other balloons seem OK.  Line
spacing seems normal, just no descenders.  This condition remains no matter
how often help balloons are turned off and on, once it happens (alternate
possibility:  sufficient usage of Mac heap with balloons off MIGHT cause
something to be purged which would cause the condition to reset).

If a Fred window or the Listener window is foremost when balloon help is
first turned on, help balloons for window content (including the content of
dialog windows) are normal

Mac IIci, 20 meg real memory, 32-bit addressing, System 7.1, QuickTime 1.5.
 Other configuration on request.

Priority:  very low, obviously.  But...when you find it, please let us know
what it is...I'd be very hard pressed to achieve this condition on
"command".

--------------
John W. Baxter   jwbaxter@halcyon.com   [BAXTER.JOHN on AppleLink, from
AppleLink only.]
From: tcf9033@venus.tamu.edu (FREY, TONY C)
Newsgroups: comp.lang.lisp
Subject: Lisp Interpreter source code?
Date: 6 Jan 1993 17:34 CST
Organization: Texas A&M University, Academic Computing Services
Distribution: world
NNTP-Posting-Host: venus.tamu.edu
News-Software: VAX/VMS VNEWS 1.41    

 Is there source code available (free) for a lisp interpreter? I'd like to
port one to OS/2 but have been unable to find source anywhere.  Any help
would be appreciated. 

Tony Frey
TCF9033@venus.tamu.edu
From: sjameson@atl.ge.com (Stephen M Jameson)
Newsgroups: comp.lang.lisp
Subject: Re: (SETF VALUES)
Date: 11 Jan 93 14:53:37
Organization: GE Advanced Technology Laboratories
	<FY.93Jan6155542@hardwick.lucid.com>
	<SJAMESON.93Jan8084615@fergie.atl.ge.com>
	<1imgf4INNmf@early-bird.think.com>
Reply-To: sjameson@atl.ge.com
NNTP-Posting-Host: retaxes.atl.ge.com
In-reply-to: barmar@think.com's message of 9 Jan 93 12:29:24 GMT

In article <1imgf4INNmf@early-bird.think.com> barmar@think.com (Barry Margolin) writes:
> In article <SJAMESON.93Jan8084615@fergie.atl.ge.com> sjameson@atl.ge.com writes:
> >In article <FY.93Jan6155542@hardwick.lucid.com> fy@lucid.com (Frank Yellin) writes:
> >> >   Is it possible to implement (SETF VALUES) in a Lisp which doesn't
> >> >   already do this?
> >Pardon my ignorance here, but could you explain in what situations one would
> >wish to do this?
> 
> The normal multiple-value assignment operators only allow you to assign to
> variables, but you might want to assign to a set of generalized references.
> Here's a simple, contrived example:
> 
> (defstruct (q-and-r (:conc-name qr-))
>   quotient
>   remainder)
> 
> (defvar *qr* (make-q-and-r))
> ...
> (setf (values (qr-quotient *qr*) (qr-remainder *qr*))
>       (floor numerator denominator))

Thank you, I understand now.  I don't have a Cltl2 or draft standard handy, but
isn't there such a thing as multiple-value-setf which would serve exactly this
purpose? 


> -- 
> Barry Margolin
> System Manager, Thinking Machines Corp.
> 
> barmar@think.com          {uunet,harvard}!think!barmar
--
Steve Jameson                 General Electric Aerospace / Martin Marietta
sjameson@atl.ge.com           Advanced Technology Laboratories
                              Moorestown, New Jersey              
****************************************************************************
**  . . . but I do not love the sword for its sharpness, nor the arrow    **
**  for its swiftness, nor the warrior for his glory.  I love only that   **
**  which they defend . . .                                               **
**    -- Faramir, "The Two Towers"                                        **
****************************************************************************
From: gustav@arp.anu.edu.au (Zdzislaw Meglicki)
Newsgroups: comp.lang.lisp
Subject: The "Series" package
Date: 6 Jan 1993 09:52:05 GMT
Organization: Centre for Information Science Research, ANU, Canberra, Australia
Distribution: world
NNTP-Posting-Host: 150.203.20.14

I've been working with the "Series" package by R. C. Waters for 
the last couple of weeks. In "Common Lisp" Guy Steele writes that
the X3J13 looked at "series" and "generators" briefly in 1989.
It is also mentioned that by the time "Series" has been included in
the Second Edition of the "CL" some 100,000 lines of code have been
written using this package. Since the Second Edition has been published
in 1990 more than 2 years have passed. Could anyone summarise what 
happened to the package and the whole concept since then? In particular,
has X3J13 made any decisions as to the package? Has the package been
put to much use?
-- 
   Zdzislaw Gustav Meglicki, gustav@arp.anu.edu.au,
   Automated Reasoning Program - CISR, and Plasma Theory Group - RSPhysS,
   The Australian National University, G.P.O. Box 4, Canberra, A.C.T., 2601, 
   Australia, fax: (Australia)-6-249-0747, tel: (Australia)-6-249-0158
Newsgroups: comp.lang.lisp
From: marcoxa@maya.CS.nyu.EDU (Marco Antoniotti)
Subject: CL I/O performance (Was: Playing sparcaudio directly from lisp)
Organization: New York University
Date: Fri, 8 Jan 1993 05:11:02 GMT

'(Good morning)

In article <C0IEG8.G5n.1@cs.cmu.edu> mkant+@cs.cmu.edu (Mark Kantrowitz) writes:

   From: mkant+@cs.cmu.edu (Mark Kantrowitz)
   Newsgroups: comp.lang.lisp
   Keywords: Lucid sparcaudio
   Date: 8 Jan 93 00:24:04 GMT
   References: <1993Jan7.210217.21559@cs.cornell.edu>
   Sender: news@cs.cmu.edu (Usenet News System)
   Organization: School of Computer Science, Carnegie Mellon
   Lines: 163
   Nntp-Posting-Host: glinda.oz.cs.cmu.edu

   In article <1993Jan7.210217.21559@cs.cornell.edu> raman@cs.cornell.edu (T. V. Raman) writes:
   >I plan to start using sparc audio extensively inside a clos program,

   I wrote the following code for Allegro CL. As you can see by
   experimentation with the code and variations on it, playing the sound
   files from Lisp is much too slow. Lisp file IO just isn't fast enough.
   If you're going to play sound files, you'll have to do much of the
   work in C, and then use a foreign function interface to run the code. 

This is an interesting remark. I ran through the code and I sincerely
do not understand why a Lisp application should be "slower" doing
IO than a C/C++ application.

As far as my experience is concerned the only "slow" call is the 'elt'
in read-ascii-string. The functions do not seem to cons a lot.

   (defun read-ascii-string (file-stream num-bytes)
     (let ((result (make-string num-bytes)))
       (dotimes (i num-bytes)
	 (setf (elt result i) (code-char (read-byte file-stream))))
       (string-right-trim (list (code-char 0)) result)))

   (defun read-32-bit-integer (file-stream)
     (let ((result 0))
       (dotimes (i 4)
	 (setf result (ash result 8))
	 (incf result (read-byte file-stream)))
       result))

   ;;; (...)

   (defun play-sounds (&optional (sounds '("AA" "r"))
				 &key (blocked nil)
				 (sound-dir *phoneme-directory*)
				 (audio-dev "/dev/audio"))
     (cond (blocked
	    (with-open-file (out *temp-sound-file*
				 :direction :output
				 :if-exists :supersede
				 :if-does-not-exist :create
				 :element-type 'unsigned-byte)
	      (write-sounds sounds sound-dir out))
	    (excl:run-shell-command (format nil "cat ~a > ~a" 
					    *temp-sound-file* audio-dev)))
	   (t
	    (with-open-file (out audio-dev
				 :direction :output
				 :if-exists :overwrite
				 :element-type 'unsigned-byte)
	      (write-sounds sounds sound-dir out)))))


Here is my question. Are there any benchmarks around for I/O done in
CL vs. the usual foes (i.e. C/C++)? I believe this would be another
valuable piece of information regarding CL implementations.

Thanks for your time,
have a nice day

Marco


Newsgroups: comp.lang.lisp
From: irvine@ntmtv.UUCP (Chuck Irvine)
Subject: Re: Symbolics Concordia Question
Organization: Northern Telecom Inc, Mountain View, CA
Date: Fri, 8 Jan 1993 20:35:25 GMT

Speaking of Concordia, I used to work in the Symbolics environment and really 
liked Concordia and the Document Examiner. It is by far the best online
documentation system that I've seen or heard of. Does anybody know if anyone
has ever thought of porting it to other Lisps, e.g. Lucid, Franz, etc.?
Newsgroups: comp.lang.lisp
From: philpot@kepler.arc.nasa.gov (Andrew Philpot)
Subject: (SETF VALUES)
Keywords: setf-methods, setf-expansions, setf, values
Organization: NASA/ARC Information Sciences Division
Date: Wed, 6 Jan 1993 21:31:39 GMT

Is it possible to implement (SETF VALUES) in a Lisp which doesn't
already do this?

This is (will be) part of lisp, e.g., as per section 5.1.2.3 of the
dpans, but my vendor hasn't implemented it yet.

I thought it should be possible, and worked on this awhile, but
couldn't seem to get it to work.  VALUES is "just" a function, after
all, not a special form/special operator.  I don't have a lot of
experience with DEFINE-SETF-METHOD (now DEFINE-SETF-EXPANDER); I don't
think the simpler routes will work (will they?).  I imagine that a
home-brewed version would be less efficient than a built-in one, but
perhaps compile-time transformations could result in pretty good code.

If anyone has done this in a (stock hardware) Lisp, or knows good
reasons why it can or cannot be done, please let me know or post.

Andrew Philpot - "not a rocket scientist"
philpot@ptolemy.arc.nasa.gov
Newsgroups: comp.lang.lisp
From: desmedt@ruls40.LeidenUniv.nl (Koenraad de Smedt)
Subject: Re: Delegation library
Keywords: delegation, prototyping, object-oriented programming
Reply-To: desmedt@ruls40.LeidenUniv.nl (Koenraad de Smedt)
Organization: Leiden University, Netherlands
Date: Fri, 8 Jan 93 12:47:41 GMT

Some people have asked me how CommonORBIT can be obtained.

[Note: one of these people is John Matthews (jm@hpvcljx.vcd.hp.com), but
a message to him bounced; John Matthews, please check your mail system]

The source code of CommonORBIT is in the public domain, but is not
publicly available by means of FTP.  People who are interested are advised to
contact me, and I will send the code by e-mail.

Koenraad de Smedt  (Leiden University)
From: thomas@gmd.de (Tom Gordon, I3.KI 2665)
Subject: Re: Lisp Parsers
Reply-To: thomas@gmd.de
Organization: GMD, Sankt Augustin, Germany.
Date: Tue, 5 Jan 1993 08:11:33 GMT

In article 11586@uqcspe.cs.uq.oz.au, berglas@cs.uq.oz.au (Anthony Berglas) writes:

> God said that f(a, b); is easier
> to read than (f a b), it requires less characters.
> 

I didn't see a smiley, :-), but let's suppose this was intended to be ironic.


> Seriously, (> (+ x 1) (* y 2)) is ugly, and it would be pretty easy
> to add a parser to Lisp that could be used instead of the normal Reader. 

Well, you know what they say about beauty being in the eye of the beholder. 
I, for one, much prefer Lisp/Scheme syntax.  You can't beat it for elegance, which
is why I find it beautiful.  Also, with a good editor (i.e. emacs), selecting
cutting, pasting and formatting s-expressions is so much easier than doing
the same operations on arbitrary blocks and expressions in C.

But these are religious matters, apparently, so I suppose the idea of supporting
alternative surface syntaxes is a good one.  Why not make everyone happy?

> 
> If anyone has heard of such a thing I would be interested to know.
> 

Sorry I can't help you here, but I do know that Apple plans to support an alternative
"algol-like" surface syntax for its new Lisp dialect, Dylan. 

---
Thomas F. Gordon
GMD, FIT; Artificial Intelligence Research Division
5205 Sankt Augustin 1 / Germany
email: thomas.gordon@gmd.de;  phone: (+49 2241) 14-2665
From: ok@csd.cri.dk (Ole Kristensen)
Newsgroups: comp.lang.lisp
Subject: Re: a problem with reading a stream
Date: 11 Jan 93 08:02:51 GMT
Organization: Computer Resources International A/S

grant@pentagon-gw.army.mil (Pete Grant) writes:

>In article <1992Dec27.014528.17943@news.columbia.edu> rs69@cunixb.cc.columbia.edu (Rong Shen) writes:
>>Hi experts:
>>
>>	I am trying to write a function that asks a path to a file
>>from the user and opens the file to read. There is no problem with
>>opening the file, but when it tries to read, the interpreter
>>complains.
>>
>>	Can anyone tell me why?
>>
>>	Thanks very much.
>>
>>--
>>rs69@cunixb.cc.columbia.edu
>>
>>(defun read-path ()
>>  (format t "Enter the path to the file to read, e.g. /tmp/foo/faq.txt")
>>  (setf file-path-name (read-line))
>>  (setf what-stream (open file-path-name :direction :input)) ; ok
>>
>>  (read what-stream nil 'This-is-the-end-of-the-world)) ; This line has error;

>1.  What is the error?  A trip into the debugger?  Returns 'THIS-IS-THE...?

>2.  What's in the file you're trying to read?

>3.  Suggestion:  Although (open ..) works, you should use WITH-OPEN-FILE
>    e.g.,
>    (with-open-file (input file-path-name)
>      (loop as line = (read-line input nil nil)
>            while line
>            do
>        (....)))

>  If you use (OPEN ..), then error off, the stream is left open and can
>prevent you from further attempts to read the file until you explicitly
>close it.  On some machine this can be less than straightforward.  On
>Symbolics you can use (FS:CLOSE-ALL-FILES).

>Pete.



Hi Rong and Pete,

The code shown is sensible to typing errors. If the pathname
does not exist, the listener will just hang. You can test it
by issuing (read NIL NIL 'This-is-the-end). It can be avoided
by something like below:

(defun read-file (pathname)
  (let* ((in-stream (open pathname
                          :direction :input
                          :if-does-not-exist NIL))
         (contents (if in-stream
                       (read in-stream NIL NIL)
                     NIL)))
    (progn
       (if in-stream
           (close in-stream)
         (pprint (list "read-file, no stream" pathname)))
       contents)))


The above function only returns the first S-expression in the file.


Best regards,

Ole

A
A
Newsgroups: comp.lang.lisp
From: barmar@think.com (Barry Margolin)
Newsgroups: comp.lang.lisp
Subject: Re: (SETF VALUES)
Date: 9 Jan 1993 12:29:24 GMT
Organization: Thinking Machines Corporation, Cambridge MA, USA
Distribution: world
NNTP-Posting-Host: gandalf.think.com

In article <SJAMESON.93Jan8084615@fergie.atl.ge.com> sjameson@atl.ge.com writes:
>In article <FY.93Jan6155542@hardwick.lucid.com> fy@lucid.com (Frank Yellin) writes:
>> >   Is it possible to implement (SETF VALUES) in a Lisp which doesn't
>> >   already do this?
>Pardon my ignorance here, but could you explain in what situations one would
>wish to do this?

The normal multiple-value assignment operators only allow you to assign to
variables, but you might want to assign to a set of generalized references.
Here's a simple, contrived example:

(defstruct (q-and-r (:conc-name qr-))
  quotient
  remainder)

(defvar *qr* (make-q-and-r))
...
(setf (values (qr-quotient *qr*) (qr-remainder *qr*))
      (floor numerator denominator))
-- 
Barry Margolin
System Manager, Thinking Machines Corp.

barmar@think.com          {uunet,harvard}!think!barmar
Newsgroups: comp.lang.lisp
From: emcoop@bnr.ca (hume smith)
Subject: Re: Re: Lucid Lisp complains about this code fragment
Organization: Bell-Northern Research, Ottawa, Canada
X-Poster: Emacs-NNTP-0.1
Date: Tue, 5 Jan 1993 14:48:39 GMT

In <1ibjv0INN2pk@early-bird.think.com>, barmar@think.com (Barry Margolin) said:
> In Common
> Lisp, if you don't want TWEAK to be in the global namespace, you should
> write:
> 
> (defun add-noise-to-list-of-numbers (l)
>   (flet ((tweak (x)
>            (+ x
> 	      (- (* (random 1000) .0001) .05))))
>     (mapcar #'tweak l)))

you could also say

(defun add-noise-to-list-of-numbers (l)
  (mapcar #'(lambda (x) (+ x (* (random 1000) .0001) -.05)) l))

but that may be less efficient - for instance, in XLisp, each time
add-noise-to-list-of-numbers is called a new closure is made.  i think.
--
Hume Smith                      Wenn ich des Tages nicht dreimal
hume.smith@acadiau.ca           mein Schaelchen Coffee trinken darf,
emcoop@bnr.ca                   so werd' ich ju zu meiner Qual
                                wie ein verdorrtes Ziegenbraetchen.

Newsgroups: comp.lang.lisp
From: charest@Aig.Jpl.Nasa.Gov (Len Charest)
Subject: AKCL|WCL as translator
Keywords: Lisp to C translation
Reply-To: charest@aig.jpl.nasa.gov
Organization: NASA/Jet Propulsion Laboratory
Date: Tue, 5 Jan 1993 23:36:56 GMT

Has anybody ever tried using either AKCL or WCL as a Lisp-to-C translator? Is it
even possible? 
..................................................
                                  Len Charest, Jr.
                 JPL Artificial Intelligence Group
                          charest@aig.jpl.nasa.gov
From: davis@passy.ilog.fr (Harley Davis)
Newsgroups: comp.lang.lisp
Subject: Re: macro question
Date: 6 Jan 93 09:27:02 GMT
	<CONVERSE.93Jan5225205@sloth.uchicago.edu>
Organization: ILOG S.A., Gentilly, France
In-reply-to: converse@cs.uchicago.edu's message of 6 Jan 93 04:52:05 GMT


In article <CONVERSE.93Jan5225205@sloth.uchicago.edu> converse@cs.uchicago.edu (timoshenko) writes:

   >I would like to define a macro which in turn defines several functions.
   >For example:

   >(defmacro a (x y)
   >  `(defun ,x () (+ 2 2))
   >  `(defun ,y () (* 2 3)))

   >As it stands, the macro only defines the second function, since that is the
   >returned value.  How can I get both functions defined?

   I suppose you could do something like

   (defmacro a (x y)
      `(progn (defun ,x () (+ 2 2))
	      (defun ,y () (* 2 3))))

   This is a macro that expands to an expression that, when evaluated,
   will cause both of the defun forms to be evaluated.  You're right
   that the last form in the defmacro is returned as the expansion, and
   so the first defun in your version above has no effect.

   Why do you want to do this, though?  It's likely to be confusing, 
   both because it's unusual (though legal) to have defun forms that
   aren't top-level, and because this will cause functions to be defined
   without a corresponding explicit defun form in the code.  I suspect
   that there is some better way to do whatever you're trying to do;
   in particular, if you are defining functions that are used only once,
   it would be better to use a lambda-expression than to automatically
   define a named function before calling it.

Your solution is correct, but I don't really understand why you don't
like it.  If all functions "should" be defined by DEFUN, then you are
severely limiting Lisp's potential for higher level syntactic
abstractions based on macros.  For example, you would also have to be
against DEFCLASS forms which define accessor functions since these
function definitions aren't visible directly at the top level.

On the other hand, I would recommend simply as a stylistic guideline
that a macro which defines functions be only used at the top level and
have its name prefixed with DEF.

-- Harley Davis
--

------------------------------------------------------------------------------
nom: Harley Davis			ILOG S.A.
net: davis@ilog.fr			2 Avenue Gallie'ni, BP 85
tel: (33 1) 46 63 66 66			94253 Gentilly Cedex, France
From: barmar@think.com (Barry Margolin)
Newsgroups: comp.lang.lisp
Subject: Re: The "Series" package
Date: 7 Jan 1993 02:52:41 GMT
Organization: Thinking Machines Corporation, Cambridge MA, USA
NNTP-Posting-Host: gandalf.think.com

In article <1iea45INNdvh@manuel.anu.edu.au> gustav@arp.anu.edu.au (Zdzislaw Meglicki) writes:
>In particular, has X3J13 made any decisions as to the package? 

X3J13 decided that it wasn't in wide enough use at the time to incorporate
into the standard, but we encourage people to use it and implementors to
incorporate it (as a de facto standard extension).
-- 
Barry Margolin
System Manager, Thinking Machines Corp.

barmar@think.com          {uunet,harvard}!think!barmar
Newsgroups: comp.lang.lisp,comp.lang.visual
From: ianst@qdpii.comp.qdpi.oz.au (Ian Staples)
Subject: Re: Assessing a language
Organization: Qld Dept Primary Industries
Date: Wed, 6 Jan 1993 08:11:30 GMT

In article <nharvey.726285592@probitas> nharvey@probitas.cs.utas.edu.au (Nicole Harvey) writes:
>
[Stuff deleted]
>   What things do you expect to be able to write relatively simply using any
>language? I would like to here from people working in all areas. 
                           ^^^^
I would like to see spell checkers that know what they are doing.
But I guess the limitation is in human talent rather than in program
language structure or logic.  Sigh...



-- 
Ian Staples                       | Internet : ianst@qdpii.comp.qdpi.oz.au
c/- P.O. Box 1054,                | Fax      : +61 (0)70 923 593
MAREEBA  Queensland  4880         | Voice    : +61 (0)70 921 555
Australia.                        | Home     : +61 (0)70 924 847