Home
last modified time | relevance | path

Searched refs:kwarg (Results 1 – 25 of 38) sorted by relevance

12

/third_party/python/Lib/test/
Dtest_keywordonlyarg.py8 def posonly_sum(pos_arg1, *arg, **kwarg): argument
9 return pos_arg1 + sum(arg) + sum(kwarg.values())
14 def keywordonly_and_kwarg_sum(*, k1, k2, **kwarg): argument
15 return k1 + k2 + sum(kwarg.values())
Dtest_type_comments.py331 len(todo) - bool(t.args.vararg) - bool(t.args.kwarg))
338 arg = t.args.kwarg
350 for arg in t.args.args + [t.args.vararg, t.args.kwarg]:
Dtest_ast.py1131 kwonlyargs=None, kwarg=None, argument
1144 kw_defaults, kwarg, defaults)
1812 self._check_content(s, fdef.args.kwarg, 'kwargs: Any')
1813 self._check_content(s, fdef.args.kwarg.annotation, 'Any')
Dtest_grammar.py691 def pos2key2dict(p1, p2, *, k1=100, k2, **kwarg): return p1,p2,k1,k2,kwarg argument
/third_party/python/Lib/unittest/test/testmock/
Dtestpatch.py1702 for kwarg in ('spec', 'spec_set', 'autospec'):
1704 **{kwarg: True})
1709 p = patch(MODNAME, create=True, **{kwarg: True})
1716 for kwarg in ('spec', 'spec_set'):
1717 p = patch(MODNAME, autospec=0, **{kwarg: 0})
1721 for kwarg in ('spec', 'autospec'):
1722 p = patch(MODNAME, spec_set=0, **{kwarg: 0})
1726 for kwarg in ('spec_set', 'autospec'):
1727 p = patch(MODNAME, spec=0, **{kwarg: 0})
1744 for kwarg in ('spec', 'autospec', 'spec_set'):
[all …]
/third_party/python/Parser/
Dpegen.c1982 _PyPegen_star_etc(Parser *p, arg_ty vararg, asdl_seq *kwonlyargs, arg_ty kwarg) in _PyPegen_star_etc() argument
1990 a->kwarg = kwarg; in _PyPegen_star_etc()
2188 arg_ty kwarg = NULL; in _PyPegen_make_arguments() local
2189 if (star_etc != NULL && star_etc->kwarg != NULL) { in _PyPegen_make_arguments()
2190 kwarg = star_etc->kwarg; in _PyPegen_make_arguments()
2194 kwdefaults, kwarg, posdefaults, p->arena); in _PyPegen_make_arguments()
DPython.asdl112 expr* kw_defaults, arg? kwarg, expr* defaults)
Dpegen.h109 arg_ty kwarg; member
/third_party/skia/third_party/externals/jinja2/
Dcompiler.py421 for kwarg in chain((x.key for x in node.kwargs), extra_kwargs or ()):
422 if is_python_keyword(kwarg):
431 for kwarg in node.kwargs:
433 self.visit(kwarg, frame)
446 for kwarg in node.kwargs:
447 self.write("%r: " % kwarg.key)
448 self.visit(kwarg.value, frame)
/third_party/node/tools/inspector_protocol/jinja2/
Dcompiler.py419 for kwarg in chain((x.key for x in node.kwargs), extra_kwargs or ()):
420 if is_python_keyword(kwarg):
429 for kwarg in node.kwargs:
431 self.visit(kwarg, frame)
444 for kwarg in node.kwargs:
445 self.write('%r: ' % kwarg.key)
446 self.visit(kwarg.value, frame)
/third_party/python/Lib/
Dinspect.py1542 for kwarg in kwonlyargs:
1543 if kwarg not in arg2value:
1544 if kwonlydefaults and kwarg in kwonlydefaults:
1545 arg2value[kwarg] = kwonlydefaults[kwarg]
2236 if f.args.kwarg:
2238 p(f.args.kwarg, empty)
Dast.py1546 if node.kwarg:
1551 self.write("**" + node.kwarg.arg)
1552 if node.kwarg.annotation:
1554 self.traverse(node.kwarg.annotation)
/third_party/python/Python/
Dsymtable.c1874 if (a->kwarg && a->kwarg->annotation) in symtable_visit_annotations()
1875 VISIT(st, expr, a->kwarg->annotation); in symtable_visit_annotations()
1904 if (a->kwarg) { in symtable_visit_arguments()
1905 if (!symtable_add_def(st, a->kwarg->arg, DEF_PARAM, LOCATION(a->kwarg))) in symtable_visit_arguments()
Dast.c111 if (args->kwarg && args->kwarg->annotation in validate_arguments()
112 && !validate_expr(state, args->kwarg->annotation, Load)) { in validate_arguments()
Dast_unparse.c272 if (args->kwarg) { in append_ast_args()
275 APPEND(arg, args->kwarg); in append_ast_args()
DPython-ast.c217 Py_CLEAR(state->kwarg); in _PyAST_Fini()
319 if ((state->kwarg = PyUnicode_InternFromString("kwarg")) == NULL) return 0; in init_identifiers()
1718 if (PyObject_SetAttr(state->arguments_type, state->kwarg, Py_None) == -1) in init_types()
3270 kw_defaults, arg_ty kwarg, asdl_expr_seq * defaults, PyArena in _PyAST_arguments() argument
3282 p->kwarg = kwarg; in _PyAST_arguments()
4909 value = ast2obj_arg(state, o->kwarg); in ast2obj_arguments()
4911 if (PyObject_SetAttr(result, state->kwarg, value) == -1) in ast2obj_arguments()
10199 arg_ty kwarg; in obj2ast_arguments() local
10367 if (_PyObject_LookupAttr(obj, state->kwarg, &tmp) < 0) { in obj2ast_arguments()
10372 kwarg = NULL; in obj2ast_arguments()
[all …]
Dast_opt.c638 CALL_OPT(astfold_arg, arg_ty, node_->kwarg); in astfold_arguments()
/third_party/python/Include/internal/
Dpycore_ast_state.h203 PyObject *kwarg; member
Dpycore_ast.h519 arg_ty kwarg; member
796 asdl_expr_seq * kw_defaults, arg_ty kwarg,
/third_party/python/Lib/lib2to3/tests/data/
Dpy3_test_grammar.py307 def pos2key2dict(p1, p2, *, k1=100, k2, **kwarg): return p1,p2,k1,k2,kwarg argument
/third_party/jinja2/
Dcompiler.py505 for kwarg in node.kwargs:
507 self.visit(kwarg, frame)
520 for kwarg in node.kwargs:
522 self.visit(kwarg.value, frame)
/third_party/python/Doc/library/
Djson.rst203 *cls* kwarg; otherwise :class:`JSONEncoder` is used.
278 kwarg; otherwise :class:`JSONDecoder` is used. Additional keyword arguments
Dast.rst1659 .. class:: arguments(posonlyargs, args, vararg, kwonlyargs, kw_defaults, kwarg, defaults)
1664 * ``vararg`` and ``kwarg`` are single :class:`arg` nodes, referring to the
1710 kwarg=arg(arg='g'),
/third_party/gstreamer/gstplugins_good/
Dmeson.build385 # We can't use the version: kwarg for find_program because old versions
/third_party/python/Misc/NEWS.d/
D3.6.1rc1.rst309 Altering a kwarg dictionary passed to functools.partial() no longer affects

12