Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> comp.databases.theory -> Re: Storing data and code in a Db with LISP-like interface

Re: Storing data and code in a Db with LISP-like interface

From: Alfredo Novoa <alfredo_novoa_at_hotmail.com>
Date: 6 May 2006 05:27:55 -0700
Message-ID: <1146918475.531799.278790@i39g2000cwa.googlegroups.com>

Hi,

Mikito Harakiri wrote:

> How does integer "inherits" arithmetic operations? You need a covariant
> return type:

Integer inherits this:

> +(rational, rational) returns rational

So it is not neccessary to define this:

> +(integer, integer) returns integer

For instance: 2 + 2 returns 4, and 4 is rational and integer.

> But then, you have to redefine arithmetic operations for integers
> anyway. So what is the point of inheritance, then?

You don't have to redefine operations.

Regards
  Alfredo Received on Sat May 06 2006 - 07:27:55 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US