[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Aldorl] [Axiomdeveloper] "has" and "with" (was curious algebra fa
From: 
Gabriel Dos Reis 
Subject: 
Re: [Aldorl] [Axiomdeveloper] "has" and "with" (was curious algebra failure) 
Date: 
Mon, 13 Aug 2007 12:59:35 0500 (CDT) 
On Mon, 13 Aug 2007, Ralf Hemmecke wrote:
 > The Spad compiler tries to treat category constructors, domain
 > constructors, package constructors, and function calls as uniformly as
 > possible. What I mean by that is that it applies the principle:
 >
 > When calling a function, collect candidates, filter them by
 > applying the criteria that the arguments match the parameter types.
 > And select the best match if possible.

 Oh, I hope that will change. The compiler should *never* have a choice left.
 Either after filtering there remains *exactly* one possibility or the compiler
 should complain.
I believe that is what the Spad compiler does.
 > And that irrespective of whether the arguments are value expressions
 > or domain expressions.

 > By "matching" here, I don't necessarily mean only `pattern matching'.
 > Rather I mean `coercible'. For example an expression of type Integer
 > is coercible to Float because Float exports the following function
 >
 > coerce : Integer > %

 That is exactly what Aldor does *not* do. It never applies "coerce" if one
 doesn't explicitly call for it. At the moment I find Aldor much better in this
 respect. You should consider that some people might implement a function that
 is not a nice "coerce" (although their function carries this name).
I don't think there is anything we can do about that. We can't police
people that name coerce a function that does pretend. Sometimes that is
bad, sometimes that is good.
 Gaby
 Re: [Axiomdeveloper] "has" and "with" (was curious algebra failure), (continued)
 Re: [Axiomdeveloper] "has" and "with" (was curious algebra failure), Ralf Hemmecke, 2007/08/13
 Re: [Aldorl] [Axiomdeveloper] "has" and "with" (was curious algebra failure), Gabriel Dos Reis, 2007/08/13
 Re: [Aldorl] [Axiomdeveloper] "has" and "with" (was curious algebra failure), Ralf Hemmecke, 2007/08/13
 RE: [Aldorl] [Axiomdeveloper] "has" and "with" (was curious algebrafailure), Weiss, Juergen, 2007/08/13
 Re: [Aldorl] [Axiomdeveloper] "has" and "with" (was curious algebra failure), Bill Page, 2007/08/13
 Re: [Aldorl] [Axiomdeveloper] "has" and "with" (was curious algebra failure), Gabriel Dos Reis, 2007/08/13
 Re: [Aldorl] [Axiomdeveloper] "has" and "with" (was curious algebra failure), Bill Page, 2007/08/13
 [Axiomdeveloper] Another strange coercion, Franz Lehner, 2007/08/13
 Re: [Axiomdeveloper] Another strange coercion, Ralf Hemmecke, 2007/08/14
 [Axiomdeveloper] SubDomain in SPAD and not in Aldor, Ralf Hemmecke, 2007/08/16
 Re: [Aldorl] [Axiomdeveloper] "has" and "with" (was curious algebra failure),
Gabriel Dos Reis <=
 Re: [Aldorl] [Axiomdeveloper] "has" and "with" (was curious algebra failure), Ralf Hemmecke, 2007/08/14
 Re: [Aldorl] [Axiomdeveloper] "has" and "with" (was curious algebra failure), Gabriel Dos Reis, 2007/08/14
 Re: [Aldorl] [Axiomdeveloper] "has" and "with" (was curious algebra failure), Martin Rubey, 2007/08/14
 Re: [Aldorl] [Axiomdeveloper] "has" and "with" (was curious algebrafailure), William Sit, 2007/08/14
 Re: [Aldorl] [Axiomdeveloper] "has" and "with" (was curious algebrafailure), Bill Page, 2007/08/14
 Re: [Aldorl] [Axiomdeveloper] "has" and "with" (was curious algebrafailure), Ralf Hemmecke, 2007/08/15
 Re: [Aldorl] [Axiomdeveloper] "has" and "with" (was curious algebrafailure), Martin Rubey, 2007/08/16
 Re: [Aldorl] [Axiomdeveloper] "has" and "with" (was curious algebrafailure), William Sit, 2007/08/16
 [Axiomdeveloper] .spad, .input, .as and autocoercion, Ralf Hemmecke, 2007/08/16
 [Axiomdeveloper] Re: .spad, .input, .as and autocoercion, Gabriel Dos Reis, 2007/08/16