Lazily evaluate the args.
480682
def _get_args(self):
        
        if not hasattr(self, '_args_evaled'):
            # cache the args in case handler is re-invoked due to flags change
            self._args_evaled = list(chain.from_iterable(self._args))
        return self._args_evaled
1197348
function rm(argv, callback) {
  util.rm(argv[2], function(err, val) {
    if (!err) {
      callback(null, val, argv[2]);
    }
  });
}
135081
def lazy_result(f):
    """"""
    @wraps(f)
    def decorated(ctx, param, value):
        return LocalProxy(lambda: f(ctx, param, value))
    return decorated
799603
def optional_argument_decorator(_decorator):
    """"""

    @functools.wraps(_decorator)
    def inner_decorator_make(*args, **kwargs):
        if len(args) == 1 and len(kwargs) == 0 and callable(args[0]):
            func = args[0]
            args = tuple()
            kwargs = dict()
        else:
            func = None

        decorator = _decorator(*args, **kwargs)

        if func:
            return decorator(func)
        else:
            return decorator

    return inner_decorator_make
1022977
protected final void args(Object... args) {
        if (args == null) args = NO_ARGS;
        this.args = args;
        retry();
    }
974846
@SuppressWarnings("ReferenceEquality")
  private void logImpl(String message, Object... args) {
    this.args = args;
    // Evaluate any (rare) LazyArg instances early. This may throw exceptions from user code, but
    // it seems reasonable to propagate them in this case (they would have been thrown if the
    // argument was evaluated at the call site anyway).
    for (int n = 0; n < args.length; n++) {
      if (args[n] instanceof LazyArg) {
        args[n] = ((LazyArg<?>) args[n]).evaluate();
      }
    }
    // Using "!=" is fast and sufficient here because the only real case this should be skipping
    // is when we called log(String) or log(), which should not result in a template being created.
    // DO NOT replace this with a string instance which can be interned, or use equals() here,
    // since that could mistakenly treat other calls to log(String, Object...) incorrectly.
    if (message != LITERAL_VALUE_MESSAGE) {
      this.templateContext = new TemplateContext(getMessageParser(), message);
    }
    getLogger().write(this);
  }
914265
def arg_strings(parsed_args, name=None):
    """"""
    name = name or 'arg_strings'
    value = getattr(parsed_args, name, [])
    if isinstance(value, str):
        return [value]
    try:
        return [v for v in value if isinstance(v, str)]
    except TypeError:
        return []
376353
def call(fun, **kwargs):
    '''
    
    '''
    args = kwargs.get('args', [])
    dirs = kwargs.get('dirs', [])

    funcs = LazyLoader(
        [os.path.join(SALT_BASE_PATH, 'modules')] + dirs,
        None,
        tag='modules',
        virtual_enable=False,
    )
    return funcs[fun](*args)
861026
public Object execEval(String arg) {
		try {
			return scriptEngine.eval("eval(" + arg + ")");
		} catch (ScriptException e) {
			throw new BundlingProcessException("Error while evaluating a script", e);
		}
	}
953648
def curry(*args)
      if curry_args.empty? && args.first.is_a?(Graph::InputEvaluator)
        Lazy[self].new(self, *args)
      else
        self.class.build(relation, { **options, curry_args: args })
      end
    end
1327684
def formatreturn(arg, input_is_array=False):
    """"""
    if not input_is_array and arg.size == 1:
        arg = arg.item()
    return arg
158102
def eval(self, script, keys=[], args=[]):
        """"""
        return self.execute(b'EVAL', script, len(keys), *(keys + args))
1218048
function lazy(arg) {
  var conf = this.configure();
  var action = arg.action();
  if(!conf.command.dir || action !== undefined) return false;
  var file = path.join(conf.command.dir, getModulePath.call(this, arg))
  try{
    action = require(file);
    if(typeof action !== 'function') {
      return this.raise(this.errors.ECMD_TYPE, [file]);
    }
    arg.action(action);
  }catch(e) {
    return this.raise(this.errors.ECMD_REQUIRE, [file, e.message], e);
  }
}
910414
def __normalize_args(**keywds):
        """"""
        if isinstance(keywds['name'], Callable) and \
                None is keywds['function']:
            keywds['function'] = keywds['name']
            keywds['name'] = None
        return keywds
90615
def server_args(self, parsed_args):
        """"""
        args = {
            arg: value
            for arg, value in vars(parsed_args).items()
            if not arg.startswith('_') and value is not None
        }
        args.update(vars(self))
        return args
224902
def lazyfunc(func):
    
    closuremem_ = [{}]
    def wrapper(*args, **kwargs):
        mem = closuremem_[0]
        key = (repr(args), repr(kwargs))
        try:
            return mem[key]
        except KeyError:
            mem[key] = func(*args, **kwargs)
        return mem[key]
    return wrapper
1162826
def evaluate(self, **kwargs):
        
        self._eval_points = kwargs.get('points', self._init_array())
        self._dimension = len(self._eval_points[0])