Newsgroups: | comp.compilers |
From: | pardo@cs.washington.edu (David Keppel) |
Keywords: | polymorphism |
Organization: | University of Washington, Computer Science, Seattle |
References: | <8133@amelia.nas.nasa.gov> |
Date: | 7 Sep 90 17:01:04 GMT |
>[Ongoing discussion of polymorphism & overloading.]
Given two uses (`T' denotes type):
func (T) -> T
func (T, T) -> T
is `func' overloaded, polymorphic, or neither? Note that the
parameter types do not change but that the typ signature of the whole
call does change. Does the O/P/N status depend on whether the
specification is
func (T: x) -> T { ... }
func (T: x, T: y) -> T { ... }
or
func (T: x, optional T: y) -> T { ... }
?
Ada allows default parameters, while some LISPs allow both defaults
and genuinely optional parmaeters. Does that make a difference?
;-D on ( And is Eiffel's `feature' a documented bug? ) Pardo
--
pardo@cs.washington.edu
{rutgers,cornell,ucsd,ubc-cs,tektronix}!uw-beaver!june!pardo
--
Return to the
comp.compilers page.
Search the
comp.compilers archives again.