That looks good

by qbguy (no login)

So basically OOP is like a FUNCTION in a TYPE.

So you can do functions inside the TYPE which means you can do stuff like array.sum() instead of sum(array()). This makes it pretty easy to understand and you can mark it as private if you want to hide it so that it can only be accessed by other functions in the type. This makes sense to have a function in a type like this because it is simple for people who don't know about OOP to get the syntax. It makes sense for it to be accessible everywhere by default.

Here's how FORTRAN 90 does OOP, since FORTRAN 90 is sort of like QBASIC in syntax:

http://www.owlnet.rice.edu/~mech517/F90_docs/EC_oop_f90.pdf

Posted on Apr 17, 2008, 9:24 AM
from IP address 72.48.236.6

Respond to this message   

Return to Index