[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

proposed minor change to var and whatis semantics



in es-0.83, var and whatis, when given a list of variables or commands,
terminate in an exception on the first that is undefined.  i've been
realizing that this is incovenient, and want to change the behavior,
but want people to comment on whether they think this is a good idea.

for var, it seems silly that ``var foo'' produces ``var is undefined''
when the obvious ``var ='' would recreate the current (non-)value.

for symmetry's sake, it makes sense that whatis does not raise an
exception, although the underlying %whatis still has to for internal
reasons, i think.

thus, where the current behavior is

	; whatis foo ls
	foo: No such file or directory
	; var q path
	q is undefined
	; 

it would change to

	; whatis foo ls
	foo: No such file or directory
	/bin/ls
	; var q path
	q = 
	cdpath = '' .. /haahr /haahr/adobe /haahr/src /haahr/me
	; 

i'm very tempted to go ahead with this change, but it's getting to
the point where such things probably shouldn't be done silently
and without comment.

paul