🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.emacs.bug
Article #99492

Some minor bugs

#99492
From: David Gillespie
Date: Fri, 31 Aug 1990 07:40
40 lines
1828 bytes
Here are a few bugs I found reading the source to Emacs 18.55.
Let's just say I don't think any aircraft are going to crash because
of these bugs, but I thought I'd mention them.

------

In make-local-variable, the function returns immediately if the variable
has already been made "automatically buffer-local", i.e., by
make-variable-buffer-local.  This is almost right, but there is a
window between the call to make-local-variable and the first setq in
which a setq-default's effect is incorrectly visible.

	(setq foo 'one)
	(make-variable-buffer-local 'foo)
	(make-local-variable 'foo)
	foo  => 'one
	(setq-default foo 'two)
	foo  => 'two    [this is inconsistent]
	(setq foo 'three)
	foo  => 'three
	(setq-default foo 'four)
	foo  => 'three  [correct behavior]

------

The aset function doesn't check the type of the argument to be stored
in a string.  Hey, kids, here's your chance to probe the inner workings
of Emacs pointers!

	(setq foo (make-string 5 ?A))  => "AAAAA"
	(aset foo 2 'not-an-integer)
	foo  => "AAdAA"

------

The function string-to-int is coded and documented as having an optional
second parameter, but max_args is set to 1 so that this argument cannot
be used.

								-- Dave
Technical Details
Message-ID: <9008310740.AA04666@csvax.cs.caltech.edu>
Path: arc1-ca.pugleaf.net!gmdzi!unido!mcsun!uunet!tut.cis.ohio-state.edu!CSVAX.CS.CALTECH.EDU!daveg

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: fb2f1,740930ec93aa18ac,start
X-Google-Attributes: gidfb2f1,public
X-Google-ArrivalTime: 1990-08-31 18:56:30 PST
Path: arc1-ca.pugleaf.net!gmdzi!unido!mcsun!uunet!tut.cis.ohio-state.edu!CSVAX.CS.CALTECH.EDU!daveg
From: daveg@CSVAX.CS.CALTECH.EDU (David Gillespie)
Newsgroups: gnu.emacs.bug
Subject: Some minor bugs
Message-ID: <9008310740.AA04666@csvax.cs.caltech.edu>
Date: 31 Aug 90 07:40:06 GMT
Sender: daemon@tut.cis.ohio-state.edu
Distribution: gnu
Organization: GNUs Not Usenet
Lines: 40
Posted: Fri Aug 31 08:40:06 1990