[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Explanation of Octave operator overloading
From: |
John Swensen |
Subject: |
Explanation of Octave operator overloading |
Date: |
Thu, 04 May 2006 13:20:39 -0600 |
User-agent: |
Thunderbird 1.5.0.2 (Windows/20060308) |
Could someone give a quick tutorial on how the operator overloads work
in Octave (and maybe add it as a section in the Da Coda Al Fine section
of the wiki)?
For example, I have defined a new type that derives from
octave_base_value called octave_socket. The problem is that I want to
be able to compare it to numerical values. I have already tried simply
overloading the operator< to compare against octave_value.int_value() as
well as just a plain int.
I see there are a bunch of macros called OCTAVE_INSTALL_*_*_*_CMP_OPS
and assume I have to do something with these, but haven't been able to
figure out what.
Thanks.
John Swensen
- Explanation of Octave operator overloading,
John Swensen <=
Re: Explanation of Octave operator overloading, Paul Thomas, 2006/05/06