Skip to content
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

box types (do we want those?) #10

Open
nikomatsakis opened this issue Aug 8, 2021 · 2 comments
Open

box types (do we want those?) #10

nikomatsakis opened this issue Aug 8, 2021 · 2 comments

Comments

@nikomatsakis
Copy link
Member

No description provided.

@crlf0710
Copy link

A very aggressive idea on this: Could we decouple types and storage / representation further?

if there's a

class Point(var x, var y)

it says it provides x, y fields following the ownership model.

A boxed version of "Point" provides this, with a heap representation, where these two fields can be accessed from the heap.

An array version of "Point" provides this, where these two fields corresponds to continuous memory.

A json version of "Point" provides this, with a json representation, where these fields are represented within json representation too.

@nikomatsakis
Copy link
Member Author

Neat idea.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants