code: def multi_interp_extensions_check(enabled=True):
      """Force legacy modules to be allowed in subinterpreters (or not).
  
      ("legacy" == single-phase init)
  
      This only applies to modules that haven't been imported yet.
      It overrides the PyInterpreterConfig.check_multi_interp_extensions
      setting (see support.run_in_subinterp_with_config() and
      _xxsubinterpreters.create()).
  
      Also see importlib.utils.allowing_all_extensions().
      """
      old = _imp._override_multi_interp_extensions_check(
          1 if enabled else -1
      )
      try:
          yield
      finally:
          _imp._override_multi_interp_extensions_check(old)
  
imports: import contextlib
  import _imp
  import importlib
  import importlib.util
  import os
  import shutil
  import sys
  import unittest
  import warnings
  from .os_helper import unlink, temp_dir
label_desc: Use image node_id 8 for calling a global function with example usage: multi_interp_extensions_check(enabled) without return types