| Age | Commit message (Collapse) | Author |
|
| Previous Name | New Name |
|------------------------------|-------------------------|
| MRB_ENABLE_ALL_SYMBOLS | MRB_USE_ALL_SYMBOLS |
| MRB_ENABLE_SYMBOLL_ALL | MRB_USE_ALL_SYMBOLS |
| MRB_ENABLE_CXX_ABI | MRB_USE_CXX_ABI |
| MRB_ENABLE_CXX_EXCEPTION | MRB_USE_CXX_EXCEPTION |
| MRB_ENABLE_DEBUG_HOOK | MRB_USE_DEBUG_HOOK |
| MRB_DISABLE_DIRECT_THREADING | MRB_NO_DIRECT_THREADING |
| MRB_DISABLE_STDIO | MRB_NO_STDIO |
| ENABLE_LINENOISE | MRB_USE_LINENOISE |
| ENABLE_READLINE | MRB_USE_READLINE |
| DISABLE_MIRB_UNDERSCORE | MRB_NO_MIRB_UNDERSCORE |
| DISABLE_GEMS | MRB_NO_GEMS |
* `MRB_ENABLE_SYMBOLL_ALL` seems to be a typo, so it is fixed.
* `MRB_` prefix is added to those without.
* The previous names can also be used for compatibility.
|
|
It is not decides by the extension.
In order to be recognized as a `.mrb` file, the following three points must be satisfied:
- File starts with "RITE"
- At least `sizeof(struct rite_binary_header)` bytes can be read
- `NUL` is included in the first 64 bytes of the file
If these are not met, it is judged as a text file and it is processed as a Ruby script.
The `bin/mruby -b` switch is still available which treats the given file as a `.mrb` file.
New `MRB_API` function:
- `include/mruby/compile.h` and `mrbgems/mruby-compiler/core/parse.y`
- `mrb_load_detect_file_cxt()` (remove with `MRB_DISABLE_STDIO`)
NOTE:
- Even script files now always open in binary mode for `bin/mruby`.
The `\r\n` is handled by the `nextc()` function already, so there is no problem even on Windows.
- The `nextc0()` function in `mrbgems/mruby-compiler/core/parse.y` can now specify a string buffer and a file pointer at the same time.
In this case, get it from the string buffer first.
This patch includes modifies by comment of https://github.com/mruby/mruby/pull/5157.
|
|
In addition, update the documents referring `build_config.rb` which is
no longer used. The new `build_config.rb` describes the new configuration
structure in the comment.
|
|
ref #4576 and ref #4947
* Need MRBAPI functions without `MRB_DISABLE_STDIO`:
* mrbgems/mruby-bin-debugger
* mrbgems/mruby-bin-mirb
* mrbgems/mruby-bin-mrbc
* mrbgems/mruby-bin-mruby
* mrbgems/mruby-bin-strip
* Need `stdio.h`:
* mrbgems/mruby-io
* mrbgems/mruby-print
* Need `snprintf()` in `stdio.h`:
* mrbgems/mruby-pack
* mrbgems/mruby-sprintf
|
|
'stdio.h' is included in 'mruby.h' ('mrbconf.h').
However, keep 'stdio.h' used by mruby-test.
|
|
We assume meta-programming is less used in embedded environments.
We have moved following methods:
* Kernel module
global_variables, local_variables, singleton_class,
instance_variables, instance_variables_defined?, instance_variable_get,
instance_variable_set, methods, private_methods, public_methods,
protected_methods, singleton_methods, define_singleton_methods
* Module class
class_variables, class_variables_defined?, class_variable_get,
class_variable_set, remove_class_variable, included_modules,
instance_methods, remove_method, method_removed, constants
* Module class methods
constants, nesting
Note:
Following meta-programming methods are kept in the core:
* Module class
alias_method, undef_method, ancestors, const_defined?, const_get,
const_set, remove_const, method_defined?, define_method
* Toplevel object
define_method
`mruby-metaprog` gem is linked by default (specified in default.gembox).
When it is removed, it will save 40KB (stripped:8KB) on x86-64
environment last time I measured.
|
|
* refactor: move `irep_remove_lv` from `mruby-bin-strip` gem to src/dump and rename to `mrb_irep_remove_lv`
* add: mrbc option `--remove-lv` to remove LVAR section
|
|
|
|
|
|
'bin/mruby' not work on windows. so correct command name and quoted arguments.
|
|
|
|
Reduces executable size by more than 50% (409->171 KB).
|
|
|
|
|
|
|
|
Previous version ignored some errors, and didn't free memory and close files.
Now no memory will be dynamically allocated to simplify error handling.
This commit also fixes a wrong check:
files[i] = fopen(argv[i], "wb");
if (!ireps[i]) {
Improve error messages a bit and add missing newline to one.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|