-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Objects or No Objects #9
Comments
Please define the terms 'record' and 'object' and why they are not the same? Our misunderstandings arise when we have different perspectives on meanings and default semantics. |
Link to potentially relevant discussion? |
If you read the OOHaskell paper you will find that an object is the fixed point of a record. However I in general prefer to separate data and functions. A record is like a namespace, and a value of a record type is a particular implementation or value. In basic terms a record is like a |
@keean wrote:
Are you referring to page 15, where setting the tail to the Unit type? Again this seems to be a conclusion that is specific to Haskell's type system and how you are representing inheritance? And what does inheritance have to do with objects? |
I think we are agreed to have simple objects. No inheritance just interfaces/type classes. Closing as decided. |
You mean no virtual inheritance and no subclassing. But what about typeclass objects? And what about unions being subtypes? I don't think we can nail down those yet? |
I think the conclusion here is we are having objects, which will be at least simple objects. The other things are the subject of other threads, but to cover my thoughts, I don't think we need typeclass objects because we have union types. By no inheritance I mean you cannot extend object A. You can extend a typeclass but that is something different. We have interface inheritance, but not implementation inheritance. |
Discussion about records vs objects
The text was updated successfully, but these errors were encountered: