mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
db3d754261
refactored five functions to use mrb_ensure() instead of MRB_TRY/MRB_CATCH: - ary_subtract_internal(): body/ensure pattern for set cleanup - ary_union_internal(): body/ensure pattern for set cleanup - ary_intersection_internal(): body/ensure pattern for set cleanup - ary_intersect_p(): body/ensure pattern for set cleanup - ary_uniq_bang(): body/ensure pattern for set cleanup each function now uses a context struct containing set pointer and other necessary data, with separate body and ensure functions that guarantee cleanup on exception. this allows array-ext to compile as pure C without requiring C++ compiler when enable_cxx_exception is set. added mruby-error dependency to access mrb_ensure(). changed include from throw.h to error.h. fix #6667. Co-authored-by: Claude <noreply@anthropic.com>
7 lines
199 B
Ruby
7 lines
199 B
Ruby
MRuby::Gem::Specification.new('mruby-array-ext') do |spec|
|
|
spec.license = 'MIT'
|
|
spec.author = 'mruby developers'
|
|
spec.summary = 'Array class extension'
|
|
spec.add_dependency 'mruby-error'
|
|
end
|