Searched refs:js_type (Results 1 – 4 of 4) sorted by relevance
106 def _FixJsDocPipeNull(self, js_type): argument114 map(self._FixJsDocPipeNull, js_type.IterTypes())116 if js_type.type_group and len(js_type.sub_types) == 2:119 for sub_type in js_type.sub_types:127 first_token = js_type.FirstToken()131 js_type.tokens.insert(0, question_mark)132 js_type.tokens.remove(sub_type)133 js_type.sub_types.remove(sub_type)134 js_type.or_null = True138 for token in js_type.tokens:[all …]
59 def _SetTypeAlias(js_type, alias_map): argument66 aliased_symbol = _GetAliasForIdentifier(js_type.identifier, alias_map)68 js_type.alias = aliased_symbol69 for sub_type in js_type.IterTypes():
561 js_type = flag and flag.jstype562 if flag and flag.flag_type in state.GetDocFlag().HAS_TYPE and js_type:563 self._MarkAliasUsed(js_type)565 def _MarkAliasUsed(self, js_type): argument576 if js_type.alias:577 self._MarkLocalVariableUsed(js_type.identifier)578 for sub_type in js_type.IterTypes():
179 def _CheckJsDocType(self, token, js_type): argument186 if not js_type: return188 if js_type.type_group and len(js_type.sub_types) == 2:189 identifiers = [t.identifier for t in js_type.sub_types]195 'Prefer "?Type" to "Type|null": "%s"' % js_type, token)200 for sub_type in js_type.IterTypes():