def get_option_internal(self, optname):
    raw_optname = optname
    if self.is_subproject():
        optname = ((self.subproject + ':') + optname)
    for opts in [self.coredata.base_options, compilers.base_options, self.coredata.builtins, dict(self.coredata.get_prefixed_options_per_machine(self.coredata.builtins_per_machine)), dict(self.coredata.flatten_lang_iterator(self.coredata.get_prefixed_options_per_machine(self.coredata.compiler_options)))]:
        v = opts.get(optname)
        if ((v is None) or v.yielding):
            v = opts.get(raw_optname)
        if (v is not None):
            return v
    try:
        opt = self.coredata.user_options[optname]
        if (opt.yielding and (':' in optname) and (raw_optname in self.coredata.user_options)):
            popt = self.coredata.user_options[raw_optname]
            if (type(opt) is type(popt)):
                opt = popt
            else:
                opt_type = opt.__class__.__name__[4:][:(- 6)].lower()
                popt_type = popt.__class__.__name__[4:][:(- 6)].lower()
                mlog.warning('Option {0!r} of type {1!r} in subproject {2!r} cannot yield to parent option of type {3!r}, ignoring parent value. Use -D{2}:{0}=value to set the value for this option manually.'.format(raw_optname, opt_type, self.subproject, popt_type), location=self.current_node)
        return opt
    except KeyError:
        pass
    raise InterpreterException(('Tried to access unknown option "%s".' % optname))
def get_option_internal(self, optname):
    raw_optname = optname
    if self.is_subproject():
        optname = ((self.subproject + ':') + optname)
    for opts in [self.coredata.base_options, compilers.base_options, self.coredata.builtins, dict(self.coredata.get_prefixed_options_per_machine(self.coredata.builtins_per_machine)), dict(self.coredata.flatten_lang_iterator(self.coredata.get_prefixed_options_per_machine(self.coredata.compiler_options)))]:
        v = opts.get(optname)
        if ((v is None) or v.yielding):
            v = opts.get(raw_optname)
        if (v is not None):
            return v
    try:
        opt = self.coredata.user_options[optname]
        if (opt.yielding and (':' in optname) and (raw_optname in self.coredata.user_options)):
            popt = self.coredata.user_options[raw_optname]
            if (type(opt) is type(popt)):
                opt = popt
            else:
                opt_type = opt.__class__.__name__[4:][:(- 6)].lower()
                popt_type = popt.__class__.__name__[4:][:(- 6)].lower()
                mlog.warning('Option {0!r} of type {1!r} in subproject {2!r} cannot yield to parent option of type {3!r}, ignoring parent value. Use -D{2}:{0}=value to set the value for this option manually.'.format(raw_optname, opt_type, self.subproject, popt_type), location=self.current_node)
        return opt
    except KeyError:
        pass
    raise InterpreterException(('Tried to access unknown option "%s".' % optname))