Commit 52b63438

52b63438cbddMerged

Yukihiro "Matz" Matsumoto <[email protected]> · 7 months ago · 1 file · ~1 modified

Description

feat: add String#encode, #force_encoding, #b as no-ops

Spinel uses UTF-8 exclusively. These methods return the receiver unchanged for source compatibility with Ruby code.

Co-Authored-By: Claude Opus 4.6 (1M context) [email protected]

Details

Commit
52b63438cbdd
Parent
87926b64cf49

spinel_codegen.rbmodifiedView file

@@ -12183,6 +12183,9 @@
1218312183 if mname == "hash"
1218412184 return "(mrb_int)sp_str_hash(" + rc + ")"
1218512185 end
12186+ if mname == "encode" || mname == "force_encoding" || mname == "b"
12187+ return rc
12188+ end
1218612189 if mname == "strip"
1218712190 return "sp_str_strip(" + rc + ")"
1218812191 end