ceronman / loxido Goto Github PK
View Code? Open in Web Editor NEWRust implementation of the Lox programming language
License: MIT License
Rust implementation of the Lox programming language
License: MIT License
I read your blog post and and I'm using your unsafe implementation as a reference for my own implementation.
I might be misunderstanding, but wouldn't this particular line just free memory up to the size of a GcObject
(i.e. just the header part of your object) and not the full object?
Line 270 in a605c17
Wouldn't you need to do a match and transmute to each type, similar to how you've done it in blacken_object
?
e.g.
Lines 195 to 199 in a605c17
Hi,
great implementation!
Would it be difficult to add the ability of scripts to return values ? For example if I would like to evaluate an expression and would expect an boolean return type, or if I want to evaluate a number expression and would expect a number to be returned ?
Thanks
Lines 220 to 224 in a605c17
if header.as_mut().marked {
return
}
Hi,
Thank you so much for sharing your great code and your experience in the blog.
I'm reading your GC code in unsafe https://github.com/ceronman/loxido/blob/unsafe/src/gc.rs and have a question.
Is it intentional that trace_references is marking objects (= trace from roots) and pushing them to grey_stack?
In my understanding the GC works in 3 steps as below.
I see grey_stack as a collection of root objects and it is created in 1 and used in 2.
But I see grey_stack is actually updated in 2 which makes me think why.
Thank you in advance,
Taro
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.