Home
last modified time | relevance | path

Searched full:node (Results 1 – 25 of 6341) sorted by relevance

12345678910>>...254

/third_party/typescript/src/compiler/factory/
DnodeTests.ts4 export function isNumericLiteral(node: Node): node is NumericLiteral {
5 return node.kind === SyntaxKind.NumericLiteral;
8 export function isBigIntLiteral(node: Node): node is BigIntLiteral {
9 return node.kind === SyntaxKind.BigIntLiteral;
12 export function isStringLiteral(node: Node): node is StringLiteral {
13 return node.kind === SyntaxKind.StringLiteral;
16 export function isJsxText(node: Node): node is JsxText {
17 return node.kind === SyntaxKind.JsxText;
20 export function isRegularExpressionLiteral(node: Node): node is RegularExpressionLiteral {
21 return node.kind === SyntaxKind.RegularExpressionLiteral;
[all …]
DnodeFactory.ts9 // Disables the node converters for the factory.
13 // Do not set an `original` pointer when updating a node. enumerator
20 * @param baseFactory A `BaseNodeFactory` used to create the base `Node` objects.
26 … // Lazily load the parenthesizer, node converters, and some factory methods until they are used.
36 …Node | undefined; }>(kind: T["kind"]) => (node: T, type: T["type"]) => updateJSDocUnaryTypeWorker<…
38 …ix: boolean; }>(kind: T["kind"]) => (node: T, type: T["type"]) => updateJSDocPrePostfixUnaryTypeWo…
40 …d: T["kind"]) => (node: T, tagName: Identifier | undefined, comment?: NodeArray<JSDocComment>) => …
42node: T, tagName: Identifier | undefined, typeExpression?: JSDocTypeExpression, comment?: NodeArra…
550 …function createNodeArray<T extends Node>(elements?: readonly T[], hasTrailingComma?: boolean): Nod…
576 … // Since the element list of a node array is typically created by starting with an empty array and
[all …]
DemitNode.ts3 * Associates a node with the current transformation, initializing
7 export function getOrCreateEmitNode(node: Node): EmitNode {
8 if (!node.emitNode) {
9 if (isParseTreeNode(node)) {
11 // parse tree node we are annotating. This allows us to clean them up after
13 if (node.kind === SyntaxKind.SourceFile) {
14 return node.emitNode = { annotatedNodes: [node] } as EmitNode;
17 …const sourceFile = getSourceFileOfNode(getParseTreeNode(getSourceFileOfNode(node))) ?? Debug.fail(…
18 getOrCreateEmitNode(sourceFile).annotatedNodes!.push(node);
21 node.emitNode = {} as EmitNode;
[all …]
/third_party/typescript/src/compiler/
DvisitorPublic.ts3 * Visits a Node using the supplied visitor, possibly returning a new Node in its place.
5 * @param node The Node to visit.
6 * @param visitor The callback used to visit the Node.
7 * @param test A callback to execute to verify the Node is valid.
8 * @param lift An optional callback to execute to lift a NodeArray into a valid Node.
10 …ion visitNode<T extends Node>(node: T, visitor: Visitor | undefined, test?: (node: Node) => boolea…
13 * Visits a Node using the supplied visitor, possibly returning a new Node in its place.
15 * @param node The Node to visit.
16 * @param visitor The callback used to visit the Node.
17 * @param test A callback to execute to verify the Node is valid.
[all …]
DutilitiesPublic.ts252 for (let current: Node = d; current; current = current.parent) {
261 …export function isParameterPropertyDeclaration(node: Node, parent: Node): node is ParameterPropert…
262 …return hasSyntacticModifier(node, ModifierFlags.ParameterPropertyModifier) && parent.kind === Synt…
265 export function isEmptyBindingPattern(node: BindingName): node is BindingPattern {
266 if (isBindingPattern(node)) {
267 return every(node.elements, isEmptyBindingElement);
272 export function isEmptyBindingElement(node: BindingElement): boolean {
273 if (isOmittedExpression(node)) {
276 return isEmptyBindingPattern(node.name);
280 let node = binding.parent;
[all …]
Demitter.ts508 function collectLinkedAliases(node: Node) {
509 if (isExportAssignment(node)) {
510 if (node.expression.kind === SyntaxKind.Identifier) {
511 … resolver.collectLinkedAliases(node.expression as Identifier, /*setVisibility*/ true);
515 else if (isExportSpecifier(node)) {
516 … resolver.collectLinkedAliases(node.propertyName || node.name, /*setVisibility*/ true);
519 forEachChild(node, collectLinkedAliases);
964 let lastSubstitution: Node | undefined;
965 let currentParenthesizerRule: ((node: Node) => Node) | undefined;
968 const typeArgumentParenthesizerRuleSelector: OrdinalParentheizerRuleSelector<Node> = {
[all …]
Dbinder.ts18 …export function getModuleInstanceState(node: ModuleDeclaration, visited?: ESMap<number, ModuleInst…
19 if (node.body && !node.body.parent) {
21 setParent(node.body, node);
22 setParentRecursive(node.body, /*incremental*/ false);
24 …return node.body ? getModuleInstanceStateCached(node.body, visited) : ModuleInstanceState.Instanti…
27 …function getModuleInstanceStateCached(node: Node, visited = new Map<number, ModuleInstanceState | …
28 const nodeId = getNodeId(node);
33 const result = getModuleInstanceStateWorker(node, visited);
38 …function getModuleInstanceStateWorker(node: Node, visited: ESMap<number, ModuleInstanceState | und…
40 switch (node.kind) {
[all …]
/third_party/typescript/src/compiler/transformers/
Dts.ts65 let currentScopeFirstDeclarationsOfName: UnderscoreEscapedMap<Node> | undefined;
82 function transformSourceFileOrBundle(node: SourceFile | Bundle) {
83 if (node.kind === SyntaxKind.Bundle) {
84 return transformBundle(node);
86 return transformSourceFile(node);
89 function transformBundle(node: Bundle) {
90 …return factory.createBundle(node.sourceFiles.map(transformSourceFile), mapDefined(node.prepends, p…
101 * @param node A SourceFile node.
103 function transformSourceFile(node: SourceFile) {
104 if (node.isDeclarationFile) {
[all …]
Des2017.ts48 /** A set of node IDs for generated super accessors (variable statements). */
63 function transformSourceFile(node: SourceFile) {
64 if (node.isDeclarationFile) {
65 return node;
69 …setContextFlag(ContextFlags.HasLexicalThis, !isEffectiveStrictModeSourceFile(node, compilerOptions…
70 const visited = visitEachChild(node, visitor, context);
102 function visitDefault(node: Node): VisitResult<Node> {
103 return visitEachChild(node, visitor, context);
106 function visitor(node: Node): VisitResult<Node> {
107 if ((node.transformFlags & TransformFlags.ContainsES2017) === 0) {
[all …]
Des2018.ts73 /** A set of node IDs for generated super accessors. */
83 …* Sets the `HierarchyFacts` for this node prior to visiting this node's subtree, returning the fac…
94 * Restores the `HierarchyFacts` for this node's ancestor after visiting this node's
108 function transformSourceFile(node: SourceFile) {
109 if (node.isDeclarationFile) {
110 return node;
113 currentSourceFile = node;
114 const visited = visitSourceFile(node);
122 function visitor(node: Node): VisitResult<Node> {
123 return visitorWorker(node, /*expressionResultIsUnused*/ false);
[all …]
/third_party/python/Lib/
Dast.py36 Parse the source into an AST node.
56 Evaluate an expression node or a string containing only a Python
57 expression. The string or node provided may only consist of the following
67 def _raise_malformed_node(node): argument
68 msg = "malformed node or string"
69 if lno := getattr(node, 'lineno', None):
71 raise ValueError(msg + f': {node!r}')
72 def _convert_num(node): argument
73 if not isinstance(node, Constant) or type(node.value) not in (int, float, complex):
74 _raise_malformed_node(node)
[all …]
/third_party/typescript/src/services/
DcallHierarchy.ts8 /** Indictates whether a node is named function or class expression. */
9 function isNamedExpression(node: Node): node is NamedExpression {
10 return (isFunctionExpression(node) || isClassExpression(node)) && isNamedDeclaration(node);
19 …/** Indicates whether a node is a function, arrow, or class expression assigned to a constant vari…
20 function isConstNamedExpression(node: Node): node is ConstNamedExpression {
21 return (isFunctionExpression(node) || isArrowFunction(node) || isClassExpression(node))
22 && isVariableDeclaration(node.parent)
23 && node === node.parent.initializer
24 && isIdentifier(node.parent.name)
25 && !!(getCombinedNodeFlags(node.parent) & NodeFlags.Const);
[all …]
Dbreakpoints.ts34 // Get the span in the node based on its syntax
37 function textSpan(startNode: Node, endNode?: Node) {
45 …function textSpanEndingAtNextToken(startNode: Node, previousTokenToFindNextEndToken: Node): TextSp…
49 …function spanInNodeIfStartsOnSameLine(node: Node | undefined, otherwiseOnNode?: Node): TextSpan | …
50 …if (node && lineOfPosition === sourceFile.getLineAndCharacterOfPosition(node.getStart(sourceFile))…
51 return spanInNode(node);
56 …function spanInNodeArray<T extends Node>(nodeArray: NodeArray<T> | undefined, node: T, match: (val…
58 const index = nodeArray.indexOf(node);
67 return textSpan(node);
70 function spanInPreviousNode(node: Node): TextSpan | undefined {
[all …]
/third_party/mindspore/mindspore-src/source/mindspore/python/mindspore/rewrite/node/
Dnode_topological_manager.py18 from .node import Node
28 def on_update_target(node: Node, index: int, old_target: ScopedValue, new_target: ScopedValue): argument
30 Update node's dicts while updating target of node.
33 node (Node): An instance of Node whose target being updated.
34 arg_idx (int): An int indicates which target of node being updated.
38 … # Update old_target provider node's target_user dict & old arg's user nodes' arg_providers dict
39 old_provider = TopoManager._get_value_provider(node, old_target)
41 for user in node.get_target_users(index):
45 for user in node.get_target_users(index):
47 # Update new_target node's target_users dict & new user nodes' arg_providers dict
[all …]
/third_party/typescript/src/compiler/transformers/module/
Dsystem.ts40 let enclosingBlockScopedContainer: Node;
48 * @param node The SourceFile node.
50 function transformSourceFile(node: SourceFile) {
51 …if (node.isDeclarationFile || !(isEffectiveExternalModule(node, compilerOptions) || node.transform…
52 return node;
55 const id = getOriginalNodeId(node);
56 currentSourceFile = node;
57 enclosingBlockScopedContainer = node;
73 …moduleInfo = moduleInfoMap[id] = collectExternalModuleInfo(context, node, resolver, compilerOption…
83 const moduleBodyBlock = createSystemModuleBody(node, dependencyGroups);
[all …]
/third_party/parse5/packages/parse5/lib/tree-adapters/
Dinterface.ts5 Node = unknown,
16 node: Node; property
45 * Appends a child node to the given parent node.
47 * @param parentNode - Parent node.
48 * @param newNode - Child node.
53 * Creates a comment node.
60 * Creates a document node.
65 * Creates a document fragment node.
70 * Creates an element node.
79 * Removes a node from its parent.
[all …]
/third_party/nghttp2/src/
Dshrpx_router.cc44 RNode *find_next_node(const RNode *node, char c) { in find_next_node() argument
45 auto itr = std::lower_bound(std::begin(node->next), std::end(node->next), c, in find_next_node()
48 if (itr == std::end(node->next) || (*itr)->s[0] != c) { in find_next_node()
57 void add_next_node(RNode *node, std::unique_ptr<RNode> new_node) { in add_next_node() argument
58 auto itr = std::lower_bound(std::begin(node->next), std::end(node->next), in add_next_node()
62 node->next.insert(itr, std::move(new_node)); in add_next_node()
66 void Router::add_node(RNode *node, const char *pattern, size_t patlen, in add_node() argument
71 add_next_node(node, std::move(new_node)); in add_node()
82 auto node = &root_; in add_route() local
86 auto next_node = find_next_node(node, pattern[i]); in add_route()
[all …]
/third_party/selinux/libsepol/cil/src/
Dcil_tree.c44 struct cil_tree_node *cil_tree_get_next_path(struct cil_tree_node *node, char **info_kind, uint32_t… in cil_tree_get_next_path() argument
48 if (!node) { in cil_tree_get_next_path()
52 node = node->parent; in cil_tree_get_next_path()
54 while (node) { in cil_tree_get_next_path()
55 if (node->flavor == CIL_NODE && node->data == NULL) { in cil_tree_get_next_path()
56 if (node->cl_head && node->cl_head->data == CIL_KEY_SRC_INFO) { in cil_tree_get_next_path()
57 if (!node->cl_head->next || !node->cl_head->next->next || !node->cl_head->next->next->next) { in cil_tree_get_next_path()
61 *info_kind = node->cl_head->next->data; in cil_tree_get_next_path()
62 rc = cil_string_to_uint32(node->cl_head->next->next->data, hll_line, 10); in cil_tree_get_next_path()
66 *path = node->cl_head->next->next->next->data; in cil_tree_get_next_path()
[all …]
/third_party/skia/third_party/externals/angle2/src/compiler/translator/TranslatorMetalDirect/
DIntermRebuild.h24 // - The node is visited before children are traversed.
25 // - The returned value is used to replace the visited node. The returned value may be the same
26 // as the original node.
30 // - If any new children are returned, the node is automatically rebuilt with the new children
32 // - Depending on the type of the node, null children may be discarded.
33 // - Ill-typed children cause rebuild errors. Ill-typed means the node to automatically rebuild
38 // - The node is visited after any children are traversed.
67 // Allow visit of returned node's children.
70 // Allow post visit of returned node.
73 // If (Children) bit, only visit if the returned node is the same as the original node.
[all …]
/third_party/skia/third_party/externals/angle2/src/compiler/translator/tree_util/
DIntermRebuild.h24 // - The node is visited before children are traversed.
25 // - The returned value is used to replace the visited node. The returned value may be the same
26 // as the original node.
30 // - If any new children are returned, the node is automatically rebuilt with the new children
32 // - Depending on the type of the node, null children may be discarded.
33 // - Ill-typed children cause rebuild errors. Ill-typed means the node to automatically rebuild
38 // - The node is visited after any children are traversed.
67 // Allow visit of returned node's children.
70 // Allow post visit of returned node.
73 // If (Children) bit, only visit if the returned node is the same as the original node.
[all …]
DAsNode.h28 static ANGLE_INLINE TIntermNode *exec(TIntermNode *node) { return node; }
34 static ANGLE_INLINE TIntermTyped *exec(TIntermNode *node)
36 return node ? node->getAsTyped() : nullptr;
43 static ANGLE_INLINE TIntermSymbol *exec(TIntermNode *node)
45 return node ? node->getAsSymbolNode() : nullptr;
52 static ANGLE_INLINE TIntermConstantUnion *exec(TIntermNode *node)
54 return node ? node->getAsConstantUnion() : nullptr;
61 static ANGLE_INLINE TIntermFunctionPrototype *exec(TIntermNode *node)
63 return node ? node->getAsFunctionPrototypeNode() : nullptr;
70 static ANGLE_INLINE TIntermPreprocessorDirective *exec(TIntermNode *node)
[all …]
/third_party/skia/third_party/externals/swiftshader/third_party/llvm-10.0/llvm/lib/Target/SystemZ/
DSystemZOperators.td229 // Node definitions
457 def z_loadbswap16 : PatFrag<(ops node:$addr), (z_loadbswap node:$addr), [{
460 def z_loadbswap32 : PatFrag<(ops node:$addr), (z_loadbswap node:$addr), [{
463 def z_loadbswap64 : PatFrag<(ops node:$addr), (z_loadbswap node:$addr), [{
467 def z_storebswap16 : PatFrag<(ops node:$src, node:$addr),
468 (z_storebswap node:$src, node:$addr), [{
471 def z_storebswap32 : PatFrag<(ops node:$src, node:$addr),
472 (z_storebswap node:$src, node:$addr), [{
475 def z_storebswap64 : PatFrag<(ops node:$src, node:$addr),
476 (z_storebswap node:$src, node:$addr), [{
[all …]
/third_party/skia/third_party/externals/swiftshader/third_party/llvm-10.0/llvm/include/llvm/Target/
DTargetSelectionDAG.td96 // DAG node.
295 // Selection DAG Node definitions.
309 def node;
706 // Selection DAG Node Transformation Functions.
723 // node is matched.
742 /// can match something on the DAG, from a single node to multiple nested other
911 def not : PatFrag<(ops node:$in), (xor node:$in, -1)>;
912 def vnot : PatFrag<(ops node:$in), (xor node:$in, immAllOnesV)>;
913 def ineg : PatFrag<(ops node:$in), (sub 0, node:$in)>;
923 def unindexedload : PatFrag<(ops node:$ptr), (ld node:$ptr)> {
[all …]
/third_party/skia/src/xml/
DSkDOM.cpp17 bool SkXMLParser::parse(const SkDOM& dom, const SkDOMNode* node) { in parse() argument
18 const char* elemName = dom.getName(node); in parse()
24 SkDOM::AttrIter iter(dom, node); in parse()
33 if ((node = dom.getFirstChild(node)) != nullptr) { in parse()
35 if (!this->parse(dom, node)) { in parse()
38 } while ((node = dom.getNextSibling(node)) != nullptr); in parse()
51 const SkDOM::Node* SkDOM::getRootNode() const { in getRootNode()
55 const SkDOM::Node* SkDOM::getFirstChild(const Node* node, const char name[]) const { in getFirstChild() argument
56 SkASSERT(node); in getFirstChild()
57 const Node* child = node->fFirstChild; in getFirstChild()
[all …]
/third_party/typescript/src/compiler/transformers/declarations/
Ddiagnostics.ts6 errorNode: Node;
36 export function canProduceDiagnostics(node: Node): node is DeclarationDiagnosticProducing {
37 return isVariableDeclaration(node) ||
38 isPropertyDeclaration(node) ||
39 isAnnotationPropertyDeclaration(node) ||
40 isPropertySignature(node) ||
41 isBindingElement(node) ||
42 isSetAccessor(node) ||
43 isGetAccessor(node) ||
44 isConstructSignatureDeclaration(node) ||
[all …]

12345678910>>...254