Since presym is now mandatory, mruby.h includes presym.h so that
MRB_SYM() macros are available everywhere without explicit include.
Remove redundant #include <mruby/presym.h> from all source files.
Co-authored-by: Claude <noreply@anthropic.com>
Added complete call-seq documentation for proc binding functionality across
both source and test files:
## Core Implementation (src/proc_binding.c):
### Main Method:
- binding: returns Binding object capturing proc's execution context,
includes comprehensive examples showing local variable access, parameter
binding, and scope retention with practical usage patterns
### Helper Functions:
- mrb_mruby_proc_binding_gem_init: initializes gem by adding binding method
to Proc class, explains method signature and return type behavior
Co-authored-by: Atlassian Rovo Dev
Currently mruby-eval depends on mruby-binding (formerly mruby-binding-core).
Also, `Kernel#eval` can accept `binding` objects.
With this in mind, it would be better if `Binding#eval` could also be handled by `mrbgems/mruby-eval`.
- Added to `mruby-binding-core`
- `Binding#local_variable_defined?`
- `Binding#local_variable_get`
- `Binding#local_variable_set`
- `Binding#local_variables`
- `Binding#receiver`
- `Binding#source_location`
- `Binding#inspect`
- Added to `mruby-proc-binding`
- `Proc#binding`
The reason for separating `Proc#binding` is that core-mrbgems has a method that returns a closure object to minimize possible problems with being able to manipulate internal variables.
By separating it as different mrbgem, each user can judge this problem and incorporate it arbitrarily.