Skip to content

Commit aec6d78

Browse files
committed
Make jt run with enforced experimental options
* --core.load_path is experimental, so we need to unlock experimental options.
1 parent a45685c commit aec6d78

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

tool/jt.rb

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -701,15 +701,16 @@ def run_ruby(*args)
701701

702702
native = false
703703
graal = false
704+
core_load_path = true
704705
ruby_args = []
705-
vm_args = [core_load_path = "--core.load_path=#{TRUFFLERUBY_DIR}/src/main/ruby"]
706+
vm_args = []
706707

707708
while (arg = args.shift)
708709
case arg
709710
when '--native'
710711
native = true
711712
when '--no-core-load-path'
712-
vm_args.delete core_load_path
713+
core_load_path = false
713714
when '--graal'
714715
graal = true
715716
when '--stress'
@@ -753,6 +754,10 @@ def run_ruby(*args)
753754

754755
ruby_args += args
755756

757+
if core_load_path
758+
vm_args << "--experimental-options" << "--core.load_path=#{TRUFFLERUBY_DIR}/src/main/ruby"
759+
end
760+
756761
if graal
757762
if ENV["RUBY_BIN"] || native
758763
# Assume that Graal is automatically set up if RUBY_BIN is set or using a native image.
@@ -1293,6 +1298,9 @@ def test_specs(command, *args)
12931298
if args.include?('-t')
12941299
# Running specs on another Ruby, pass no options
12951300
else
1301+
# For --core.load_path and --backtraces.hide_core_files
1302+
options << "-T--experimental-options"
1303+
12961304
if args.delete('--native')
12971305
verify_native_bin!
12981306
options << '-t' << find_launcher(true)

0 commit comments

Comments
 (0)