From 54716fe7ebbf20b5e91fdbe9b65e0bedb0c4836a Mon Sep 17 00:00:00 2001 From: ko1 Date: Fri, 23 Oct 2015 19:02:55 +0000 Subject: * ruby.c: introduce --enable-frozen-string-literal-debug option. If this option is enabled, the modify error will be: can't modify frozen String (RuntimeError) => can't modify frozen String, created at test.rb:3 (RuntimeError) * iseq.h: add compile option frozen_string_literal_debug. * compile.c: catch up this fix. * error.c (rb_error_frozen): ditto. * iseq.c (set_compile_option_from_hash): ditto. * test/ruby/test_rubyoptions.rb: add a test for this fix. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52257 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- iseq.h | 1 + 1 file changed, 1 insertion(+) (limited to 'iseq.h') diff --git a/iseq.h b/iseq.h index 13d2f2630c..699524f17f 100644 --- a/iseq.h +++ b/iseq.h @@ -67,6 +67,7 @@ struct rb_compile_option_struct { int stack_caching; int trace_instruction; int frozen_string_literal; + int frozen_string_literal_debug; int debug_level; }; -- cgit v1.2.3