[climacs-devel] cl-automton's automaton objects may print incorrect state numbers

Aleksandar Bakic a_bakic at yahoo.com
Thu Sep 1 22:46:33 UTC 2005


> But why does *print-renumerate-states* only suppress some state numbers?
> In the example with "a.c" the numbers appear.

It does not suppress, it (re)sets state numbers (in a hash-table traversal
order). A couple automaton operators set state numbers, which is exercised by
"a.c". The question is, do you want to reset state numbers for printing
purposes (and perhaps lose debugging information)?

> BTW is there a way to tell SBCL about the terminal? (Latin-1,
> UTF-8 up to a certain limit, Slime connected to Emacs with a given encoding
> running inside a terminal window with certain settings)

I have the following line in my ~/.slime.lisp:

#+sbcl (setq swank::*coding-system* :utf-8-unix)

and this one when I connect from Emacs/SLIME to SBCL:

  (setq slime-net-coding-system 'utf-8-unix)

> It makes more sense to me to have positive variable names, e.g.,
> *escape-unicode-chars* which then would have nil as a default setting
> and which you would set to t while using Slime.

I agree; will fix it some time soon.

> Does *print-renumerate-states* affect automaton-equal too?  To really
> test for equality (maybe "isomorphism" is a better word) you need to pair
> each state in one automaton with a state in the other.  So you won't be
> looking at the individual state numbers, but you will be numbering the pairs,
> in effect.

No, *p-r-s* only affects print-object, but I thought about the issues in
combination. The automaton-equal relies on minimize to produce a pair of
isomorphic automata as inputs, in case they are equivalent (this is an
assumption...; otherwise it would be tough to decide the equivalence; the
minimization algorithms are based on that). There is an auxiliary hash table
(*state-ht*) which is used for pairing the states themselves, not their numbers
(which, in some cases, are never set). Anyway, automaton-equal is used in tests
only.

Alex


		
____________________________________________________
Start your day with Yahoo! - make it your home page 
http://www.yahoo.com/r/hs 
 



More information about the climacs-devel mailing list