• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

mrubyを超漢字で動作させる


Commit MetaInfo

Revisãoe871b77f417538dc181ef69d497262786d96f5c0 (tree)
Hora2015-10-21 00:16:46
AutorSeba Gamboa <me@sagm...>
CommiterSeba Gamboa

Mensagem de Log

Increasing docs coverage

Mudança Sumário

Diff

--- a/.yardopts
+++ b/.yardopts
@@ -1,6 +1,14 @@
11 --plugin mruby
22 --plugin coderay
33 --output-dir doc/api
4+
5+src/**/*.c
6+mrblib/**/*.rb
7+include/**/*.h
8+
9+mrbgems/*/src/**/*.c
10+mrbgems/*/mrblib/**/*.rb
11+mrbgems/*/include/**/*.h
412 -
513 AUTHORS
614 MITL
--- a/include/mruby.h
+++ b/include/mruby.h
@@ -887,9 +887,26 @@ MRB_API mrb_value mrb_attr_get(mrb_state *mrb, mrb_value obj, mrb_sym id);
887887 MRB_API mrb_bool mrb_respond_to(mrb_state *mrb, mrb_value obj, mrb_sym mid);
888888 MRB_API mrb_bool mrb_obj_is_instance_of(mrb_state *mrb, mrb_value obj, struct RClass* c);
889889
890-/* fiber functions (you need to link mruby-fiber mrbgem to use) */
890+
891+/*
892+ * Resume a Fiber
893+ *
894+ * @mrbgem mruby-fiber
895+ */
891896 MRB_API mrb_value mrb_fiber_resume(mrb_state *mrb, mrb_value fib, mrb_int argc, const mrb_value *argv);
897+
898+/*
899+ * Yield a Fiber
900+ *
901+ * @mrbgem mruby-fiber
902+ */
892903 MRB_API mrb_value mrb_fiber_yield(mrb_state *mrb, mrb_int argc, const mrb_value *argv);
904+
905+/*
906+ * FiberError reference
907+ *
908+ * @mrbgem mruby-fiber
909+ */
893910 #define E_FIBER_ERROR (mrb_class_get(mrb, "FiberError"))
894911
895912 /* memory pool implementation */
--- a/src/array.c
+++ b/src/array.c
@@ -1068,7 +1068,7 @@ mrb_init_array(mrb_state *mrb)
10681068 {
10691069 struct RClass *a;
10701070
1071- a = mrb->array_class = mrb_define_class(mrb, "Array", mrb->object_class); /* 15.2.12 */
1071+ mrb->array_class = a = mrb_define_class(mrb, "Array", mrb->object_class); /* 15.2.12 */
10721072 MRB_SET_INSTANCE_TT(a, MRB_TT_ARRAY);
10731073
10741074 mrb_define_class_method(mrb, a, "[]", mrb_ary_s_create, MRB_ARGS_ANY()); /* 15.2.12.4.1 */
--- a/src/hash.c
+++ b/src/hash.c
@@ -827,7 +827,7 @@ mrb_init_hash(mrb_state *mrb)
827827 {
828828 struct RClass *h;
829829
830- h = mrb->hash_class = mrb_define_class(mrb, "Hash", mrb->object_class); /* 15.2.13 */
830+ mrb->hash_class = h = mrb_define_class(mrb, "Hash", mrb->object_class); /* 15.2.13 */
831831 MRB_SET_INSTANCE_TT(h, MRB_TT_HASH);
832832
833833 mrb_define_method(mrb, h, "[]", mrb_hash_aget, MRB_ARGS_REQ(1)); /* 15.2.13.4.2 */
--- a/src/kernel.c
+++ b/src/kernel.c
@@ -1097,7 +1097,7 @@ mrb_init_kernel(mrb_state *mrb)
10971097 {
10981098 struct RClass *krn;
10991099
1100- krn = mrb->kernel_module = mrb_define_module(mrb, "Kernel"); /* 15.3.1 */
1100+ mrb->kernel_module = krn = mrb_define_module(mrb, "Kernel"); /* 15.3.1 */
11011101 mrb_define_class_method(mrb, krn, "block_given?", mrb_f_block_given_p_m, MRB_ARGS_NONE()); /* 15.3.1.2.2 */
11021102 mrb_define_class_method(mrb, krn, "global_variables", mrb_f_global_variables, MRB_ARGS_NONE()); /* 15.3.1.2.4 */
11031103 mrb_define_class_method(mrb, krn, "iterator?", mrb_f_block_given_p_m, MRB_ARGS_NONE()); /* 15.3.1.2.5 */
--- a/src/numeric.c
+++ b/src/numeric.c
@@ -1161,7 +1161,7 @@ mrb_init_numeric(mrb_state *mrb)
11611161 mrb_define_method(mrb, integer, "to_int", int_to_i, MRB_ARGS_NONE());
11621162
11631163 /* Fixnum Class */
1164- fixnum = mrb->fixnum_class = mrb_define_class(mrb, "Fixnum", integer);
1164+ mrb->fixnum_class = fixnum = mrb_define_class(mrb, "Fixnum", integer);
11651165 mrb_define_method(mrb, fixnum, "+", fix_plus, MRB_ARGS_REQ(1)); /* 15.2.8.3.1 */
11661166 mrb_define_method(mrb, fixnum, "-", fix_minus, MRB_ARGS_REQ(1)); /* 15.2.8.3.2 */
11671167 mrb_define_method(mrb, fixnum, "*", fix_mul, MRB_ARGS_REQ(1)); /* 15.2.8.3.3 */
@@ -1181,7 +1181,7 @@ mrb_init_numeric(mrb_state *mrb)
11811181 mrb_define_method(mrb, fixnum, "divmod", fix_divmod, MRB_ARGS_REQ(1)); /* 15.2.8.3.30 (x) */
11821182
11831183 /* Float Class */
1184- fl = mrb->float_class = mrb_define_class(mrb, "Float", numeric); /* 15.2.9 */
1184+ mrb->float_class = fl = mrb_define_class(mrb, "Float", numeric); /* 15.2.9 */
11851185 mrb_undef_class_method(mrb, fl, "new");
11861186 mrb_define_method(mrb, fl, "+", flo_plus, MRB_ARGS_REQ(1)); /* 15.2.9.3.1 */
11871187 mrb_define_method(mrb, fl, "-", flo_minus, MRB_ARGS_REQ(1)); /* 15.2.9.3.2 */
--- a/src/object.c
+++ b/src/object.c
@@ -264,7 +264,7 @@ mrb_init_object(mrb_state *mrb)
264264 struct RClass *t;
265265 struct RClass *f;
266266
267- n = mrb->nil_class = mrb_define_class(mrb, "NilClass", mrb->object_class);
267+ mrb->nil_class = n = mrb_define_class(mrb, "NilClass", mrb->object_class);
268268 mrb_undef_class_method(mrb, n, "new");
269269 mrb_define_method(mrb, n, "&", false_and, MRB_ARGS_REQ(1)); /* 15.2.4.3.1 */
270270 mrb_define_method(mrb, n, "^", false_xor, MRB_ARGS_REQ(1)); /* 15.2.4.3.2 */
@@ -273,7 +273,7 @@ mrb_init_object(mrb_state *mrb)
273273 mrb_define_method(mrb, n, "to_s", nil_to_s, MRB_ARGS_NONE()); /* 15.2.4.3.5 */
274274 mrb_define_method(mrb, n, "inspect", nil_inspect, MRB_ARGS_NONE());
275275
276- t = mrb->true_class = mrb_define_class(mrb, "TrueClass", mrb->object_class);
276+ mrb->true_class = t = mrb_define_class(mrb, "TrueClass", mrb->object_class);
277277 mrb_undef_class_method(mrb, t, "new");
278278 mrb_define_method(mrb, t, "&", true_and, MRB_ARGS_REQ(1)); /* 15.2.5.3.1 */
279279 mrb_define_method(mrb, t, "^", true_xor, MRB_ARGS_REQ(1)); /* 15.2.5.3.2 */
@@ -281,7 +281,7 @@ mrb_init_object(mrb_state *mrb)
281281 mrb_define_method(mrb, t, "|", true_or, MRB_ARGS_REQ(1)); /* 15.2.5.3.4 */
282282 mrb_define_method(mrb, t, "inspect", true_to_s, MRB_ARGS_NONE());
283283
284- f = mrb->false_class = mrb_define_class(mrb, "FalseClass", mrb->object_class);
284+ mrb->false_class = f = mrb_define_class(mrb, "FalseClass", mrb->object_class);
285285 mrb_undef_class_method(mrb, f, "new");
286286 mrb_define_method(mrb, f, "&", false_and, MRB_ARGS_REQ(1)); /* 15.2.6.3.1 */
287287 mrb_define_method(mrb, f, "^", false_xor, MRB_ARGS_REQ(1)); /* 15.2.6.3.2 */
--- a/src/string.c
+++ b/src/string.c
@@ -2674,7 +2674,7 @@ mrb_init_string(mrb_state *mrb)
26742674
26752675 mrb_static_assert(RSTRING_EMBED_LEN_MAX < (1 << 5), "pointer size too big for embedded string");
26762676
2677- s = mrb->string_class = mrb_define_class(mrb, "String", mrb->object_class); /* 15.2.10 */
2677+ mrb->string_class = s = mrb_define_class(mrb, "String", mrb->object_class); /* 15.2.10 */
26782678 MRB_SET_INSTANCE_TT(s, MRB_TT_STRING);
26792679
26802680 mrb_define_method(mrb, s, "bytesize", mrb_str_bytesize, MRB_ARGS_NONE());
--- a/src/symbol.c
+++ b/src/symbol.c
@@ -478,7 +478,7 @@ mrb_init_symbol(mrb_state *mrb)
478478 {
479479 struct RClass *sym;
480480
481- sym = mrb->symbol_class = mrb_define_class(mrb, "Symbol", mrb->object_class); /* 15.2.11 */
481+ mrb->symbol_class = sym = mrb_define_class(mrb, "Symbol", mrb->object_class); /* 15.2.11 */
482482
483483 mrb_define_method(mrb, sym, "===", sym_equal, MRB_ARGS_REQ(1)); /* 15.2.11.3.1 */
484484 mrb_define_method(mrb, sym, "id2name", mrb_sym_to_s, MRB_ARGS_NONE()); /* 15.2.11.3.2 */