guile-devel
[Top][All Lists]
Advanced

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

Re: The new class fraction


From: Mikael Djurfeldt
Subject: Re: The new class fraction
Date: Tue, 25 Nov 2003 16:46:18 -0500
User-agent: Gnus/5.1002 (Gnus v5.10.2) Emacs/21.3 (gnu/linux)

Mikael Djurfeldt <address@hidden> writes:

> 2003-11-18  Marius Vollmer  <address@hidden>
>
>       * objects.c (scm_class_fraction): New. 
>
> It is great to have rational numbers in Guile's number tower.
>
> However, why have you chosen the type name "fraction" rather than
> "rational" as is the name used in for example Common Lisp?
>
> I suggest quickly changing the name to <rational> before <fraction>
> sticks.

Hmm... on second consideration.  Probably we should keep <fraction> as
the concrete class representing fractions and introduce the abstract
class <rational>, with subclasses <integer> and <fraction> so that
membership of class <rational> is equivalent to the result of a call
to the predicate rational?.

M




reply via email to

[Prev in Thread] Current Thread [Next in Thread]