Commit 87abf04e

87abf04e0221Merged

Yukihiro "Matz" Matsumoto <[email protected]> · 6 months ago · 3 files · ~2 modified · -1 deleted

Description

Revert "fix: Hash#fetch with hash default on int-leaf hash"

This reverts commit 9f38cf1bcd050ddfe24c7a21ff7c4fbba99cf38a.

Details

Commit
87abf04e0221
Parent
b9fe6475f7f6

spinel_analyze.rbmodifiedView file

@@ -3808,16 +3808,6 @@
38083808 if def_at_f == "string" || def_at_f == "mutable_str"
38093809 return "string"
38103810 end
3811- # Hash-typed default (`fetch "k", {}`). Sequel to the
3812- # string-default case above: the two ternary arms are int (from
3813- # the get) and a hash pointer (from the default literal), with
3814- # no shared primitive type. Box both to sp_RbVal and surface
3815- # the call's result as poly. Limited to the int-leaf hash
3816- # variants for now; broader receivers can extend the pattern.
3817- if is_hash_type(def_at_f) == 1
3818- @needs_rb_value = 1
3819- return "poly"
3820- end
38213811 end
38223812 end
38233813 end