[Gambas-user] Financial program
Rolf Schmidt
rolf.frogs at ...221...
Tue Dec 15 14:30:13 CET 2009
Am Dienstag, 15. Dezember 2009 schrieb Doriano Blengino:
> Jean-Yves F. Barbier ha scritto:
> > Doriano Blengino a écrit :
> > ...
> >
> >> A strongness inherited from pascal... I gave a look to many, countless
> >
> > hmm, I don't think Pascal can define vars as temperature[-10, +50]
>
> What do you mean precisely? Can you define the properties of such variable?
>
> > I'm far from a specialist, as a matter of fact I didn't used OO before
> > (only C and ASM a looong time ago) so the only way I see to make a mix
> > is to call external subroutines through SHELL or EXEC; but if you know
> > other ways, I'm in.
> >
> > I don't wanna end up with terrible hacks, nor spend more time to develop
> > something that already exists in another language: I need it to run the
> > way I want in an easy (and maintenable) way - without headaches...
>
> *That* would be slow, very slooow.
>
> There are "external" declarations in gambas (I was admired when I saw
> them the first time). That should be the way to go. I used them to
> interface the LDAP library, and it worked. But it was a pain to manage
> pointers and memory in gambas, and probably there are several quirks in
> that work. If the python lib is written in C++ instead, then things get
> worse, so an EXEC is simpler for sure (but slow). I insist on the
> slowness because you insisted on that in an earlier mail. If you want to
> process thousands rows from a database, then the exec is guaranteed to
> be out of discussion.
Did you try to use the mp-lib (multi precision) from the gnu project. It is
designed to make math cal the way we learnd at school, so its result are
always correct at any depth of decimal fractions.
I think they have a definition for the data/variables they need for the
calculation. So define variables in their way, is a possibility how to
implement a number class in gambas.
Regards
Rolf
More information about the User
mailing list