mrbgems / issues Goto Github PK
View Code? Open in Web Editor NEWIssues repository. Feel free to create any kind of issues related to mruby, mrbgem.
Home Page: https://github.com/mrbgems/issues/issues
Issues repository. Feel free to create any kind of issues related to mruby, mrbgem.
Home Page: https://github.com/mrbgems/issues/issues
Initial implementation in CRuby:
あと、crubyのparse.yの"kw"をgrepすればいいのでは。
あと、引数は`f_args`でやってるっぽいので、そこのblockついてるのをtailにしてkw関係のハンドリングをするっぽい
In rubyspec:
a:
or b:
.**
is rest of the keyword arguments like *
in normal argument.In Ruby Under a Microscope
(Japanese edition).
key?
method to check whether argument is passed.delete
to extract arguments from the passed Hash
.https://qiita.com/tsahara@github/items/86610a696f8ca792db45
should use mrb_data_init API
Need to add space for rest array when generating OP_APOST
.
@@ -1063,8 +1063,8 @@ gen_vmassignment(codegen_scope *s, node *tree, int rhs, int val)
else {
pop();
}
- push_n(post);
- pop_n(post);
+ push_n(post + 1);
+ pop_n(post + 1);
genop(s, MKOP_ABC(OP_APOST, cursp(), n, post));
n = 1;
if (t->car) { /* rest */
Since currently it can't be built with latest mruby.
https://github.com/mobiruby/mruby-cfunc
Since GC is inefficient in some embedded platform usage.
The idea is from Squirrel:
mixed approach ref counting/GC
It provides weak reference type and optional GC for detecting leaked object.
For lesser memory over-head weak reference implementation I don't want to add a new field to struct RBasic
.
Instead object that can have instance variables will have __weakref
instance variable.
Object without instance variables will have a flag to check whether it has a weak reference and need to provide a VM specific table to get weak reference object from object pointer.
struct mrb_weakref_data {
struct RBasic *ref;
};
void mrb_weakref_strong_deleter(mrb_state *mrb, void *p)
{
struct mrb_weakref_data *d = (struct mrb_weakref_data*)p;
d->ref = NULL;
}
void mrb_weakref_deleter(mrb_state *mrb, void *p)
{
struct mrb_weakref_data *d = (struct mrb_weakref_data*)p;
if (d->ref) {
// TODO: need other way to release objects without instance variables
mrb_iv_remove(mrb, (struct RObject*)d->ref, mrb_intern_lit(mrb, "__weakref"));
}
mrb_free(mrb, p);
}
GitHub pages seems good.
Since it's about mruby, should use mruby to generate HTMLs.
With NODE_ZSUPER
, nil
block isn't generated by codegen.c
unlike NODE_SUPER
.
p class A
include Comparable
end
returns array of included module in mruby.
Though, cruby return defined class instead.
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.