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

Implement foreign objects #4

Open
Javyre opened this issue Jan 28, 2018 · 3 comments
Open

Implement foreign objects #4

Javyre opened this issue Jan 28, 2018 · 3 comments
Assignees
Milestone

Comments

@Javyre
Copy link
Contributor

Javyre commented Jan 28, 2018

I half-wrote a system for foreign object using finalizers but the manual strongly advises against that...

We could try to use scm_gc_malloc() with boxes or something which would be way cleaner...
heres an example usage of scm_gc_malloc() and scm_gc_malloc_pointerless(): https://www.gnu.org/software/guile/manual/guile.html#Creating-Foreign-Objects

@cherryman cherryman added this to the 1.0.0 Release milestone Jan 28, 2018
@Javyre Javyre modified the milestone: 1.0.0 Release Jan 28, 2018
@Javyre Javyre self-assigned this Feb 3, 2018
@Javyre
Copy link
Contributor Author

Javyre commented Feb 3, 2018

According to guile guys, finalizers are fine since we need destructors when dropping rust objects...
Ill start working on the seconds half of the impl

@Javyre
Copy link
Contributor Author

Javyre commented Feb 17, 2018

Well, I successfully implemented foreign objects pretty cleanly with only one slot...
still waiting on response from guile-user: https://lists.gnu.org/archive/html/guile-user/2018-02/msg00003.html

Javyre added a commit that referenced this issue Feb 18, 2018
@Javyre
Copy link
Contributor Author

Javyre commented Feb 18, 2018

Left a lot of the old Typelist code commented out in the commit since I don't know if this is the definitive solution... Still no response from mailing list... 😢

@Javyre Javyre added this to In progress in Initial release Mar 6, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Initial release
  
In progress
Development

No branches or pull requests

2 participants