Skip to content

Commit 5a5287e

Browse files
jeremyevanskou
andauthored
Fix Ruby 3.4 check
Co-authored-by: Sutou Kouhei <[email protected]>
1 parent 8b3ade2 commit 5a5287e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ext/stringio/stringio.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1861,7 +1861,7 @@ strio_set_encoding(int argc, VALUE *argv, VALUE self)
18611861
}
18621862
ptr->enc = enc;
18631863
if (!NIL_P(ptr->string) && WRITABLE(self)
1864-
#if RUBY_API_VERSION_MAJOR == 3 || RUBY_API_VERSION_MAJOR >= 4
1864+
#if (RUBY_API_VERSION_MAJOR == 3 && RUBY_API_VERSION_MINOR >= 4) || RUBY_API_VERSION_MAJOR >= 4
18651865
// Do not attempt to modify chilled strings on Ruby 3.4+
18661866
&& !FL_TEST_RAW(ptr->string, RUBY_FL_USER2 | RUBY_FL_USER3)
18671867
#endif

0 commit comments

Comments
 (0)