<div dir="ltr"><div>OK, I thought it is effectively the same as overriding a property. I use it also in "real code", where I do not need setter & getters. And yes, I do know the OO philosophy about them, but I disagree. For me it's just huge amount of useless code.</div><div>But yes, I think the compiler should raise error.<br></div><div><br></div><div>Jussi<br></div></div><br><div class="gmail_quote"><div dir="ltr">On Mon, Oct 8, 2018 at 1:51 AM Benoît Minisini <<a href="mailto:g4mba5@gmail.com">g4mba5@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Le 03/10/2018 à 14:25, Jussi Lahtinen a écrit :<br>
> There is the "null object" error, which happens only when JIT is <br>
> enabled. See the attachment.<br>
> <br>
> Jussi<br>
> <br>
<br>
It comes from the fact that a public variable is declared in a child <br>
class with the same name as in the parent class.<br>
<br>
It works by luck in the interpreter, but not in the JIT compiler.<br>
<br>
I think I should forbid that. Having two different variables with the <br>
same name is obviously a design error. It's different from overriding a <br>
method, a property or a constant, which is perfectly useful.<br>
<br>
-- <br>
Benoît Minisini<br>
<br>
----[ Gambas mailing-list is hosted by <a href="https://www.hostsharing.net" rel="noreferrer" target="_blank">https://www.hostsharing.net</a> ]----<br>
</blockquote></div>