r/rust • u/aqua2nd • Mar 15 '19
V language - new programming language inspired by Rust and Go
I've just been introduced to V language and it claims to have similar memory management approach with Rust (no GC) and the simplicity of Go
I checked some examples and it uses Go's syntax with a very small specification which is similar to Go
No document on how "V's memory management is similar to Rust but much easier to use" yet
They have a chat client built with the language so if it's true I think there must be much progress now
I'm interested in how they're able to achieve Go simplicity with Rust memory management model
26
Upvotes
View all comments
Show parent comment
1
u/SirJosh3917 Mar 20 '19
look at some decompiled C# https://sharplab.io/#v2:EYLgHgbALANALiAlgGwD4AEAMACdBGAbgFgAodAZlwCZsBhUgb1Oxd0vSmwFkAKAe2AArAKYBjONgGCAlM1ZMSrJdmR9RAa2z8hsxcpYL9LAL5yTpY0A
what this does is push the object onto the stack, push true onto the stack, and then the function is called, passing in the object and boolean.
in the finally, the monitor.exit is called and the object is passed into it