(self, code: 'mesonlib.FileOrString', env: 'Environment',
                       extra_args: T.Union[None, CompilerArgs, T.List[str], T.Callable[[CompileCheckMode], T.List[str]]] = None,
                       dependencies: T.Optional[T.List['Dependency']] = None,
                       mode: str = 'compile', want_output: bool = False,
                       disable_cache: bool = False,
                       temp_dir: str = None)
Helper for getting a cacched value when possible.

        This method isn't meant to be called externally, it's mean to be
        wrapped by other methods like compiles() and links().
Helper for getting a cacched value when possible.
Helper for getting a cacched value when possible .
def _build_wrapper(self, code: 'mesonlib.FileOrString', env: 'Environment',
                       extra_args: T.Union[None, CompilerArgs, T.List[str], T.Callable[[CompileCheckMode], T.List[str]]] = None,
                       dependencies: T.Optional[T.List['Dependency']] = None,
                       mode: str = 'compile', want_output: bool = False,
                       disable_cache: bool = False,
                       temp_dir: str = None) -> T.Iterator[T.Optional[CompileResult]]:
        """Helper for getting a cacched value when possible.

        This method isn't meant to be called externally, it's mean to be
        wrapped by other methods like compiles() and links().
        """
        args = self.build_wrapper_args(env, extra_args, dependencies, CompileCheckMode(mode))
        if disable_cache or want_output:
            with self.compile(code, extra_args=args, mode=mode, want_output=want_output, temp_dir=env.scratch_dir) as r:
                yield r
        else:
            with self.cached_compile(code, env.coredata, extra_args=args, mode=mode, temp_dir=env.scratch_dir) as r:
                yield r
def _build_wrapper ( self , code : 'mesonlib.FileOrString' , env : 'Environment' , extra_args : T . Union [ None , CompilerArgs , T . List [ str ] , T . Callable [ [ CompileCheckMode ] , T . List [ str ] ] ] = None , dependencies : T . Optional [ T . List [ 'Dependency' ] ] = None , mode : str = 'compile' , want_output : bool = False , disable_cache : bool = False , temp_dir : str = None ) -> T . Iterator [ T . Optional [ CompileResult ] ] : args = self . build_wrapper_args ( env , extra_args , dependencies , CompileCheckMode ( mode ) ) if disable_cache or want_output : with self . compile ( code , extra_args = args , mode = mode , want_output = want_output , temp_dir = env . scratch_dir ) as r : yield r else : with self . cached_compile ( code , env . coredata , extra_args = args , mode = mode , temp_dir = env . scratch_dir ) as r : yield r