Hello Hans,
Tuesday, February 17, 2004, 10:43:41 PM, you wrote:
> Hi-
> Cristiano Duarte wrote:
>>
>>>I still think that interfaces should follow the same behavior as classes
>>>(i.e. if you can override in classes you can override in interfaces),
>>>but I understand that academically this is w
Hi-
Cristiano Duarte wrote:
I still think that interfaces should follow the same behavior as classes
(i.e. if you can override in classes you can override in interfaces),
but I understand that academically this is wrong. Of course overriding
is wrong period, but it's the route you have to take w
Hi Hans,
On Tue, 17 Feb 2004 15:44:38 -0500, Hans Lellelid wrote:
> Ok, I guess that's just how it is in PHP. The only thing I would cling
> to is that this behavior is inconsistent with the way classes behave:
> i.e. you can override a method in a class and the ($obj instanceof
> ParentClass) w
Hi -
Cristiano Duarte wrote:
On Tue, 17 Feb 2004 15:34:11 +, Stephane Drouard wrote:
Hans,
In PHP you are not allowed to explicit overload methods. Ex:
class A {
function x($a1) {}
function x($a1, $a2) {}
}
The function "x" is already defined and explicit overloading is not
On Tue, 17 Feb 2004 15:34:11 +, Stephane Drouard wrote:
Hans,
In PHP you are not allowed to explicit overload methods. Ex:
class A {
function x($a1) {}
function x($a1, $a2) {}
}
The function "x" is already defined and explicit overloading is not
possible, so the code above w
Hello Hans,
Tuesday, February 17, 2004, 2:59:26 PM, you wrote:
> Andi Gutmans wrote:
>> It depends what you call different signature. If you are talking about
>> default arguments, we should consider allowing those as they don't
>> change the isA relationship. However, if you want us to allow
On 17 Feb 2004 at 8:59, Hans Lellelid wrote:
> interface IA {
> function init();
> function doSomething($arg1,$arg2);
> }
>
> interface IB {
> funciton init();
> function doSomething($arg1, $arg2, $arg3, $arg4 = null);
> function doSomethingElse($arg1);
> }
>
> class A implements
== Quote from Hans Lellelid ([EMAIL PROTECTED])'s article
> In more traditional PHP this works fine:
>
> class A {
> function init() { ... }
> function doSomething($arg1, $arg2) { ... }
> }
>
> class B extends A {
> function doSomething($arg1, $arg2, $arg3, $arg4 = null) { ... }
> f
Andi Gutmans wrote:
It depends what you call different signature. If you are talking about
default arguments, we should consider allowing those as they don't
change the isA relationship. However, if you want us to allow
inheriting interfaces which truly differ in function prototypes than
that
It depends what you call different signature. If you are talking about
default arguments, we should consider allowing those as they don't change
the isA relationship. However, if you want us to allow inheriting
interfaces which truly differ in function prototypes than that would
definitely be
Hi -
This issue of inheritance & interfaces persists to give me problems...
Perhaps I'm going about this wrong for PHP.
Zeev Suraski wrote:
You're not supposed to change the signature when you're
extending/implementing interfaces. I'll try to see if it's feasible
to improve the checks so tha
11 matches
Mail list logo