[Gambas-devel] About gb.gsl components

Emil Lenngren emil.lenngren at ...176...
Wed Jul 11 22:06:30 CEST 2012


Next bug:
Public Sub Main()
  Dim a As Object = New Complex(2, 1)
  Dim i As Integer
  For i = 1 To 2
    Print a + 2.0
    a = Me
  Next
End

-> Segmentation fault.

And some questions:
I see that if a class inherits Complex (at least a non-native class), the
operators are also inherited = good.
When I implement this in the JIT, can I assume that child classes do not
override operators, i.e. can I codegen a direct call to the operator (if
the type is a "pure object")? Or do I have to use virtual dispatching?

/Emil

2012/7/10 Randall Morgan <rmorgan62 at ...176...>

> That's great Benoit. I'll need to start reading your code today.
>
>
>
> On Tue, Jul 10, 2012 at 8:26 AM, Benoît Minisini <
> gambas at ...1...> wrote:
>
>> Le 10/07/2012 01:20, Emil Lenngren a écrit :
>> > Ok, that's fine. Tell me when you think the specifications are finished
>> > so I can implement it in the jit.
>> >
>> > /Emil
>> >
>>
>> OK, I think that 'operators on object' is more or less finished.
>>
>> It can handle '+', '-', '*', '/', 'Abs', '=' and '<>' (that are
>> mandatory) and '^' (that is optional).
>>
>> I will have to add the '%' (modulo) operator soon.
>>
>> Regards,
>>
>> --
>> Benoît Minisini
>>
>>
>>
>>
>> ------------------------------------------------------------------------------
>> Live Security Virtual Conference
>> Exclusive live event will cover all the ways today's security and
>> threat landscape has changed and how IT managers can respond. Discussions
>> will include endpoint security, mobile security and the latest in malware
>> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
>> _______________________________________________
>> Gambas-devel mailing list
>> Gambas-devel at lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/gambas-devel
>>
>
>
>
> --
> If you ask me if it can be done. The answer is YES, it can always be done.
> The correct questions however are... What will it cost, and how long will
> it take?
>
>
> ------------------------------------------------------------------------------
> Live Security Virtual Conference
> Exclusive live event will cover all the ways today's security and
> threat landscape has changed and how IT managers can respond. Discussions
> will include endpoint security, mobile security and the latest in malware
> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
> _______________________________________________
> Gambas-devel mailing list
> Gambas-devel at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gambas-devel
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.gambas-basic.org/pipermail/devel/attachments/20120711/3d3311a8/attachment.html>


More information about the Devel mailing list