Merge pull request #19137 from github/redsun82/rust-renames

Rust: rename several entities to their more natural names
This commit is contained in:
Paolo Tranquilli
2025-03-31 14:03:34 +02:00
committed by GitHub
141 changed files with 628 additions and 703 deletions

View File

@@ -72,7 +72,7 @@ repos:
- id: rust-codegen
name: Run Rust checked in code generation
files: ^misc/codegen/|^rust/(prefix\.dbscheme|schema/|codegen/|.*/generated/|ql/lib/(rust\.dbscheme$|codeql/rust/elements)|\.generated.list)
files: ^misc/codegen/|^rust/(prefix\.dbscheme|schema/|codegen/|.*/generated/|ql/lib/(rust\.dbscheme$|codeql/rust/elements)|\.generated.list|ast-generator/)
language: system
entry: bazel run //rust/codegen -- --quiet
pass_filenames: false

View File

@@ -23,9 +23,7 @@ fn class_name(type_name: &str) -> String {
"Literal" => "LiteralExpr".to_owned(),
"ArrayExpr" => "ArrayExprInternal".to_owned(),
"AsmOptions" => "AsmOptionsList".to_owned(),
_ if type_name.starts_with("Record") && type_name != "RecordFieldList" => {
type_name.replacen("Record", "Struct", 1)
}
_ if type_name.starts_with("Record") => type_name.replacen("Record", "Struct", 1),
_ if type_name.ends_with("Type") => format!("{}Repr", type_name),
_ => type_name.to_owned(),
}
@@ -36,10 +34,14 @@ fn property_name(type_name: &str, field_name: &str) -> String {
("CallExpr", "expr") => "function",
("LetExpr", "expr") => "scrutinee",
("MatchExpr", "expr") => "scrutinee",
("Variant", "expr") => "discriminant",
("FieldExpr", "expr") => "container",
(_, "name_ref") => "identifier",
(_, "then_branch") => "then",
(_, "else_branch") => "else_",
("ArrayType", "ty") => "element_type_repr",
("ArrayTypeRepr", "ty") => "element_type_repr",
("SelfParam", "is_amp") => "is_ref",
("StructField", "expr") => "default",
("UseTree", "is_star") => "is_glob",
(_, "ty") => "type_repr",
_ if field_name.contains("record") => &field_name.replacen("record", "struct", 1),
@@ -103,25 +105,27 @@ fn node_src_to_schema_class(
node: &AstNodeSrc,
super_types: &BTreeMap<String, BTreeSet<String>>,
) -> SchemaClass {
let name = class_name(&node.name);
let fields = get_fields(node)
.iter()
.map(|f| {
let (ty, child) = match &f.ty {
FieldType::String => ("optional[string]".to_string(), false),
FieldType::Predicate => ("predicate".to_string(), false),
FieldType::Optional(ty) => (format!("optional[\"{}\"]", class_name(ty)), true),
FieldType::List(ty) => (format!("list[\"{}\"]", class_name(ty)), true),
};
SchemaField {
name: property_name(&name, &f.name),
ty,
child,
}
})
.collect();
SchemaClass {
name: class_name(&node.name),
name,
fields,
bases: get_bases(&node.name, super_types),
fields: get_fields(node)
.iter()
.map(|f| {
let (ty, child) = match &f.ty {
FieldType::String => ("optional[string]".to_string(), false),
FieldType::Predicate => ("predicate".to_string(), false),
FieldType::Optional(ty) => (format!("optional[\"{}\"]", class_name(ty)), true),
FieldType::List(ty) => (format!("list[\"{}\"]", class_name(ty)), true),
};
SchemaField {
name: property_name(&node.name, &f.name),
ty,
child,
}
})
.collect(),
}
}
@@ -428,6 +432,7 @@ fn get_fields(node: &AstNodeSrc) -> Vec<FieldInfo> {
struct EnumVariantInfo {
name: String,
snake_case_name: String,
variant_ast_name: String,
}
#[derive(Serialize)]
@@ -476,16 +481,21 @@ fn enum_to_extractor_info(node: &AstEnumSrc) -> Option<ExtractorEnumInfo> {
variants: node
.variants
.iter()
.map(|v| EnumVariantInfo {
name: v.clone(),
snake_case_name: to_lower_snake_case(v),
.map(|v| {
let name = class_name(v);
let snake_case_name = to_lower_snake_case(v);
EnumVariantInfo {
name,
snake_case_name,
variant_ast_name: v.clone(),
}
})
.collect(),
})
}
fn field_info_to_extractor_info(node: &AstNodeSrc, field: &FieldInfo) -> ExtractorNodeFieldInfo {
let name = property_name(&node.name, &field.name);
fn field_info_to_extractor_info(name: &str, field: &FieldInfo) -> ExtractorNodeFieldInfo {
let name = property_name(name, &field.name);
match &field.ty {
FieldType::String => ExtractorNodeFieldInfo {
name,
@@ -517,14 +527,16 @@ fn field_info_to_extractor_info(node: &AstNodeSrc, field: &FieldInfo) -> Extract
fn node_to_extractor_info(node: &AstNodeSrc) -> ExtractorNodeInfo {
let fields = get_fields(node);
let has_attrs = fields.iter().any(|f| f.name == "attrs");
let name = class_name(&node.name);
let fields = fields
.iter()
.map(|f| field_info_to_extractor_info(&name, f))
.collect();
ExtractorNodeInfo {
name: class_name(&node.name),
name,
snake_case_name: to_lower_snake_case(&node.name),
ast_name: node.name.clone(),
fields: fields
.iter()
.map(|f| field_info_to_extractor_info(node, f))
.collect(),
fields,
has_attrs,
}
}

View File

@@ -25,7 +25,7 @@ impl Translator<'_> {
pub(crate) fn emit_{{snake_case_name}}(&mut self, node: ast::{{ast_name}}) -> Option<Label<generated::{{name}}>> {
match node {
{{#variants}}
ast::{{ast_name}}::{{name}}(inner) => self.emit_{{snake_case_name}}(inner).map(Into::into),
ast::{{ast_name}}::{{variant_ast_name}}(inner) => self.emit_{{snake_case_name}}(inner).map(Into::into),
{{/variants}}
}
}

View File

@@ -476,7 +476,7 @@ fn emit_adt(
name,
field_list,
attrs: vec![],
expr: None,
discriminant: None,
visibility,
})
})
@@ -1000,14 +1000,14 @@ fn make_qualified_path(
qualifier: Option<trap::Label<generated::Path>>,
name: String,
) -> trap::Label<generated::Path> {
let name_ref = Some(trap.emit(generated::NameRef {
let identifier = Some(trap.emit(generated::NameRef {
id: trap::TrapId::Star,
text: Some(name),
}));
let segment = Some(trap.emit(generated::PathSegment {
id: trap::TrapId::Star,
generic_arg_list: None,
name_ref,
identifier,
parenthesized_arg_list: None,
ret_type: None,
return_type_syntax: None,
@@ -1253,11 +1253,11 @@ fn emit_hir_ty(
enum Variant {
Unit,
Record(trap::Label<generated::RecordFieldList>),
Record(trap::Label<generated::StructFieldList>),
Tuple(trap::Label<generated::TupleFieldList>),
}
impl From<Variant> for Option<trap::Label<generated::RecordFieldList>> {
impl From<Variant> for Option<trap::Label<generated::StructFieldList>> {
fn from(val: Variant) -> Self {
match val {
Variant::Record(label) => Some(label),
@@ -1305,11 +1305,11 @@ fn emit_variant_data(trap: &mut TrapFile, db: &dyn HirDatabase, variant_id: Vari
name,
type_repr,
visibility,
expr: None,
default: None,
})
})
.collect();
Variant::Record(trap.emit(generated::RecordFieldList {
Variant::Record(trap.emit(generated::StructFieldList {
id: trap::TrapId::Star,
fields,
}))

View File

@@ -1,2 +1,2 @@
mod.rs 4bcb9def847469aae9d8649461546b7c21ec97cf6e63d3cf394e339915ce65d7 4bcb9def847469aae9d8649461546b7c21ec97cf6e63d3cf394e339915ce65d7
top.rs 49e4f3abb137d6eed5a7c5202b3a31c9cafa1f565ee63dd5960e971950fafaa1 49e4f3abb137d6eed5a7c5202b3a31c9cafa1f565ee63dd5960e971950fafaa1
top.rs 50fa90457102611ea7892153e4beb7512d3704a1c78d9bb8e75eb96b98b31740 50fa90457102611ea7892153e4beb7512d3704a1c78d9bb8e75eb96b98b31740

View File

@@ -650,7 +650,7 @@ impl From<trap::Label<AsmPiece>> for trap::Label<Element> {
#[derive(Debug)]
pub struct AsmRegSpec {
pub id: trap::TrapId<AsmRegSpec>,
pub name_ref: Option<trap::Label<NameRef>>,
pub identifier: Option<trap::Label<NameRef>>,
}
impl trap::TrapEntry for AsmRegSpec {
@@ -660,8 +660,8 @@ impl trap::TrapEntry for AsmRegSpec {
fn emit(self, id: trap::Label<Self>, out: &mut trap::Writer) {
out.add_tuple("asm_reg_specs", vec![id.into()]);
if let Some(v) = self.name_ref {
out.add_tuple("asm_reg_spec_name_refs", vec![id.into(), v.into()]);
if let Some(v) = self.identifier {
out.add_tuple("asm_reg_spec_identifiers", vec![id.into(), v.into()]);
}
}
}
@@ -2081,7 +2081,7 @@ impl From<trap::Label<Path>> for trap::Label<Element> {
pub struct PathSegment {
pub id: trap::TrapId<PathSegment>,
pub generic_arg_list: Option<trap::Label<GenericArgList>>,
pub name_ref: Option<trap::Label<NameRef>>,
pub identifier: Option<trap::Label<NameRef>>,
pub parenthesized_arg_list: Option<trap::Label<ParenthesizedArgList>>,
pub ret_type: Option<trap::Label<RetTypeRepr>>,
pub return_type_syntax: Option<trap::Label<ReturnTypeSyntax>>,
@@ -2097,8 +2097,8 @@ impl trap::TrapEntry for PathSegment {
if let Some(v) = self.generic_arg_list {
out.add_tuple("path_segment_generic_arg_lists", vec![id.into(), v.into()]);
}
if let Some(v) = self.name_ref {
out.add_tuple("path_segment_name_refs", vec![id.into(), v.into()]);
if let Some(v) = self.identifier {
out.add_tuple("path_segment_identifiers", vec![id.into(), v.into()]);
}
if let Some(v) = self.parenthesized_arg_list {
out.add_tuple("path_segment_parenthesized_arg_lists", vec![id.into(), v.into()]);
@@ -2496,7 +2496,7 @@ pub struct StructExprField {
pub id: trap::TrapId<StructExprField>,
pub attrs: Vec<trap::Label<Attr>>,
pub expr: Option<trap::Label<Expr>>,
pub name_ref: Option<trap::Label<NameRef>>,
pub identifier: Option<trap::Label<NameRef>>,
}
impl trap::TrapEntry for StructExprField {
@@ -2512,8 +2512,8 @@ impl trap::TrapEntry for StructExprField {
if let Some(v) = self.expr {
out.add_tuple("struct_expr_field_exprs", vec![id.into(), v.into()]);
}
if let Some(v) = self.name_ref {
out.add_tuple("struct_expr_field_name_refs", vec![id.into(), v.into()]);
if let Some(v) = self.identifier {
out.add_tuple("struct_expr_field_identifiers", vec![id.into(), v.into()]);
}
}
}
@@ -2611,7 +2611,7 @@ impl From<trap::Label<StructExprFieldList>> for trap::Label<Element> {
pub struct StructField {
pub id: trap::TrapId<StructField>,
pub attrs: Vec<trap::Label<Attr>>,
pub expr: Option<trap::Label<Expr>>,
pub default: Option<trap::Label<Expr>>,
pub name: Option<trap::Label<Name>>,
pub type_repr: Option<trap::Label<TypeRepr>>,
pub visibility: Option<trap::Label<Visibility>>,
@@ -2627,8 +2627,8 @@ impl trap::TrapEntry for StructField {
for (i, v) in self.attrs.into_iter().enumerate() {
out.add_tuple("struct_field_attrs", vec![id.into(), i.into(), v.into()]);
}
if let Some(v) = self.expr {
out.add_tuple("struct_field_exprs", vec![id.into(), v.into()]);
if let Some(v) = self.default {
out.add_tuple("struct_field_defaults", vec![id.into(), v.into()]);
}
if let Some(v) = self.name {
out.add_tuple("struct_field_names", vec![id.into(), v.into()]);
@@ -2677,7 +2677,7 @@ impl From<trap::Label<StructField>> for trap::Label<Element> {
pub struct StructPatField {
pub id: trap::TrapId<StructPatField>,
pub attrs: Vec<trap::Label<Attr>>,
pub name_ref: Option<trap::Label<NameRef>>,
pub identifier: Option<trap::Label<NameRef>>,
pub pat: Option<trap::Label<Pat>>,
}
@@ -2691,8 +2691,8 @@ impl trap::TrapEntry for StructPatField {
for (i, v) in self.attrs.into_iter().enumerate() {
out.add_tuple("struct_pat_field_attrs", vec![id.into(), i.into(), v.into()]);
}
if let Some(v) = self.name_ref {
out.add_tuple("struct_pat_field_name_refs", vec![id.into(), v.into()]);
if let Some(v) = self.identifier {
out.add_tuple("struct_pat_field_identifiers", vec![id.into(), v.into()]);
}
if let Some(v) = self.pat {
out.add_tuple("struct_pat_field_pats", vec![id.into(), v.into()]);
@@ -4150,7 +4150,7 @@ pub struct AssocTypeArg {
pub id: trap::TrapId<AssocTypeArg>,
pub const_arg: Option<trap::Label<ConstArg>>,
pub generic_arg_list: Option<trap::Label<GenericArgList>>,
pub name_ref: Option<trap::Label<NameRef>>,
pub identifier: Option<trap::Label<NameRef>>,
pub param_list: Option<trap::Label<ParamList>>,
pub ret_type: Option<trap::Label<RetTypeRepr>>,
pub return_type_syntax: Option<trap::Label<ReturnTypeSyntax>>,
@@ -4171,8 +4171,8 @@ impl trap::TrapEntry for AssocTypeArg {
if let Some(v) = self.generic_arg_list {
out.add_tuple("assoc_type_arg_generic_arg_lists", vec![id.into(), v.into()]);
}
if let Some(v) = self.name_ref {
out.add_tuple("assoc_type_arg_name_refs", vec![id.into(), v.into()]);
if let Some(v) = self.identifier {
out.add_tuple("assoc_type_arg_identifiers", vec![id.into(), v.into()]);
}
if let Some(v) = self.param_list {
out.add_tuple("assoc_type_arg_param_lists", vec![id.into(), v.into()]);
@@ -5210,8 +5210,8 @@ impl From<trap::Label<ExprStmt>> for trap::Label<Element> {
pub struct FieldExpr {
pub id: trap::TrapId<FieldExpr>,
pub attrs: Vec<trap::Label<Attr>>,
pub expr: Option<trap::Label<Expr>>,
pub name_ref: Option<trap::Label<NameRef>>,
pub container: Option<trap::Label<Expr>>,
pub identifier: Option<trap::Label<NameRef>>,
}
impl trap::TrapEntry for FieldExpr {
@@ -5224,11 +5224,11 @@ impl trap::TrapEntry for FieldExpr {
for (i, v) in self.attrs.into_iter().enumerate() {
out.add_tuple("field_expr_attrs", vec![id.into(), i.into(), v.into()]);
}
if let Some(v) = self.expr {
out.add_tuple("field_expr_exprs", vec![id.into(), v.into()]);
if let Some(v) = self.container {
out.add_tuple("field_expr_containers", vec![id.into(), v.into()]);
}
if let Some(v) = self.name_ref {
out.add_tuple("field_expr_name_refs", vec![id.into(), v.into()]);
if let Some(v) = self.identifier {
out.add_tuple("field_expr_identifiers", vec![id.into(), v.into()]);
}
}
}
@@ -7510,65 +7510,6 @@ impl From<trap::Label<RangePat>> for trap::Label<Element> {
}
}
#[derive(Debug)]
pub struct RecordFieldList {
pub id: trap::TrapId<RecordFieldList>,
pub fields: Vec<trap::Label<StructField>>,
}
impl trap::TrapEntry for RecordFieldList {
fn extract_id(&mut self) -> trap::TrapId<Self> {
std::mem::replace(&mut self.id, trap::TrapId::Star)
}
fn emit(self, id: trap::Label<Self>, out: &mut trap::Writer) {
out.add_tuple("record_field_lists", vec![id.into()]);
for (i, v) in self.fields.into_iter().enumerate() {
out.add_tuple("record_field_list_fields", vec![id.into(), i.into(), v.into()]);
}
}
}
impl trap::TrapClass for RecordFieldList {
fn class_name() -> &'static str { "RecordFieldList" }
}
impl From<trap::Label<RecordFieldList>> for trap::Label<FieldList> {
fn from(value: trap::Label<RecordFieldList>) -> Self {
// SAFETY: this is safe because in the dbscheme RecordFieldList is a subclass of FieldList
unsafe {
Self::from_untyped(value.as_untyped())
}
}
}
impl From<trap::Label<RecordFieldList>> for trap::Label<AstNode> {
fn from(value: trap::Label<RecordFieldList>) -> Self {
// SAFETY: this is safe because in the dbscheme RecordFieldList is a subclass of AstNode
unsafe {
Self::from_untyped(value.as_untyped())
}
}
}
impl From<trap::Label<RecordFieldList>> for trap::Label<Locatable> {
fn from(value: trap::Label<RecordFieldList>) -> Self {
// SAFETY: this is safe because in the dbscheme RecordFieldList is a subclass of Locatable
unsafe {
Self::from_untyped(value.as_untyped())
}
}
}
impl From<trap::Label<RecordFieldList>> for trap::Label<Element> {
fn from(value: trap::Label<RecordFieldList>) -> Self {
// SAFETY: this is safe because in the dbscheme RecordFieldList is a subclass of Element
unsafe {
Self::from_untyped(value.as_untyped())
}
}
}
#[derive(Debug)]
pub struct RefExpr {
pub id: trap::TrapId<RefExpr>,
@@ -8093,6 +8034,65 @@ impl From<trap::Label<SliceTypeRepr>> for trap::Label<Element> {
}
}
#[derive(Debug)]
pub struct StructFieldList {
pub id: trap::TrapId<StructFieldList>,
pub fields: Vec<trap::Label<StructField>>,
}
impl trap::TrapEntry for StructFieldList {
fn extract_id(&mut self) -> trap::TrapId<Self> {
std::mem::replace(&mut self.id, trap::TrapId::Star)
}
fn emit(self, id: trap::Label<Self>, out: &mut trap::Writer) {
out.add_tuple("struct_field_lists", vec![id.into()]);
for (i, v) in self.fields.into_iter().enumerate() {
out.add_tuple("struct_field_list_fields", vec![id.into(), i.into(), v.into()]);
}
}
}
impl trap::TrapClass for StructFieldList {
fn class_name() -> &'static str { "StructFieldList" }
}
impl From<trap::Label<StructFieldList>> for trap::Label<FieldList> {
fn from(value: trap::Label<StructFieldList>) -> Self {
// SAFETY: this is safe because in the dbscheme StructFieldList is a subclass of FieldList
unsafe {
Self::from_untyped(value.as_untyped())
}
}
}
impl From<trap::Label<StructFieldList>> for trap::Label<AstNode> {
fn from(value: trap::Label<StructFieldList>) -> Self {
// SAFETY: this is safe because in the dbscheme StructFieldList is a subclass of AstNode
unsafe {
Self::from_untyped(value.as_untyped())
}
}
}
impl From<trap::Label<StructFieldList>> for trap::Label<Locatable> {
fn from(value: trap::Label<StructFieldList>) -> Self {
// SAFETY: this is safe because in the dbscheme StructFieldList is a subclass of Locatable
unsafe {
Self::from_untyped(value.as_untyped())
}
}
}
impl From<trap::Label<StructFieldList>> for trap::Label<Element> {
fn from(value: trap::Label<StructFieldList>) -> Self {
// SAFETY: this is safe because in the dbscheme StructFieldList is a subclass of Element
unsafe {
Self::from_untyped(value.as_untyped())
}
}
}
#[derive(Debug)]
pub struct TryExpr {
pub id: trap::TrapId<TryExpr>,
@@ -8589,7 +8589,7 @@ impl From<trap::Label<UnderscoreExpr>> for trap::Label<Element> {
pub struct Variant {
pub id: trap::TrapId<Variant>,
pub attrs: Vec<trap::Label<Attr>>,
pub expr: Option<trap::Label<Expr>>,
pub discriminant: Option<trap::Label<Expr>>,
pub field_list: Option<trap::Label<FieldList>>,
pub name: Option<trap::Label<Name>>,
pub visibility: Option<trap::Label<Visibility>>,
@@ -8605,8 +8605,8 @@ impl trap::TrapEntry for Variant {
for (i, v) in self.attrs.into_iter().enumerate() {
out.add_tuple("variant_attrs", vec![id.into(), i.into(), v.into()]);
}
if let Some(v) = self.expr {
out.add_tuple("variant_exprs", vec![id.into(), v.into()]);
if let Some(v) = self.discriminant {
out.add_tuple("variant_discriminants", vec![id.into(), v.into()]);
}
if let Some(v) = self.field_list {
out.add_tuple("variant_field_lists", vec![id.into(), v.into()]);
@@ -9326,7 +9326,7 @@ impl From<trap::Label<ExternBlock>> for trap::Label<Addressable> {
pub struct ExternCrate {
pub id: trap::TrapId<ExternCrate>,
pub attrs: Vec<trap::Label<Attr>>,
pub name_ref: Option<trap::Label<NameRef>>,
pub identifier: Option<trap::Label<NameRef>>,
pub rename: Option<trap::Label<Rename>>,
pub visibility: Option<trap::Label<Visibility>>,
}
@@ -9341,8 +9341,8 @@ impl trap::TrapEntry for ExternCrate {
for (i, v) in self.attrs.into_iter().enumerate() {
out.add_tuple("extern_crate_attrs", vec![id.into(), i.into(), v.into()]);
}
if let Some(v) = self.name_ref {
out.add_tuple("extern_crate_name_refs", vec![id.into(), v.into()]);
if let Some(v) = self.identifier {
out.add_tuple("extern_crate_identifiers", vec![id.into(), v.into()]);
}
if let Some(v) = self.rename {
out.add_tuple("extern_crate_renames", vec![id.into(), v.into()]);
@@ -10031,7 +10031,7 @@ pub struct MethodCallExpr {
pub arg_list: Option<trap::Label<ArgList>>,
pub attrs: Vec<trap::Label<Attr>>,
pub generic_arg_list: Option<trap::Label<GenericArgList>>,
pub name_ref: Option<trap::Label<NameRef>>,
pub identifier: Option<trap::Label<NameRef>>,
pub receiver: Option<trap::Label<Expr>>,
}
@@ -10051,8 +10051,8 @@ impl trap::TrapEntry for MethodCallExpr {
if let Some(v) = self.generic_arg_list {
out.add_tuple("method_call_expr_generic_arg_lists", vec![id.into(), v.into()]);
}
if let Some(v) = self.name_ref {
out.add_tuple("method_call_expr_name_refs", vec![id.into(), v.into()]);
if let Some(v) = self.identifier {
out.add_tuple("method_call_expr_identifiers", vec![id.into(), v.into()]);
}
if let Some(v) = self.receiver {
out.add_tuple("method_call_expr_receivers", vec![id.into(), v.into()]);
@@ -10510,7 +10510,7 @@ impl trap::TrapEntry for Struct {
out.add_tuple("struct_attrs", vec![id.into(), i.into(), v.into()]);
}
if let Some(v) = self.field_list {
out.add_tuple("struct_field_lists", vec![id.into(), v.into()]);
out.add_tuple("struct_field_lists_", vec![id.into(), v.into()]);
}
if let Some(v) = self.generic_param_list {
out.add_tuple("struct_generic_param_lists", vec![id.into(), v.into()]);
@@ -11172,7 +11172,7 @@ pub struct Union {
pub attrs: Vec<trap::Label<Attr>>,
pub generic_param_list: Option<trap::Label<GenericParamList>>,
pub name: Option<trap::Label<Name>>,
pub struct_field_list: Option<trap::Label<RecordFieldList>>,
pub struct_field_list: Option<trap::Label<StructFieldList>>,
pub visibility: Option<trap::Label<Visibility>>,
pub where_clause: Option<trap::Label<WhereClause>>,
}

View File

@@ -385,10 +385,10 @@ impl Translator<'_> {
}
pub(crate) fn emit_asm_reg_spec(&mut self, node: ast::AsmRegSpec) -> Option<Label<generated::AsmRegSpec>> {
let name_ref = node.name_ref().and_then(|x| self.emit_name_ref(x));
let identifier = node.name_ref().and_then(|x| self.emit_name_ref(x));
let label = self.trap.emit(generated::AsmRegSpec {
id: TrapId::Star,
name_ref,
identifier,
});
self.emit_location(label, &node);
emit_detached!(AsmRegSpec, self, node, label);
@@ -426,7 +426,7 @@ impl Translator<'_> {
pub(crate) fn emit_assoc_type_arg(&mut self, node: ast::AssocTypeArg) -> Option<Label<generated::AssocTypeArg>> {
let const_arg = node.const_arg().and_then(|x| self.emit_const_arg(x));
let generic_arg_list = node.generic_arg_list().and_then(|x| self.emit_generic_arg_list(x));
let name_ref = node.name_ref().and_then(|x| self.emit_name_ref(x));
let identifier = node.name_ref().and_then(|x| self.emit_name_ref(x));
let param_list = node.param_list().and_then(|x| self.emit_param_list(x));
let ret_type = node.ret_type().and_then(|x| self.emit_ret_type(x));
let return_type_syntax = node.return_type_syntax().and_then(|x| self.emit_return_type_syntax(x));
@@ -436,7 +436,7 @@ impl Translator<'_> {
id: TrapId::Star,
const_arg,
generic_arg_list,
name_ref,
identifier,
param_list,
ret_type,
return_type_syntax,
@@ -801,13 +801,13 @@ impl Translator<'_> {
pub(crate) fn emit_extern_crate(&mut self, node: ast::ExternCrate) -> Option<Label<generated::ExternCrate>> {
if self.should_be_excluded(&node) { return None; }
let attrs = node.attrs().filter_map(|x| self.emit_attr(x)).collect();
let name_ref = node.name_ref().and_then(|x| self.emit_name_ref(x));
let identifier = node.name_ref().and_then(|x| self.emit_name_ref(x));
let rename = node.rename().and_then(|x| self.emit_rename(x));
let visibility = node.visibility().and_then(|x| self.emit_visibility(x));
let label = self.trap.emit(generated::ExternCrate {
id: TrapId::Star,
attrs,
name_ref,
identifier,
rename,
visibility,
});
@@ -835,13 +835,13 @@ impl Translator<'_> {
pub(crate) fn emit_field_expr(&mut self, node: ast::FieldExpr) -> Option<Label<generated::FieldExpr>> {
if self.should_be_excluded(&node) { return None; }
let attrs = node.attrs().filter_map(|x| self.emit_attr(x)).collect();
let expr = node.expr().and_then(|x| self.emit_expr(x));
let name_ref = node.name_ref().and_then(|x| self.emit_name_ref(x));
let container = node.expr().and_then(|x| self.emit_expr(x));
let identifier = node.name_ref().and_then(|x| self.emit_name_ref(x));
let label = self.trap.emit(generated::FieldExpr {
id: TrapId::Star,
attrs,
expr,
name_ref,
container,
identifier,
});
self.emit_location(label, &node);
emit_detached!(FieldExpr, self, node, label);
@@ -1477,14 +1477,14 @@ impl Translator<'_> {
let arg_list = node.arg_list().and_then(|x| self.emit_arg_list(x));
let attrs = node.attrs().filter_map(|x| self.emit_attr(x)).collect();
let generic_arg_list = node.generic_arg_list().and_then(|x| self.emit_generic_arg_list(x));
let name_ref = node.name_ref().and_then(|x| self.emit_name_ref(x));
let identifier = node.name_ref().and_then(|x| self.emit_name_ref(x));
let receiver = node.receiver().and_then(|x| self.emit_expr(x));
let label = self.trap.emit(generated::MethodCallExpr {
id: TrapId::Star,
arg_list,
attrs,
generic_arg_list,
name_ref,
identifier,
receiver,
});
self.emit_location(label, &node);
@@ -1700,14 +1700,14 @@ impl Translator<'_> {
pub(crate) fn emit_path_segment(&mut self, node: ast::PathSegment) -> Option<Label<generated::PathSegment>> {
let generic_arg_list = node.generic_arg_list().and_then(|x| self.emit_generic_arg_list(x));
let name_ref = node.name_ref().and_then(|x| self.emit_name_ref(x));
let identifier = node.name_ref().and_then(|x| self.emit_name_ref(x));
let parenthesized_arg_list = node.parenthesized_arg_list().and_then(|x| self.emit_parenthesized_arg_list(x));
let ret_type = node.ret_type().and_then(|x| self.emit_ret_type(x));
let return_type_syntax = node.return_type_syntax().and_then(|x| self.emit_return_type_syntax(x));
let label = self.trap.emit(generated::PathSegment {
id: TrapId::Star,
generic_arg_list,
name_ref,
identifier,
parenthesized_arg_list,
ret_type,
return_type_syntax,
@@ -1816,12 +1816,12 @@ impl Translator<'_> {
if self.should_be_excluded(&node) { return None; }
let attrs = node.attrs().filter_map(|x| self.emit_attr(x)).collect();
let expr = node.expr().and_then(|x| self.emit_expr(x));
let name_ref = node.name_ref().and_then(|x| self.emit_name_ref(x));
let identifier = node.name_ref().and_then(|x| self.emit_name_ref(x));
let label = self.trap.emit(generated::StructExprField {
id: TrapId::Star,
attrs,
expr,
name_ref,
identifier,
});
self.emit_location(label, &node);
emit_detached!(StructExprField, self, node, label);
@@ -1849,14 +1849,14 @@ impl Translator<'_> {
pub(crate) fn emit_record_field(&mut self, node: ast::RecordField) -> Option<Label<generated::StructField>> {
if self.should_be_excluded(&node) { return None; }
let attrs = node.attrs().filter_map(|x| self.emit_attr(x)).collect();
let expr = node.expr().and_then(|x| self.emit_expr(x));
let default = node.expr().and_then(|x| self.emit_expr(x));
let name = node.name().and_then(|x| self.emit_name(x));
let type_repr = node.ty().and_then(|x| self.emit_type(x));
let visibility = node.visibility().and_then(|x| self.emit_visibility(x));
let label = self.trap.emit(generated::StructField {
id: TrapId::Star,
attrs,
expr,
default,
name,
type_repr,
visibility,
@@ -1867,14 +1867,14 @@ impl Translator<'_> {
Some(label)
}
pub(crate) fn emit_record_field_list(&mut self, node: ast::RecordFieldList) -> Option<Label<generated::RecordFieldList>> {
pub(crate) fn emit_record_field_list(&mut self, node: ast::RecordFieldList) -> Option<Label<generated::StructFieldList>> {
let fields = node.fields().filter_map(|x| self.emit_record_field(x)).collect();
let label = self.trap.emit(generated::RecordFieldList {
let label = self.trap.emit(generated::StructFieldList {
id: TrapId::Star,
fields,
});
self.emit_location(label, &node);
emit_detached!(RecordFieldList, self, node, label);
emit_detached!(StructFieldList, self, node, label);
self.emit_tokens(&node, label.into(), node.syntax().children_with_tokens());
Some(label)
}
@@ -1896,12 +1896,12 @@ impl Translator<'_> {
pub(crate) fn emit_record_pat_field(&mut self, node: ast::RecordPatField) -> Option<Label<generated::StructPatField>> {
if self.should_be_excluded(&node) { return None; }
let attrs = node.attrs().filter_map(|x| self.emit_attr(x)).collect();
let name_ref = node.name_ref().and_then(|x| self.emit_name_ref(x));
let identifier = node.name_ref().and_then(|x| self.emit_name_ref(x));
let pat = node.pat().and_then(|x| self.emit_pat(x));
let label = self.trap.emit(generated::StructPatField {
id: TrapId::Star,
attrs,
name_ref,
identifier,
pat,
});
self.emit_location(label, &node);
@@ -2513,14 +2513,14 @@ impl Translator<'_> {
pub(crate) fn emit_variant(&mut self, node: ast::Variant) -> Option<Label<generated::Variant>> {
if self.should_be_excluded(&node) { return None; }
let attrs = node.attrs().filter_map(|x| self.emit_attr(x)).collect();
let expr = node.expr().and_then(|x| self.emit_expr(x));
let discriminant = node.expr().and_then(|x| self.emit_expr(x));
let field_list = node.field_list().and_then(|x| self.emit_field_list(x));
let name = node.name().and_then(|x| self.emit_name(x));
let visibility = node.visibility().and_then(|x| self.emit_visibility(x));
let label = self.trap.emit(generated::Variant {
id: TrapId::Star,
attrs,
expr,
discriminant,
field_list,
name,
visibility,

View File

@@ -1,4 +1,4 @@
lib/codeql/rust/controlflow/internal/generated/CfgNodes.qll 2fc9c20eb37521ebf57fc755b6d4f3725ea74e790f21944c8f24acd64f8504ed 118451f6047dd5c9400ea318878c769f4d85912a04973d175bdc35870285dd50
lib/codeql/rust/controlflow/internal/generated/CfgNodes.qll d1cc3cfc9ae558b1cb473e3bfca66e5c424445b98ce343eb6f3050321fe4f8a0 8d00e385230b45360bc6281af01e0f674c58117593fd1b3cb7eb0c8a45517542
lib/codeql/rust/elements/Abi.qll 4c973d28b6d628f5959d1f1cc793704572fd0acaae9a97dfce82ff9d73f73476 250f68350180af080f904cd34cb2af481c5c688dc93edf7365fd0ae99855e893
lib/codeql/rust/elements/Addressable.qll 13011bfd2e1556694c3d440cc34af8527da4df49ad92b62f2939d3699ff2cea5 ddb25935f7553a1a384b1abe2e4b4fa90ab50b952dadec32fd867afcb054f4be
lib/codeql/rust/elements/ArgList.qll 661f5100f5d3ef8351452d9058b663a2a5c720eea8cf11bedd628969741486a2 28e424aac01a90fb58cd6f9f83c7e4cf379eea39e636bc0ba07efc818be71c71
@@ -129,7 +129,6 @@ lib/codeql/rust/elements/PrefixExpr.qll 107e7bd111b637fd6d76026062d54c2780760b96
lib/codeql/rust/elements/PtrTypeRepr.qll 2eb2b6f6e5858a10fa1b10d85400ed6db781339bf152162a2fd33213c1ce083b bb99c2da04c80d3c14f47cda1feb9719af801d209becb3d9b20746a2a3b8fc02
lib/codeql/rust/elements/RangeExpr.qll 43785bea08a6a537010db1138e68ae92eed7e481744188dfb3bad119425ff740 5e81cfbdf4617372a73d662a248a0b380c1f40988a5daefb7f00057cae10d3d4
lib/codeql/rust/elements/RangePat.qll b5c0cfc84b8a767d58593fa7102dcf4be3ff8b02ba2f5360c384fa8af4aac830 cc28399dd99630bfa50c54e641a3833abe6643137d010a0a25749d1d70e8c911
lib/codeql/rust/elements/RecordFieldList.qll e067a0111ef4eb442236a265b6e492ffe17886a18650324a52cc0f9fe98aae50 816d98a3c6b387b5b40cbe221f53f676ea5107e1ddbea628f02b5f9e3b5ddf0c
lib/codeql/rust/elements/RefExpr.qll 91a0d3a86002289dc01ffbe8daca13e34e92e522fbb508241a9d51faf1d4a9d2 b6e63d8e6f8956d2501706d129a6f5f24b410ea6539839757c76ba950c410582
lib/codeql/rust/elements/RefPat.qll fe076bdccb454111b38f360837d180274ba8a003b4cffe910b5197cd74188089 2604c8bb2b0b47091d5fc4aa276de46fe3561e346bd98f291c3783cef402ba06
lib/codeql/rust/elements/RefTypeRepr.qll ac41d8b4132f273d65873ea3c59631bc1718b3266ae08075346e6cb1bfe2f17c b7e34851d37008806d4519105a5e3405dda07b999294c6656a0c447ac1635b2a
@@ -151,6 +150,7 @@ lib/codeql/rust/elements/StructExpr.qll af9059c01a97755e94f1a8b60c66d9c7663ed070
lib/codeql/rust/elements/StructExprField.qll 3eb9f17ecd1ad38679689eb4ecc169d3a0b5b7a3fc597ae5a957a7aea2f74e4f 8fcd26f266f203004899a60447ba16e7eae4e3a654fbec7f54e26857730ede93
lib/codeql/rust/elements/StructExprFieldList.qll 6f77363f93ce4e55d91cc93cef4451b93b9714a4aec91c5416d488191340a079 4da6b070125150f2d28028e29095df93e0bbdb5bc4bd4c672e060492f36367c4
lib/codeql/rust/elements/StructField.qll cd6ebb8927eb2614aa1241f03702b1db06e6c581acc368966c2809adb62a3cff 792a2040847a5e6ef3efcc33eeffa9df0bf720a5c39204ac5533bf85b2f9e9bd
lib/codeql/rust/elements/StructFieldList.qll 384a8dab7b1bb70151bfc8cb378ebffbea8e5112f92cf26f1c6f2fd0eb9d2e35 6ee3cc6952a134f6f4d6988700f45eb51d23d19f3c08d63a868d9ad8e54be12a
lib/codeql/rust/elements/StructPat.qll cdd1e8417d1c8cb3d14356390d71eb2916a295d95f240f48d4c2fb21bf4398cb 69c3456a13ef3e978a9a145b9e232198a30360f771feb41a917e507410611f6c
lib/codeql/rust/elements/StructPatField.qll 856aa7d7c6d9b3c17514cbd12a36164e6e9d5923245770d0af3afb759a15204a 1bd1a294d84ad5e4da24e03b4882b215c50473875014859dbf26555d1f4ec2d5
lib/codeql/rust/elements/StructPatFieldList.qll e32d5adc36dc9800454920c784098680b22d3c1c31754bbb65db1a226105b3b0 0ecfd969411a56ebf04f6a4950219b9128b66151c115fcd734d89687f3f5e524
@@ -174,7 +174,7 @@ lib/codeql/rust/elements/TypeRepr.qll ea41b05ef0aaac71da460f9a6a8331cf98166f2c38
lib/codeql/rust/elements/UnderscoreExpr.qll 233661b82b87c8cda16d8f2e17965658c3dc6b69efb23cb8eb9c4f50c68521e0 8edff8e80aac2ecf83a6b58f310cab688cbaeea0a0e68a298b644e565960cc74
lib/codeql/rust/elements/Unextracted.qll 12e60c79ef5b94d72b579b19970622e7b73822ebc13fbcfedfe953527ab1ac36 ec015db2eb12c3c82693ddc71d32d9ab9ef7a958e741e2510681bb707ceca23e
lib/codeql/rust/elements/Unimplemented.qll bf624d28163e5c99accda16c0c99f938bec4a3b1b920a463e86fc8529ff5ff02 013bc7777298d250338f835cd494b5a8accea2d6a4f9561851f283ac129a446b
lib/codeql/rust/elements/Union.qll e8e05763f7004c6a03d0bc4bcc153e12cc9150bb019d165b9ee84657a4c2dfe3 0db02f200220e0af54bf2ec21ccea1d8eba4f9225521d19ca8701786a807b552
lib/codeql/rust/elements/Union.qll 9539358aa47fbe99c0e63d154bf899427bb6d935f3acd00600c11c6396b18565 520612bafb6912001138562a19a691f8b9ca377d5c4bf7aedf49f1b0938eb955
lib/codeql/rust/elements/Use.qll e27d30ece0456a73732dfd867dfc5abdf48a50de56e7dafcab444b688610af72 7efe59c04dd2f10b4a25b8a17beb51362be0a93d73e5a9e1251cf133cf1227c3
lib/codeql/rust/elements/UseBoundGenericArg.qll f16903f8fff676d3700eaad5490804624391141472ecc3166ccb1f70c794c120 5efda98088d096b42f53ceccae78c05f15c6953525b514d849681cb2cf65b147
lib/codeql/rust/elements/UseBoundGenericArgs.qll 6d3b8bf8e59ef6d10d2f58c6d2eca61b113a524174f62d1f56b724c4179fda04 8fad6ed9e5bf159a2db01e7eb960cc55b940f7b92c4bb5c967120068e4fec80a
@@ -367,8 +367,6 @@ lib/codeql/rust/elements/internal/PtrTypeReprImpl.qll 82bb14c7c5764aa6c829d463ed
lib/codeql/rust/elements/internal/RangeExprConstructor.qll a0aa90a1c38c5deea56475399016afae2a00a858b961fbbab8ddeb3bc6a08103 0ddf1bcf28aafc56d7334e6138fb268f9b36a429e4cbdd982cd8384e0644076b
lib/codeql/rust/elements/internal/RangePatConstructor.qll fe4345cb41d970ab64196ca37eccb26e5b9cf85fab4253cacfd2b31de03bd070 1d09d5ec8203d76aed2dfb7e7f14c0c07d6559c8f589e11860fff8a2c682c1a6
lib/codeql/rust/elements/internal/RangePatImpl.qll ef11ab2c002896036553231741a7cf896fafa09e22e920e15661b9cbe4393cae 24ac2dcce3055a77f3a5e0b38cf13aebefd2eeaefa53674ff144a6225634ac0d
lib/codeql/rust/elements/internal/RecordFieldListConstructor.qll 9f1d916f3784092dcbff7224451c8f4f0daf6f8293a466b0a30ec9b92cd41358 8aafe377714a134287362c4b96439c1c6baa5a31c2c36a544bd5f73e9213477a
lib/codeql/rust/elements/internal/RecordFieldListImpl.qll 9446404c45f0dc4473a63eab64669d9a2d25ac67ae230960dd0edd749ba2b9f0 7548d4c7b07c974035da36d83579a0b8a538e088fe834aec50d32591be9766e1
lib/codeql/rust/elements/internal/RefExprConstructor.qll 9ad08c0f3d980a56a2af8857cb84db589941d20ab3ae5c8ece004ccaccaaf950 4cac3ace31b7ed77a72e989fce9cdbae2247f03c28a3f0c50d67385d02c7f193
lib/codeql/rust/elements/internal/RefPatConstructor.qll d8b88c2c468b08072f6f853306eb61eb88ee1e6c5cfb63958f115a64a9715bb3 0c1d6a8af6a66912698acce47e89d4e3239e67f89c228a36a141f9c685c36394
lib/codeql/rust/elements/internal/RefTypeReprConstructor.qll 8e7012b456ebf1cc7a2c50892c0fffd51f0d5d83e417e1d4cabd4d409e3dddc0 4f3c6368bcea5e8c3f0b83591336f01331dc6dabf9c1e8b67de0fc4d640f65f0
@@ -400,6 +398,8 @@ lib/codeql/rust/elements/internal/StructExprFieldConstructor.qll 6766d7941963904
lib/codeql/rust/elements/internal/StructExprFieldListConstructor.qll fda308db380c608d5df1dc48b30bccb32bce31eabff807d0e623b812000a2a2c 84fb7cb24bf61aec602956f867c722d10907b3edfd4dd6946f1349cf6240b4f1
lib/codeql/rust/elements/internal/StructExprFieldListImpl.qll 73aa0a61c2fe5c3cb345b98c1d0bc60474734068ff405061c87406f252ef29ba 66c75d1a449dd9c11db36492f24de13baa98f99d41284ef69298e7b9beb470dc
lib/codeql/rust/elements/internal/StructFieldConstructor.qll 07c7ca8cd5666a0d022573e8d4f9a2e8b237c629c729b9563d783f5e34f232ce 82de0f502272ebdc4f3b15aa314611dd20e82f78ad629e79b5459fdcacf44f9e
lib/codeql/rust/elements/internal/StructFieldListConstructor.qll c4ed03a31f08e63f77411e443635ae20caa82c0b4ce27a8ca0011ddf85602874 9f6c12949ea06f932c141fed8e6f7d2d93e0d3305dfc60db163feb34ada90917
lib/codeql/rust/elements/internal/StructFieldListImpl.qll 93c2b214e315c2fe6a85235fb05c0bfdcd06a03a2246adf551d8c015d28ab9f2 2f80b04deb63785e5766cf78989bb37d69cc9a0372cce737bd544962fc40bb18
lib/codeql/rust/elements/internal/StructPatConstructor.qll 4289608942b7ca73d5a7760232ef23cd9a1baf63cc1d0dc64e7dfea146194fe4 189aec3a5c376addd75b17a79729837fb4185de4abf45008df3956a2d9cdadb8
lib/codeql/rust/elements/internal/StructPatFieldConstructor.qll 780294d2bbad2062a7c66a0dca370e12551d94dd97540936864cf26cbafd7d0e aa9c717f3ec13927be9c598af06ae0b785fb6645a409acf4eaedf07b0b765079
lib/codeql/rust/elements/internal/StructPatFieldListConstructor.qll f67090a3738f2dc89874325c1ec2d4b4d975a5fdef505f0008a016f33868bebb 1c10b9ae42ed78758f59902c44c3eeebb0bd862c04783f83aa4db5653f12bf0e
@@ -479,11 +479,11 @@ lib/codeql/rust/elements/internal/generated/AsmOption.qll d2de2db0f17d55e253f9ca
lib/codeql/rust/elements/internal/generated/AsmOptionsList.qll 43f6f378ac9f88b457096093bedae7d65c3f5c6fa1d5cf83245296ae076a52f0 a632a6a5c7534067e5380b06d5975dbbb4f2ee8155af5c9d79be9f520ff4dbfb
lib/codeql/rust/elements/internal/generated/AsmPiece.qll 17f425727781cdda3a2ec59e20a70e7eb14c75298298e7a014316593fb18f1f9 67656da151f466288d5e7f6cd7723ccb4660df81a9414398c00f7a7c97a19163
lib/codeql/rust/elements/internal/generated/AsmRegOperand.qll 09a8bafe06287f7d6a186a4d3e9db9a7b1038b800ae117ed4ec40d8618d20837 7cb8bf72a6cbc537ef94ef07133e7803a8ef5d391159a5bbbf6b0e36a3378269
lib/codeql/rust/elements/internal/generated/AsmRegSpec.qll 082a4bdb831c3530bd20440551d9216970a01b3e623d7d07e042dc660fc4697a aa2415338805b7394d4a064c0a51e6147bd007aadf1798030e8456e16d6fead3
lib/codeql/rust/elements/internal/generated/AsmRegSpec.qll 9a8003554d574dfb0bae899a1af537c41e445b9eaa245dfc046e6a0813dfa503 c5260bc88bb1fe8b4bd431ce27d95ee91255d06dfa62eeb854b97e959a3f4b71
lib/codeql/rust/elements/internal/generated/AsmSym.qll 9a535efdb6ed0a46a6a0054b91afb1880c9fed8dd841f934a285870aa9a882dd 861c4038d1e86364884cc1ea6d08e0aaf7f278dc15707f69ac0606d94866fdea
lib/codeql/rust/elements/internal/generated/AssocItem.qll aa7c06e001b67e4a59476fa7299e09f8da16c93f91aff0ec9812c64386e7c023 0032b45e34e6aba9c4b3d319b108efa0de8ad679b5f254a1ec7c606877ff5e95
lib/codeql/rust/elements/internal/generated/AssocItemList.qll c53d95395352bb3568198fd18da62e23511c64f19b5aaae4122bd696d402ebf5 3c244f2f0f053903576cdf2b1a15874dee0371caf9fecb5353aceab3c403f532
lib/codeql/rust/elements/internal/generated/AssocTypeArg.qll 9a1fef9d51764a5647e540eb5c07b00c5e4738cd12efc887f05ac74962a15a25 ac564fbd6be444faa3b675c3ec3f979b6c72ebadcdd98a92febf3d83231d8982
lib/codeql/rust/elements/internal/generated/AssocTypeArg.qll 26a84e6e8d1d886d749bf6504d084ee392cd6d51c377af0628dbf675e85d174f 96a571ee8687139c3e9c57cbae0da3136e082e9aa715a025eebbb776e120c417
lib/codeql/rust/elements/internal/generated/AstNode.qll 1cbfae6a732a1de54b56669ee69d875b0e1d15e58d9aa621df9337c59db5619d 37e16a0c70ae69c5dc1b6df241b9acca96a6326d6cca15456699c44a81c93666
lib/codeql/rust/elements/internal/generated/Attr.qll 2e7983b2c462750065ed58cc10c62e42012ddf0dd32f5439df7c6d6bf8ff349d e8270d33a50f088a83a2dfaa5b0a63ec775a6c97c8bf3a9383ce7a1ba8fe8fa3
lib/codeql/rust/elements/internal/generated/AwaitExpr.qll 1d71af702a1f397fb231fae3e0642b3deeba0cd5a43c1d8fabdff29cac979340 e0bfa007bdecc5a09a266d449d723ae35f5a24fbdfc11e4e48aeea3ec0c5147c
@@ -511,11 +511,11 @@ lib/codeql/rust/elements/internal/generated/Enum.qll 4f4cbc9cd758c20d476bc767b91
lib/codeql/rust/elements/internal/generated/Expr.qll 5fa34f2ed21829a1509417440dae42d416234ff43433002974328e7aabb8f30f 46f3972c7413b7db28a3ea8acb5a50a74b6dd9b658e8725f6953a8829ac912f8
lib/codeql/rust/elements/internal/generated/ExprStmt.qll d1112230015fbeb216b43407a268dc2ccd0f9e0836ab2dca4800c51b38fa1d7d 4a80562dcc55efa5e72c6c3b1d6747ab44fe494e76faff2b8f6e9f10a4b08b5b
lib/codeql/rust/elements/internal/generated/ExternBlock.qll c292d804a1f8d2cf6a443be701640c4e87410662921e026d3553bc624fd18abd ba6fae821d2502a97dec636e2d70476ad0693bc6185ae50e8391699529bd0ee0
lib/codeql/rust/elements/internal/generated/ExternCrate.qll 35fea4e810a896c1656adb4682c4c3bc20283768073e26ae064189ce310433c8 fc504dff79ba758d89b10cd5049539fbc766ee9862ff495066cea26abf0b5e0b
lib/codeql/rust/elements/internal/generated/ExternCrate.qll 0cfda7daab7ecbaaab90238f947050a59e3bd0627cbde496b7418300c76358a5 7cb17b4d1b8d206fcb799c71cf123390a9f9a10f65778b581fe82cf2a456cf33
lib/codeql/rust/elements/internal/generated/ExternItem.qll 749b064ad60f32197d5b85e25929afe18e56e12f567b73e21e43e2fdf4c447e3 e2c2d423876675cf2dae399ca442aef7b2860319da9bfadeff29f2c6946f8de7
lib/codeql/rust/elements/internal/generated/ExternItemList.qll 6bc97fdae6c411cab5c501129c1d6c2321c1011cccb119515d75d07dc55c253b 6b5aa808025c0a4270cac540c07ba6faede1b3c70b8db5fd89ec5d46df9041b2
lib/codeql/rust/elements/internal/generated/ExtractorStep.qll 61cd504a1aab98b1c977ee8cff661258351d11ca1fec77038c0a17d359f5810e 5e57b50f3e8e3114a55159fb11a524c6944363f5f8a380abccc8b220dedc70ca
lib/codeql/rust/elements/internal/generated/FieldExpr.qll 3e506b5cb93793ec30f56bb637a600db869fcba6181b068516a671d55c362739 7bbf953696d763ad6b210f378f487ba85b875fa115b22c0c0508599a63633502
lib/codeql/rust/elements/internal/generated/FieldExpr.qll d6077fcc563702bb8d626d2fda60df171023636f98b4a345345e131da1a03dfc 03f9eb65abfab778e6d2c7090c08fe75c38c967302f5a9fa96ab0c24e954929d
lib/codeql/rust/elements/internal/generated/FieldList.qll 575cfd2705113ad5eaf5885cfbcae8b4cb74c4f1192c9905ceb63992187061ad d6571e4238527e93681be4182cc8da35b002e768fbb727b36860c91557e3f430
lib/codeql/rust/elements/internal/generated/FnPtrTypeRepr.qll d490ab9f2e3654d9abde18a06e534abd99ca62f518ca08670b696a97e9d5c592 01500319820f66cb4bbda6fe7c26270f76ea934efff4bb3cbf88e9b1e07e8be2
lib/codeql/rust/elements/internal/generated/ForExpr.qll 6c1838d952be65acaa9744736e73d9bfdcf58d7b392394223bf6fbfdcc172906 44237a248a5aa326a2544e84bc77f536f118f57a98c51562b71ddc81edfcccb8
@@ -564,7 +564,7 @@ lib/codeql/rust/elements/internal/generated/MatchArmList.qll 13362680c037fe83fef
lib/codeql/rust/elements/internal/generated/MatchExpr.qll b686842e7000fd61e3a0598bf245fb4e18167b99eca9162fdfdff0b0963def22 00f1743b1b0f1a92c5a687f5260fda02d80cc5871694cad0d5e7d94bac7fe977
lib/codeql/rust/elements/internal/generated/MatchGuard.qll 521a507883963106780f1782084c581fbcf1179863c7c15438c4db79e30e78dd 6226feffaaa8d828a42ece0c693e616cd375672eb987c3b7ff1ca15fa23c116a
lib/codeql/rust/elements/internal/generated/Meta.qll 38fca2c9958b4179de311546fe0850319010aca9cd17c97d57e12b521c5d0947 740f99c9d41044ceebfcc9d29baaa22f59c11a40f45502a34aa587d423c018f8
lib/codeql/rust/elements/internal/generated/MethodCallExpr.qll 17bffcc826851a8be32a1900b8fdf777f9bab6aed9f8268d566173c4974c1cf9 134a2860bdf16daafdb3e574c52a69d2598210653db89c2fa062ca25e8f8a649
lib/codeql/rust/elements/internal/generated/MethodCallExpr.qll 816267f27f990d655f1ef2304eb73a9468935ffbfddd908773a77fa3860bb970 adda2574300a169a13ea9e33af05c804bf00868d3e8930f0f78d6a8722ad688d
lib/codeql/rust/elements/internal/generated/Missing.qll 16735d91df04a4e1ae52fae25db5f59a044e540755734bbab46b5fbb0fe6b0bd 28ca4e49fb7e6b4734be2f2f69e7c224c570344cc160ef80c5a5cd413e750dad
lib/codeql/rust/elements/internal/generated/Module.qll ebae5d8963c9fd569c0fbad1d7770abd3fd2479437f236cbce0505ba9f9af52c fa3c382115fed18a26f1a755d8749a201b9489f82c09448a88fb8e9e1435fe5f
lib/codeql/rust/elements/internal/generated/Name.qll 12aad57744b7d1b04454159536409244c47319aedd580acb58ee93ef9d7f837d 63fc67ccc085db22f82576a53489f15216a7c29d5b941b14a965eab481534e2e
@@ -579,7 +579,7 @@ lib/codeql/rust/elements/internal/generated/ParamList.qll c808c9d84dd7800573832b
lib/codeql/rust/elements/internal/generated/ParenExpr.qll bc0731505bfe88516205ec360582a4222d2681d11342c93e15258590ddee82f2 d4bd6e0c80cf1d63746c88d4bcb3a01d4c75732e5da09e3ebd9437ced227fb60
lib/codeql/rust/elements/internal/generated/ParenPat.qll 4f168ef5d5bb87a903251cc31b2e44a759b099ec69c90af31783fbb15778c940 0e34f94a45a13396fd57d94c245dc64d1adde2ab0e22b56946f7e94c04e297fc
lib/codeql/rust/elements/internal/generated/ParenTypeRepr.qll 40ab5c592e7699c621787793743e33988de71ff42ca27599f5ab3ddb70e3f7d8 12c0a6eed2202ee3e892f61da3b3ce77ac3190854cdf3097e8d2be98aa3cb91d
lib/codeql/rust/elements/internal/generated/ParentChild.qll d5cda732625e48dabe494d264d2b26df2d2e043ca0503052b551ee2cb1518ab7 9ff0d4634f7be4afada224f9eb3607041ea3461b389401a9f2998099037edffe
lib/codeql/rust/elements/internal/generated/ParentChild.qll 3a9dd595f34bc5841d21f91882b01f2882b18b70e8c718e81d491b4b33bad82b fb40a76aff319ec5f7dae9a05da083b337887b0918b3702641b39342213ddf6f
lib/codeql/rust/elements/internal/generated/ParenthesizedArgList.qll c5fa328ea60d3a3333d7c7bb3480969c1873166c7ac8ebb9d0afad7a8099d1a8 2dbbb6200d96f7db7dea4a55bdeab8d67b14d39a43e0bd54ada019f7e466f163
lib/codeql/rust/elements/internal/generated/Pat.qll 3605ac062be2f294ee73336e9669027b8b655f4ad55660e1eab35266275154ee 7f9400db2884d336dd1d21df2a8093759c2a110be9bf6482ce8e80ae0fd74ed4
lib/codeql/rust/elements/internal/generated/Path.qll 9b12afb46fc5a9ad3a811b05472621bbecccb900c47504feb7f29d96b28421ca bcacbffc36fb3e0c9b26523b5963af0ffa9fd6b19f00a2a31bdb2316071546bd
@@ -587,15 +587,14 @@ lib/codeql/rust/elements/internal/generated/PathAstNode.qll e6d4d5bffd3c623baaae
lib/codeql/rust/elements/internal/generated/PathExpr.qll 34ebad4d062ce8b7e517f2ab09d52745fb8455203f4a936df7284ad296638387 ba66781cdbdeb89c27a4bfb2be0f27f85fb34978d699b4e343446fb0d7ad2aa6
lib/codeql/rust/elements/internal/generated/PathExprBase.qll d8218e201b8557fa6d9ca2c30b764e5ad9a04a2e4fb695cc7219bbd7636a6ac2 4ef178426d7095a156f4f8c459b4d16f63abc64336cb50a6cf883a5f7ee09113
lib/codeql/rust/elements/internal/generated/PathPat.qll 003d10a4d18681da67c7b20fcb16b15047cf9cc4b1723e7674ef74e40589cc5a 955e66f6d317ca5562ad1b5b13e1cd230c29e2538b8e86f072795b0fdd8a1c66
lib/codeql/rust/elements/internal/generated/PathSegment.qll 10cad4c93ef8046b757c1dd9f0eb7be2d53117159ebc7c43eb071f182bff7c4b 189de31d2dc4ef76859509ce06dfab7aa58b2114176c04140bd2841c425d5b5f
lib/codeql/rust/elements/internal/generated/PathSegment.qll bd7633916e407673c6c4e2c6e5cfb01b42c9d2cd4ec7291f676e63350af26bb8 3c75d01a6dac7e4bc5cdf6fc8b62ad2eb863c90615dcdad19a3d3b26f475b5e6
lib/codeql/rust/elements/internal/generated/PathTypeRepr.qll b847fabe7059485c5194cbc144f38dae2433057771ff10fe0b6ae9876b33afd4 ee2fdcd86d78c389a2276ebe7e889f042b7bb39c3c611f56b951591600a60e8a
lib/codeql/rust/elements/internal/generated/PrefixExpr.qll c9ede5f2deb7b41bc8240969e8554f645057018fe96e7e9ad9c2924c8b14722b 5ae2e3c3dc8fa73e7026ef6534185afa6b0b5051804435d8b741dd3640c864e1
lib/codeql/rust/elements/internal/generated/PtrTypeRepr.qll 51d1e9e683fc79dddbffadee9015b5351bf03ce48f879da98b1f6931a61166f8 122a9c4887aa24e3f3a587b2f37c4db32633f56df3c8b696db4b8a609d9d4a98
lib/codeql/rust/elements/internal/generated/PureSynthConstructors.qll e5b8e69519012bbaae29dcb82d53f7f7ecce368c0358ec27ef6180b228a0057f e5b8e69519012bbaae29dcb82d53f7f7ecce368c0358ec27ef6180b228a0057f
lib/codeql/rust/elements/internal/generated/RangeExpr.qll 23cca03bf43535f33b22a38894f70d669787be4e4f5b8fe5c8f7b964d30e9027 18624cef6c6b679eeace2a98737e472432e0ead354cca02192b4d45330f047c9
lib/codeql/rust/elements/internal/generated/RangePat.qll 80826a6a6868a803aa2372e31c52a03e1811a3f1f2abdb469f91ca0bfdd9ecb6 34ee1e208c1690cba505dff2c588837c0cd91e185e2a87d1fe673191962276a9
lib/codeql/rust/elements/internal/generated/Raw.qll 48bb632ea749504184ba9ed85f364806657a6de953eff9492d5c1c509c75b9b0 b5f8a05c79cbb36f95d830994946e58862583f3e16df80c947e8318aa8f17beb
lib/codeql/rust/elements/internal/generated/RecordFieldList.qll 4a23b0d75a90671197246dbbb4e62706c180074abb8ebe60a96df11c47a917a2 09be127977651a24010b090d9681714d83ebd461098f9cf0e0d1973cafb1c782
lib/codeql/rust/elements/internal/generated/Raw.qll 4a73b51a4e7c995c42d68cf64ff8aff351d898f306ceedf70a009bf86bbf7d84 f7ccdbc4841d87dae7bbf6f58556901176c930a9a797a59dbc04269ca3b516ce
lib/codeql/rust/elements/internal/generated/RefExpr.qll 7d995884e3dc1c25fc719f5d7253179344d63650e217e9ff6530285fe7a57f64 f2c3c12551deea4964b66553fb9b6423ee16fec53bd63db4796191aa60dc6c66
lib/codeql/rust/elements/internal/generated/RefPat.qll 456ede39837463ee22a630ec7ab6c8630d3664a8ea206fcc6e4f199e92fa564c 5622062765f32930465ba6b170e986706f159f6070f48adee3c20e24e8df4e05
lib/codeql/rust/elements/internal/generated/RefTypeRepr.qll 3d8c0bd296d33b91a81633f697a43269a6538df06d277262d3990d3f6880ef57 13680f39e89bcd8299c218aba396f3deec804597e6f7cb7d4a7e7c748b6faa77
@@ -614,14 +613,15 @@ lib/codeql/rust/elements/internal/generated/Stmt.qll 8473ff532dd5cc9d7decaddcd17
lib/codeql/rust/elements/internal/generated/StmtList.qll a667193e32341e17400867c6e359878c4e645ef9f5f4d97676afc0283a33a026 a320ed678ee359302e2fc1b70a9476705cd616fcfa44a499d32f0c7715627f73
lib/codeql/rust/elements/internal/generated/Struct.qll b54a48c32d99345f22f189da87ff5a27f8b1e8ca78e740ba38d2b4766f280eaa c4bd85920ed3409c48eec9eed6e2e902f9694a3aa6e43222bbe5085f9663c22a
lib/codeql/rust/elements/internal/generated/StructExpr.qll c6d861eaa0123b103fd9ffd2485423419ef9b7e0b4af9ed2a2090d8ec534f65d 50da99ee44771e1239ed8919f711991dd3ec98589fbe49b49b68c88074a07d74
lib/codeql/rust/elements/internal/generated/StructExprField.qll a6c1f744dbad034e6a3b173b8ff8037e2bfdea58316dedfe5508299afb770435 f7ed27ce27d14516e735a19a0509aa614d9c7637133efec8e6dc4145b5f3bee7
lib/codeql/rust/elements/internal/generated/StructExprField.qll 6bdc52ed325fd014495410c619536079b8c404e2247bd2435aa7685dd56c3833 501a30650cf813176ff325a1553da6030f78d14be3f84fea6d38032f4262c6b0
lib/codeql/rust/elements/internal/generated/StructExprFieldList.qll b19b6869a6828c7a39a7312539eb29fd21734ff47dfd02281de74194fd565d7e 3cadebffaa937e367a5e1da6741e4e9e5c9a9c7f7555e28cfa70639afd19db7c
lib/codeql/rust/elements/internal/generated/StructField.qll d3eca4a20ae50c9396fd56820491bcc0af812b921b56ac9f73614d99c78277b8 874d95c4b7af98f706ea23e05afc9b260775128f6d256891607fa4f0022bc15a
lib/codeql/rust/elements/internal/generated/StructField.qll bcbaa836d9b9889c87ba57c6ea733cdc85425168d9df05aca5cfd051851d8cd1 a17034896bc7fa25c84e40b460109d122ca1e85632cf8ac620f66f3eb0ff81b5
lib/codeql/rust/elements/internal/generated/StructFieldList.qll 8911a44217d091b05f488da4e012cb026aed0630caa84ca301bbcbd054c9a28c a433383fea7e42f20750aa43e6070c23baad761a4264be99257541c1004ead31
lib/codeql/rust/elements/internal/generated/StructPat.qll c76fa005c2fd0448a8803233e1e8818c4123301eb66ac5cf69d0b9eaafc61e98 6e0dffccdce24bca20e87d5ba0f0995c9a1ae8983283e71e7dbfcf6fffc67a58
lib/codeql/rust/elements/internal/generated/StructPatField.qll 285530e9b73d51b3921984e344a9a944afc68c6d83fba7ee1d63345de455208f 17985cea91de1ed21e53e8c0fdb6382768cc57c5b79856dab3bc03cf1c323df9
lib/codeql/rust/elements/internal/generated/StructPatField.qll 5b5c7302dbc4a902ca8e69ff31875c867e295a16a626ba3cef29cd0aa248f179 4e192a0df79947f5cb0d47fdbbba7986137a6a40a1be92ae119873e2fad67edf
lib/codeql/rust/elements/internal/generated/StructPatFieldList.qll e34c003e660ba059ba81bb73b3c8d21bd2a47d0251569c46277dc9ccf2947b0a 85113f35ba5f6b9e01ad4072246a4de1ac0e4528348ac564868e96f34a3e09e2
lib/codeql/rust/elements/internal/generated/Synth.qll ae5702e53d576dccdffa398e2142a696361e70f2fca40c10a3c976f3e4ff1fff ab4d20c73b4668ea0e1103a8a54ba7f39030795df7b9ee010109f15d50999bd2
lib/codeql/rust/elements/internal/generated/SynthConstructors.qll e4298dc8e52d56672d91df093cc858105b5072be4ae5bed95105e0ffd80e7233 e4298dc8e52d56672d91df093cc858105b5072be4ae5bed95105e0ffd80e7233
lib/codeql/rust/elements/internal/generated/Synth.qll 409b9ae5c78f47f271eb05a9eb7043df6cd6ca35ce381843714667f1f2dfdf9a aa4d5082abccd7cd47a493447eea79b0a3ff81439c333f05087030e76f0fa8e5
lib/codeql/rust/elements/internal/generated/SynthConstructors.qll fe007cf6eab5f0cf89ea1ea91e1f9b23e0fcf0f2872f52ef352584503f90aa29 fe007cf6eab5f0cf89ea1ea91e1f9b23e0fcf0f2872f52ef352584503f90aa29
lib/codeql/rust/elements/internal/generated/Token.qll 77a91a25ca5669703cf3a4353b591cef4d72caa6b0b9db07bb9e005d69c848d1 2fdffc4882ed3a6ca9ac6d1fb5f1ac5a471ca703e2ffdc642885fa558d6e373b
lib/codeql/rust/elements/internal/generated/TokenTree.qll 8577c2b097c1be2f0f7daa5acfcf146f78674a424d99563e08a84dd3e6d91b46 d2f30764e84dbfc0a6a5d3d8a5f935cd432413688cb32da9c94e420fbc10665c
lib/codeql/rust/elements/internal/generated/Trait.qll 8fa41b50fa0f68333534f2b66bb4ec8e103ff09ac8fa5c2cc64bc04beafec205 ce1c9aa6d0e2f05d28aab8e1165c3b9fb8e24681ade0cf6a9df2e8617abeae7e
@@ -642,13 +642,13 @@ lib/codeql/rust/elements/internal/generated/TypeRepr.qll 1e7b9d2ddab86e35dad7c31
lib/codeql/rust/elements/internal/generated/UnderscoreExpr.qll b3780c99c5d57159bef4c6bd2fd8ec44ebd1854c892c1ca776c740f71249e58c 2fd451cbf0a779e8042e439882e7d9cadc19d1e596df3bbb086d16f2596407c7
lib/codeql/rust/elements/internal/generated/Unextracted.qll 01563dfd769d6dc3c6b8a40d9a4dc0d99a3b6a0c6725c180d2bf4d7633929a17 a93ce90f8c03f4305e59de9c63f089fc7935298fc9a73d091d76933cf63e790c
lib/codeql/rust/elements/internal/generated/Unimplemented.qll a3eb304781991bff1227de1e4422b68bf91e7b344e4f6c9e874b324e82a35e60 6bc4839fda3850a56dc993b79ef9ba921008395c8432b184e14438fba4566f21
lib/codeql/rust/elements/internal/generated/Union.qll d91aa6cd02bce27a28d1fba87fe80be3a33d1e560d3dd447c3035ff2738a0821 22343e17c08e53d237e834fb9fb9c97fbdebc95bfda4bab80a0c3274edebf7fd
lib/codeql/rust/elements/internal/generated/Union.qll 83b1ed06279e1f6baa1c2618e09f58a15b83c300837d0da3faf3b8f63cf15aa0 e9d877bb75231a36b3d32cf92a598593eeaf4f5100ac1fa172781bc5b9514349
lib/codeql/rust/elements/internal/generated/Use.qll d42ccf3516a9f79ae8766f93ad5f09d3cdcd7b96844d4c9de64189b56018a7b4 70a9553a8f71f6cbfdd0f59a4b42292d13177613ceb0542436436e0ac2e1f8ee
lib/codeql/rust/elements/internal/generated/UseBoundGenericArg.qll 69162794e871291545ea04f61259b2d000671a96f7ca129f7dd9ed6e984067c4 31de9ebc0634b38e2347e0608b4ea888892f1f2732a2892464078cd8a07b4ee8
lib/codeql/rust/elements/internal/generated/UseBoundGenericArgs.qll 05dca015d922935887856f3a0d577dbcf5b8f82bc384bdc9c8c2d0106419716d fcee14ed4f7a639b1ba721bd390fc0cdbfdc7c759e3092aa462d466fe390de45
lib/codeql/rust/elements/internal/generated/UseTree.qll 15b84e3a194959aef793cd0c16b3d2d21ee5822e2d26186b5d73f922325c2827 49c409a7b82c1099436fbe3bd041d35dcd23169d58d31fbd718f6deb96fb7318
lib/codeql/rust/elements/internal/generated/UseTreeList.qll 829441cf309f008a6a9d2e784aa414ab4c11880a658f8ee71aa4df385cd2b6a8 ced82df94fea7a191f414f7e6496d13791d2f535046844b6f712a390663ac3d0
lib/codeql/rust/elements/internal/generated/Variant.qll b0be3cd76ac17655c683f384eafc9263e241068a85ca7e905675b2b7e9121b29 6f1b2ad719342bab0cb770d318e84c227de66e65838c33642aa5ac1a836883f8
lib/codeql/rust/elements/internal/generated/Variant.qll 6d85af18e730e3f88cb97cd40660437364d7718072567f871310abd617a1e6e5 da2a5edfeebf9b3e554cb866c5b32f9b122044194122640c97d9d07781215bd1
lib/codeql/rust/elements/internal/generated/VariantDef.qll 3a579b21a13bdd6be8cddaa43a6aa0028a27c4e513caa003a6304e160fc53846 1ca1c41ed27660b17fbfb44b67aa8db087ea655f01bac29b57bb19fa259d07a2
lib/codeql/rust/elements/internal/generated/VariantList.qll 4eb923ca341033c256ca9b8a8a5b4e14c7eac9d015be187fd97eeb25dfb1e18e e7865e975c35db49cd72cb8f9864797d3cfed16c3a675b5032b867ced2bbb405
lib/codeql/rust/elements/internal/generated/Visibility.qll aba81820f30bed0fd2cd06831f7256af15ae32525b2a437896420b4cc067ea38 d6aed90b27124b812daf2ddd14b4e181277cbe638b4ccaab74e27681ac30e4ab
@@ -658,7 +658,7 @@ lib/codeql/rust/elements/internal/generated/WhileExpr.qll 7edf1f23fbf953a2baabcd
lib/codeql/rust/elements/internal/generated/WildcardPat.qll d74b70b57a0a66bfae017a329352a5b27a6b9e73dd5521d627f680e810c6c59e 4b913b548ba27ff3c82fcd32cf996ff329cb57d176d3bebd0fcef394486ea499
lib/codeql/rust/elements/internal/generated/YeetExpr.qll cac328200872a35337b4bcb15c851afb4743f82c080f9738d295571eb01d7392 94af734eea08129b587fed849b643e7572800e8330c0b57d727d41abda47930b
lib/codeql/rust/elements/internal/generated/YieldExpr.qll 37e5f0c1e373a22bbc53d8b7f2c0e1f476e5be5080b8437c5e964f4e83fad79a 4a9a68643401637bf48e5c2b2f74a6bf0ddcb4ff76f6bffb61d436b685621e85
lib/codeql/rust/elements.qll 5fbfcd83eeb4467d0a721e5b4faf61d0b31316d923e6a6f61d1724023ad91cae 5fbfcd83eeb4467d0a721e5b4faf61d0b31316d923e6a6f61d1724023ad91cae
lib/codeql/rust/elements.qll 05fb894d008a9c0478d03fb1639ffc57516b67d9de7f7309331279512f630b4a 05fb894d008a9c0478d03fb1639ffc57516b67d9de7f7309331279512f630b4a
test/extractor-tests/generated/Abi/Abi.ql 7f6e7dc4af86eca3ebdc79b10373988cd0871bd78b51997d3cffd969105e5fdd 2f936b6ca005c6157c755121584410c03e4a3949c23bee302fbe05ee10ce118f
test/extractor-tests/generated/Abi/Abi_getAbiString.ql a496762fcec5a0887b87023bbf93e9b650f02e20113e25c44d6e4281ae8f5335 14109c7ce11ba25e3cd6e7f1b3fcb4cb00622f2a4eac91bfe43145c5f366bc52
test/extractor-tests/generated/ArgList/ArgList.ql e412927756e72165d0e7c5c9bd3fca89d08197bbf760db8fb7683c64bb2229bc 043dba8506946fbb87753e22c387987d7eded6ddb963aa067f9e60ef9024d684
@@ -687,10 +687,10 @@ test/extractor-tests/generated/AsmOptionsList/MISSING_SOURCE.txt b6cf5771fdbbe98
test/extractor-tests/generated/AsmRegOperand/MISSING_SOURCE.txt b6cf5771fdbbe981aeb3f443ec7a40517b6e99ffc9817fd8872c2e344240dae1 b6cf5771fdbbe981aeb3f443ec7a40517b6e99ffc9817fd8872c2e344240dae1
test/extractor-tests/generated/AsmRegSpec/MISSING_SOURCE.txt b6cf5771fdbbe981aeb3f443ec7a40517b6e99ffc9817fd8872c2e344240dae1 b6cf5771fdbbe981aeb3f443ec7a40517b6e99ffc9817fd8872c2e344240dae1
test/extractor-tests/generated/AsmSym/MISSING_SOURCE.txt b6cf5771fdbbe981aeb3f443ec7a40517b6e99ffc9817fd8872c2e344240dae1 b6cf5771fdbbe981aeb3f443ec7a40517b6e99ffc9817fd8872c2e344240dae1
test/extractor-tests/generated/AssocTypeArg/AssocTypeArg.ql 31b925ef046811d8f02253619b4346ed4998fc32230c025edd971d3167c15e39 f7974a74e5673a6d7665d48796561ca4b3231a06690d3544186078da467c86ff
test/extractor-tests/generated/AssocTypeArg/AssocTypeArg.ql e0bfc812d6bc06fcd820d67044831fbc7c6917e11f75565128c5a927c5706aa3 e4b765d91f1205ed818dc1143316aa642d968e7bcd65ed055579ab941c401637
test/extractor-tests/generated/AssocTypeArg/AssocTypeArg_getConstArg.ql c81e25fd7885f13c0500e8f9b84195876e70f2b25ad604046f497818226c8542 62ac0e7c82da169c248e4f9e0e8f866d2f4e599b03a287c2bd407b95a5d9efc8
test/extractor-tests/generated/AssocTypeArg/AssocTypeArg_getGenericArgList.ql 4d20375752c000aab8d2e4988fff1a5c95689d114c8d63f37b389b95000ee873 957e360a4eeefa2536958770a7d150fda610d1d45c09900dbe66e470e361e294
test/extractor-tests/generated/AssocTypeArg/AssocTypeArg_getNameRef.ql 0fbb10321c355b15a9fdb2022af254d9d50b084117e47abf4c03bacc6189c9dd 084624f77b21062822fd16441e0c05e7820140bd2e468aac624782f0c4474e26
test/extractor-tests/generated/AssocTypeArg/AssocTypeArg_getIdentifier.ql 1d6d4031ed10dbe09ba8597d9ba5417c6b890b5b745e91bca12401459fc3c4e2 7da625c3a6eaf93b0ebd5d9863aad5fad45b1baf5df27d93d7f9c5d1fb76db13
test/extractor-tests/generated/AssocTypeArg/AssocTypeArg_getParamList.ql 586cb26683e522469a5094d359be4d8e5c6a3a74c1621a059bfcbbbedc0e34b4 84784b38c24313f3ffc88371421550922d9deb44d09ca7727ca77e892a672dc9
test/extractor-tests/generated/AssocTypeArg/AssocTypeArg_getRetType.ql 3e18791a74c12d93ac8f786aa76bd836876052837bb9f0b25222cde47c55e419 b53bb52ff98c1ca0ba09ffce034a97ddd86e32828df7acb9bf34e20c4fb19664
test/extractor-tests/generated/AssocTypeArg/AssocTypeArg_getReturnTypeSyntax.ql 37252b5cee5ae64c36612aea57a6766bd34254ae35b9774642a36a8222aecfe6 c1f587d52b39c8aa66b9e6e4f36f40bda17dfcd72714ff79a262af99f829f89d
@@ -776,20 +776,20 @@ test/extractor-tests/generated/ExternBlock/ExternBlock_getAttr.ql 78ed6a2d31ccab
test/extractor-tests/generated/ExternBlock/ExternBlock_getCrateOrigin.ql 5a2e0b546e17a998156f48f62e711c8a7b920d352516de3518dfcd0dfedde82d 1d11b8a790c943ef215784907ff2e367b13737a5d1c24ad0d869794114deaa32
test/extractor-tests/generated/ExternBlock/ExternBlock_getExtendedCanonicalPath.ql 40d6ee4bcb77c2669e07cf8070cc1aadfca22a638412c8fcf35ff892f5393b0c e9782a3b580e076800a1ad013c8f43cdda5c08fee30947599c0c38c2638820d6
test/extractor-tests/generated/ExternBlock/ExternBlock_getExternItemList.ql 2c2b29bdfdc3b27173c068cbaab9946b42053aa14cf371236b4b60ff2e723370 dfc20fc8ef81cdce6f0badd664ef3914d6d49082eb942b1da3f45239b4351e2f
test/extractor-tests/generated/ExternCrate/ExternCrate.ql c4313ed4790d6c085f47d6c14b11bfa67f7758a1f160758a385bcfcd37284151 9a761086cd80a6fdb7a41f2f6887e1c0b8b3aa19ada0b1dcc74a57646338ecc9
test/extractor-tests/generated/ExternCrate/ExternCrate.ql c6c673d6f533fc47b1a15aac0deb5675ba146c9b53e4575f01e97106969ef38e 5a4d9e6f4fdb689d9687f4e7eb392b184c84bad80eec5dad0da775af27028604
test/extractor-tests/generated/ExternCrate/ExternCrate_getAttr.ql cbe8efdfdbe5d46b4cd28d0e9d3bffcf08f0f9a093acf12314c15b692a9e502e 67fe03af83e4460725f371920277186c13cf1ed35629bce4ed9e23dd3d986b95
test/extractor-tests/generated/ExternCrate/ExternCrate_getCrateOrigin.ql c0bf9ba36beb93dc27cd1c688f18b606f961b687fd7a7afd4b3fc7328373dcfb 312da595252812bd311aecb356dd80f2f7dc5ecf77bc956e6478bbe96ec72fd9
test/extractor-tests/generated/ExternCrate/ExternCrate_getExtendedCanonicalPath.ql 88e16e2bbef466cec43ace25716e354408b5289f9054eaafe38abafd9df327e3 83a69487e16d59492d44d8c02f0baf7898c88ed5fcf67c73ed89d80f00c69fe8
test/extractor-tests/generated/ExternCrate/ExternCrate_getNameRef.ql 4bbc210ed3114f355a36768fc8173dfb65bd683bdf47491a30890cf110a6fb2c cd9c1b52dd350337e946fb43243de1504f0ae44d81668dab3629f2b7c2651572
test/extractor-tests/generated/ExternCrate/ExternCrate_getIdentifier.ql 6ce362fb4df37210ce491e2ef4e04c0899a67c7e15b746c37ef87a42b2b5d5f9 5209c8a64d5707e50771521850ff6deae20892d85a82803aad1328c2d6372d09
test/extractor-tests/generated/ExternCrate/ExternCrate_getRename.ql 52007ef7745e7ceb394de73212c5566300eb7962d1de669136633aea0263afb2 da98779b9e82a1b985c1b1310f0d43c784e5e66716a791ac0f2a78a10702f34b
test/extractor-tests/generated/ExternCrate/ExternCrate_getVisibility.ql d2c13d0c19a5ef81ca776f03a7259e743adbfa66ef440f7d402cd97391ecdfc4 c678f6ac0a075c1e0adc3768a344dbeebcf0d13e30878546094777e3fcdf92bd
test/extractor-tests/generated/ExternItemList/ExternItemList.ql 7596986006fe1084815ad47b7e1cb77c4062a8c0432c2e6234c974b8632ead40 23c30ea01dba595e6e1bfa384f3570d32df4310ec2e8dbeb9a20afab9edbbfc0
test/extractor-tests/generated/ExternItemList/ExternItemList_getAttr.ql f9560f441efc30b65ad88e3d3d323f40cbe3862c04a9c044fb2ca16edac4f3ca 18138daa285c73d40e5caa03791a6133b44429bff4e14cb1f223d487cf1648b4
test/extractor-tests/generated/ExternItemList/ExternItemList_getExternItem.ql 2f20a6a4f41babb7340dd366a8145bb7cc9ceb75812af8a6316d076a4eac3428 4f613a73604dfe3f0d32343156e8ae30f4295186ac4ef2f733c772e96821ffc4
test/extractor-tests/generated/FieldExpr/FieldExpr.ql 1b45da610feb62cee42f7a3866e6a9396c1e4c880ce1a82f09892047090e1322 980eae97fdeff4b8b3b264080a3cbb320d3a2530960fa185108f665b4c2aee29
test/extractor-tests/generated/FieldExpr/FieldExpr.ql bac5eb23ef2e6a69b3b898a486c2c498bd8a92233116224faaf9039225cf33bb 23a4a86b6235571b3af8a27ad88b4e163d9dc568a23b948d690662089c55e26b
test/extractor-tests/generated/FieldExpr/FieldExpr_getAttr.ql 609c4f1e275d963cf93a364b5ec750de8cb4790abdaa710cb533ff13ab750a4e 8c2aa84b1ea6ef40a7ee39a2168baf1b88323bfbc6b9f184e7b39631765a48dd
test/extractor-tests/generated/FieldExpr/FieldExpr_getExpr.ql 57df2d733faf3e3e30ae106d8423aab612ab0ddf8659da008e384130cf1e8023 1e240bee8e83dc26f78d2c55464ca1fb88d773691d47aee9a2182c90f57eb8f1
test/extractor-tests/generated/FieldExpr/FieldExpr_getNameRef.ql 8631f5e8bdd72443a1ee3d667ee9136a51ad49dfd206612a36b79686da1beb19 692aef607108b8e3eaa78b8c915f2fd1d310905f8fea770b9694722a9a2a6232
test/extractor-tests/generated/FieldExpr/FieldExpr_getContainer.ql 747b7de5f2bc23f526e96611401c897d063625912dc90544a4c57e2732c0766a 1528b998f6480bb1fd089c0115137c3a39fcfabc73d30917784a5d7ed5ef2990
test/extractor-tests/generated/FieldExpr/FieldExpr_getIdentifier.ql 61fcbae168878f655bb35e8f1af8536c82acf02068bf782e5abdb7b780136ef9 5716c109cfbc996e884a7fbba8800cb770930060cc5c4d70c0bd434e37f2bbcb
test/extractor-tests/generated/FnPtrTypeRepr/FnPtrTypeRepr.ql 277dc617dd193f414c777e85db358f6dc5ebd7c029ac321d92fc6f1036da6abf 2c1a245975852e010552b0e0157b0daac7137cb25aa059fa5cc3adb43544a52a
test/extractor-tests/generated/FnPtrTypeRepr/FnPtrTypeRepr_getAbi.ql c4a7519f9ab86de609a0155d41a0fd6cdfab6bbd7ffc41f3d5ef49565bdb5825 a0404f9a702f007d78f24291e80e939ce3ed2b603e436998dd1337f978499137
test/extractor-tests/generated/FnPtrTypeRepr/FnPtrTypeRepr_getParamList.ql e097544fa9a1c173a996f323a90aa2b82aa6f12f30cd602fbcf0d4bfaf136311 6b5f8a4e4bee41343d075561005442c89b2b16ba547226f54c060c206b0b9e26
@@ -945,11 +945,11 @@ test/extractor-tests/generated/Meta/Meta.ql 16f163f00ba2bbaa0a8c6f3f6710c860a8f6
test/extractor-tests/generated/Meta/Meta_getExpr.ql ec9ec61f5be7d65c32775fb5c068daea04f9db7d875293ed99cc1b2481db041f 77a0c52f1cb6ddc8fdb294d637f9eda1b7301ffa3067f0fca6272d894f57d3ee
test/extractor-tests/generated/Meta/Meta_getPath.ql aa9d4145a4e613c51b6e4637d57e3b7d0f66e0bb88f4ce959d598870814c06bb 2087e00686d502c0e2e89c88eae0fb354463576a9ae4101320981d3fd79b9078
test/extractor-tests/generated/Meta/Meta_getTokenTree.ql 1051c27ffd0d9a20436d684fde529b9ff55abe30d50e1d575b0318951e75bd34 983975672d928fb907676628384c949731da9807bf0c781bb7ec749d25733d2d
test/extractor-tests/generated/MethodCallExpr/MethodCallExpr.ql 0149a2d174c72a530b39a5878e204cb6db7632935a5ceaf20e2b2363b67dfdf6 8284d9133c21136f89a04105c280efe736a782035235c6abc081f3d9a2616447
test/extractor-tests/generated/MethodCallExpr/MethodCallExpr.ql d141f5a2ef95019aa64e8cb384ab4a45e7a93c941b84ef2e14c13377f159e4db 47a68fc874af6cc9a4b278a5aab1633a9db17300fd7dbd6dbe193d48d99144bc
test/extractor-tests/generated/MethodCallExpr/MethodCallExpr_getArgList.ql 180e0b1715f5cd2be0de01bff3d3a45594b495b8250748d40ff7108d6c85923d bdadcdbecca5891287a47b6dd6b2fda62e07457718aef39212503ab63bc17783
test/extractor-tests/generated/MethodCallExpr/MethodCallExpr_getAttr.ql 2ce876a04a159efce83b863dffc47fbb714b95daea2b91fa6fbb623d28eed9ec 7bca1cd0e8fbceec0e640afb6800e1780eff5b5b402e71b9b169c0ba26966f96
test/extractor-tests/generated/MethodCallExpr/MethodCallExpr_getGenericArgList.ql 655db9a0501b1ef20d604cc4cd9d708371781291443e8dec97b70ec2914601d2 2fc7df0eca22dcef2f9f5c86d37ee43452d372a4c0f9f4da0194828c82ba93e0
test/extractor-tests/generated/MethodCallExpr/MethodCallExpr_getNameRef.ql 9a4829a174388e818f0c63ee6b8bdf1b68beaab48f51734ec6cc14635d24001c f57c9cdaf5235aad604f60b53ce92e73946d03a085f95ed051a26683967be4ba
test/extractor-tests/generated/MethodCallExpr/MethodCallExpr_getIdentifier.ql 13c08e67eda07ea9ddc6f22ab4fc7773185c0b700ae11d57b62e0c78a4dea2e3 cb812e282a77fa29c838ba939d342a29c360c263c5afa5aac4ad422a8176869b
test/extractor-tests/generated/MethodCallExpr/MethodCallExpr_getReceiver.ql 77407ac956c897ff7234132de1a825f1af5cfd0b6c1fd3a30f64fe08813d56db d80719e02d19c45bd6534c89ec7255652655f5680199854a0a6552b7c7793249
test/extractor-tests/generated/MethodCallExpr/MethodCallExpr_getResolvedCrateOrigin.ql c22504665900715e8a32dd47627111e8cef4ed2646f74a8886dead15fbc85bb5 d92462cf3cb40dcd383bcaffc67d9a43e840494df9d7491339cbd09a0a73427b
test/extractor-tests/generated/MethodCallExpr/MethodCallExpr_getResolvedPath.ql 9e7bbb7ed60db49b45c3bdf8e01ec58de751889fc394f59ac33f9d6e98200aa1 c055d877e2ff0edc78cce6dd79c78b2881e7940889729cbb5c12e7029ddeb5a3
@@ -996,9 +996,9 @@ test/extractor-tests/generated/Path/PathPat.ql 6b9d973009f1b4963c7c83b0f5051eda7
test/extractor-tests/generated/Path/PathPat_getPath.ql 6c0c71c80a6e631ea7775ec8660b470ff6b264bab14a399606cf113b1fb190fc 8e34cbb4d064db929e94652e1901ec4f26affa71e30e556b7acdff71dd622cbb
test/extractor-tests/generated/Path/PathPat_getResolvedCrateOrigin.ql f690fd9a8773e7c73b70f2d64ee919fef8eee243c5a315c4a6d2713d43ea0e43 f37817427c36cec14a2e07f99d3a32f37f3f27a8eafdf170749ec2780054729b
test/extractor-tests/generated/Path/PathPat_getResolvedPath.ql 55df4541a7b0e82198acfcedd7dc99eb564908270e4fb2b032bf05e40fba6fef a5932d884903da901263f88644c8585a45045190d7204f630506c5aece798288
test/extractor-tests/generated/Path/PathSegment.ql e75c820f7cf8c94cae72053ee3cadd6b60e342b78d03d310fa94f16a5776a096 b90af2408bbfc684f156ce053be91639f9f011c0aeff9a1f51a5865b285f6e66
test/extractor-tests/generated/Path/PathSegment.ql 523ec635961b9aff465dd98a1e63f8e872e147943646ea7383af95c3fa5d8e42 29bd402ee76eaa080cd6fbf29ba9d9141cc9828f1d3ddf162da6534daed52c56
test/extractor-tests/generated/Path/PathSegment_getGenericArgList.ql 8f6e67b3e316309f20e21d7e7944accf66b0256b76fa50ee9a714044c6ec8cea 15f10a701fc4d3f9fd6734da90790cdbc8a1ddd57bf52695740acedcb2e6e485
test/extractor-tests/generated/Path/PathSegment_getNameRef.ql 799d284e2f9267d6bbe67aa7035e525ef347dc74cb3e2180e7b2171b5cb49674 592130bc2358989536abf62e8a261272c851483ede4f19783f7d61ffc1803e4b
test/extractor-tests/generated/Path/PathSegment_getIdentifier.ql 52fedfc7518d4646e5f90843806c70fcfde7e7af602846a4f1dd90c3a46c9229 a291e47676ee9d257ac76fd5e4088f5905ec5fefc77568038efa6c88d2116a85
test/extractor-tests/generated/Path/PathSegment_getParenthesizedArgList.ql 0d5919b0a240678d84dc687de954ef6dc11fe4a20f54c56578c541c573bdf3f2 5d2094ad5c0b0b7f298260511c5072b129b121928394b27c49d39e69ba6a5870
test/extractor-tests/generated/Path/PathSegment_getRetType.ql 36386a514bc925f5b17ad87afba9fef7986900c1b791732de061213c6e86743f f38bcee68c1da19e70bb1e1c4a4047c763a466f1b8ef2c4f65f8c724c0b58197
test/extractor-tests/generated/Path/PathSegment_getReturnTypeSyntax.ql d1db51208a311c30af369ce2fdc3a3296e7d598b27bf4960b8b34622a9d9163b 561b1e38c6d8b301fdc016e1d012dd805fde1b42b0720c17d7b15535715047f2
@@ -1023,8 +1023,6 @@ test/extractor-tests/generated/RangePat/RangePat.ql 97314b9a5543a7471d722ae188a6
test/extractor-tests/generated/RangePat/RangePat_getEnd.ql 723eb5030ec52d3aa3650a3e2de6cc0195a0030630239b972235963320e0d808 2df3b1a6197c3abd43dc743fd09cbf55165e3191f2b49336777594541e5da96a
test/extractor-tests/generated/RangePat/RangePat_getOperatorName.ql 564216b2342f56dc8c1aed6306f57b6dafb33de9e3ba337a840a8c077ce95933 2a76ec7a59bada29733a1515bc1ea8bedd37429d1694ca63c7a8fbf94098a4c7
test/extractor-tests/generated/RangePat/RangePat_getStart.ql ad2066efa32fced2dd107031f2a9b9635c3c892e874870a4320522bae9309aa4 b4a8c57a838074e186b823938d1a9372153c193da6c839b5f242ca25c679e83f
test/extractor-tests/generated/RecordFieldList/RecordFieldList.ql 586bccfa550243177d9fdfd6900a473f51a76ed360b537f19cb300330d5dad5b a063373dfdbf06b68c69694ea4ae72a26b906c910f9095894c09e72f8fb52819
test/extractor-tests/generated/RecordFieldList/RecordFieldList_getField.ql 2eb92ef8528204f3f105c19a36cdc06b3b6d20242463ff2ed1fb81c544812a71 d69091899e7157099f117e14fe60cd3705cfda45f28f6a6a2b7234a4a9c1e664
test/extractor-tests/generated/RefExpr/RefExpr.ql 27d5dceb9e50668e77143ff5c4aa07cbe15aeea9829de70f1ddfe18d83690106 b95058b7a0bad4bddb857794901d9b651b2f9e4dd3554e5349a70a52cbbfaff6
test/extractor-tests/generated/RefExpr/RefExpr_getAttr.ql 477fb3fee61395fabf78f76360ea27656432cb9db62e6f1dab1e9f3c75c83d39 5210f2ac54c082b616d8dcb091659cdad08a5d4ae06bf61193c33f208237482f
test/extractor-tests/generated/RefExpr/RefExpr_getExpr.ql 180d6417fd7322cabf4143d0ddd7810f65506b172a5c82484b3ef398041636b2 a291f0bec1ec5b3fa6d088b3d1a658889b9a3521c39ff3bb7a5ab22a56b8b20a
@@ -1081,28 +1079,30 @@ test/extractor-tests/generated/StructExpr/StructExpr_getPath.ql f6f2b26a93b24d19
test/extractor-tests/generated/StructExpr/StructExpr_getResolvedCrateOrigin.ql c2794babda0823c62c2af6fe9e3b11d8e4b6baa8095bf8f01faee13b4894ff67 cba6a7576a572238c59142e46cc398c5f31cd91c8d1710381d579bb6bb0edb7c
test/extractor-tests/generated/StructExpr/StructExpr_getResolvedPath.ql 5152d15064daa1da4470cdc659a07281734d56ed958e67efc54701eb44d550dc a7a78db088b0dd7b7c148ad24c8faa014e2eab29146e056bdf35bef5ca2f8485
test/extractor-tests/generated/StructExpr/StructExpr_getStructExprFieldList.ql 1c2401038fe14e660d5101951e7467dc3a56969698a8cc5b818d664902b269bc f6b7047112ade49b632d2e3f71531dd2dffe7c2cc848587908fa4b85dc06ee82
test/extractor-tests/generated/StructExprField/StructExprField.ql 4a530138ecae9ac693cd7d3dc06f02a8457263e4a7e9ab13092c59441de0f4c1 e434b184b6ed4ff0f759c33df4a41519d85163c8efbf259c1c9a65b282b0cfa7
test/extractor-tests/generated/StructExprField/StructExprField.ql f054440c074461bdb00506e775be346efc4faf8afd3e55d61f72c8776d1d4bd5 8bfacfa4864309157b6795de26e6c37676ad627e2e8771dfdc8abe57ff269c92
test/extractor-tests/generated/StructExprField/StructExprField_getAttr.ql 660400f80824956422b95923519769df08514f089269c7a5ccc14036b90b233d f137716537f8780ad63bd6af0da06a96f0d00cb7a35402d3684e6866112b9d1a
test/extractor-tests/generated/StructExprField/StructExprField_getExpr.ql 00180d982057ee23297578d76bf1a337fde8341f0520ebfa5786c8564884ae5a c2b813c25df4ffc49486426365cc0cc0bbf07cf0c7d7adece7e6576fc8b776dc
test/extractor-tests/generated/StructExprField/StructExprField_getNameRef.ql 1c1263f0f5b69ec098b59ba8dfe9689d20ca8359b09887e73026bee908bea37d 044b48656a7e53d2c4a3d638c8881d29f9045c24467b11ebeb96b9e35dc0d322
test/extractor-tests/generated/StructExprField/StructExprField_getIdentifier.ql 9bacb8d6590d5cde340443c4d0963a8ef8ddf434f912a28b04f9dd9f76504f3b 1a2209ee1086873dd2b07979b089bbab849283bfb8f44ba3deb5ff480acc1cbd
test/extractor-tests/generated/StructExprFieldList/StructExprFieldList.ql 33dc3f6c1f737e0ca2015530467bfa123eac0eb8ab63f2937ad0064f2246fb2d b89d5817c6a249232540570ef93ecf880a8ef74aa409c7cd8ddbc83f6d589fea
test/extractor-tests/generated/StructExprFieldList/StructExprFieldList_getAttr.ql cd7f5236f6b660fc064f3a04f3a58d720ed4e81916cbd1a049c1fac7171108ed 61317928d0833f7bb55255a5045bedc0913db1266e963ede97d597ee43e3ddd9
test/extractor-tests/generated/StructExprFieldList/StructExprFieldList_getField.ql 1292aec1141bdb75fd8e0993f683035f396a0e6c841b76ee86a0a1d3dce0dbc4 450eccbd07cc0aa81cef698f43d60aeb55f8952a573eaf84a389a6449c3d63a7
test/extractor-tests/generated/StructExprFieldList/StructExprFieldList_getSpread.ql d0470b9846323d0408e0f26444cdc5322d78ce1ac203073ff4f556dac5343be7 280712a0b3714256aff4c2a4370fd43e70c418f526e383ed7100d61cdf790c36
test/extractor-tests/generated/StructField/StructField.ql ad16292735a9bdbfcb287cf7141bbe52df894f7e5695cab1ebde670e4b314984 84ce151bdcbfc4decb2682417f024029897120f8067dd22a9ee56ccc47e0898d
test/extractor-tests/generated/StructField/StructField.ql 7943d00e32171da93fae8215456c79b2df590cffa7241f4c0e78b0d7d525b1b2 6d5e3825075d2cb4438adf699a5a92ce22301ea58888d63ea336118bf29c0205
test/extractor-tests/generated/StructField/StructField_getAttr.ql a01715bc688d5fa48c9dd4bfab21d0909169f851a290895c13a181f22c0e73a9 fa6ffcf007492d9e1b7f90d571b9747bd47b2dc29e558a8e1c3013c5949dcdb7
test/extractor-tests/generated/StructField/StructField_getExpr.ql 2d71524a890ffe2856c38c3549d05ca1a29765fa8214aa4168bf22d325f28707 24a1b78c143620ddb68f95879617f2b4f9172da36e13405d558fa6dc4f260257
test/extractor-tests/generated/StructField/StructField_getDefault.ql deccc63b81892cd1b293d8b328ad5b3efdf32892efc8b161dfcd89330ca6b5a2 9a9f306f63208ce30d26f91dd15b94867a7d9affd31a0f51a3d1d2ce50786abc
test/extractor-tests/generated/StructField/StructField_getName.ql 4c5a7e00b758a744a719bff63d493ee7d31ff8b3010e00c1d1449034d00130ec 9b284d848e5c86eac089f33deca7586441a89d927e7703cb4f98bb7c65a7238c
test/extractor-tests/generated/StructField/StructField_getTypeRepr.ql 3f36890b9ced576327d0fb6e3c80c6482c3a6d6f751fa769b24b2c14a46f8ee8 aed0681a3928b965f1448954d3a0369238a3cd715b97a0d988d15b971bf45356
test/extractor-tests/generated/StructField/StructField_getVisibility.ql 335d097fabbc9720b065248cd1c295fe8dc040bf646ce491244b6840d9a847d3 9a9073eb52cd401b07beb4eb0aef7a15d5d398d0c76c35416ffcb059a360d654
test/extractor-tests/generated/StructFieldList/StructFieldList.ql 02635fb8b0bccb4cb8be71a2b103c6854192dd0300669127ce74590566b0b163 62e4151cbc47ec7bd10cb9f711587454d8fcf64fb54f279b82eefcf20028c37f
test/extractor-tests/generated/StructFieldList/StructFieldList_getField.ql b70e569d48109f57a1a765fcab2329adce382a17258c4e93a57f540a408b1836 1d6a65b7ac1ed8fd0e966132ec9ecbb425fa7ca501a2cd1db7269f9534415f30
test/extractor-tests/generated/StructPat/StructPat.ql 2fa9b13ad6752a1296908c76caf3778dfd7d31e1ffc581011366208dfc3288a4 5a61ae9056a153b526d07c451a55f3959ce90adf762fe6c31f434fae27086d5d
test/extractor-tests/generated/StructPat/StructPat_getPath.ql 03fb1254cc797239de302fbf1ad1b4e7e926e2ec4423221fbec06425e3647f63 9ab60ad1f16d4fb04d3de9f8f05d959fc90c42bb8f0dfc04ccc906897f5c1633
test/extractor-tests/generated/StructPat/StructPat_getResolvedCrateOrigin.ql e3188ae0bb8835ad4aed5c775b52afb6cc7f9c520a8f62140d6cc590f2b8ce5d fd3e6eaf185e933e5ab1566cc49ef3497e50608070831879e01cf5a5ec23eae5
test/extractor-tests/generated/StructPat/StructPat_getResolvedPath.ql 1f4be7d78b187997093d52729d985dceb4c9e918274e0b9f06585e3337e3044b 2533855f07fce230dd567b2192ee20168bca077dbf7f1e8489dec142fcd396b8
test/extractor-tests/generated/StructPat/StructPat_getStructPatFieldList.ql f7b6dadd6ed0e40fb87e4be6eabe7fb96931b8c910c443588147202707655ced a43de755e0ca786a491afc97805e34d787c7bd03e7bca8df090e9386d4019688
test/extractor-tests/generated/StructPatField/StructPatField.ql 283c474e08a209ab4eb4bbc2cb6b7d3ff20326a0257c26d039f7d76b37859c87 276d06a98e091fe7737ecbb686753607c9506a1bca8ee78c801d1acf18e2923b
test/extractor-tests/generated/StructPatField/StructPatField.ql e6f468111706d4254b6c3e686c31e309c11b4246d8ed7eb288dd349ec0787c12 7ab1b5ead54fe09daf3d4cc6d8eb3e39fe253bede8822187de1a74a10cc59e01
test/extractor-tests/generated/StructPatField/StructPatField_getAttr.ql 5e1df4f73291bbefda06437859aef73457fe58a22c134ceb9148cfcc19b696e7 69aea129500dca110023f03c6337e4b1a86627d6d51c43585534cf826db13d04
test/extractor-tests/generated/StructPatField/StructPatField_getNameRef.ql 2496b1b5efe9036b4d93738ff4372396ff5dccad126e615f7ffd9b69ad44628b e8ce0dad6dd7561c11df59afcbb04a9c01fcdc66045f1abf31982e25d3f4b5ac
test/extractor-tests/generated/StructPatField/StructPatField_getIdentifier.ql bf44755d6b82d69610de44cab2d49362b10621589948b68480d80412acec820a ec06b8f947cdaca913fd44685e5ce2bf52281306808cbb17e7e88118c897f877
test/extractor-tests/generated/StructPatField/StructPatField_getPat.ql bb3e9ad8cdaac8723504fffbafa21acc95c5bce7843fc6f3641e98758d93573f 77e6f9946e66a25ac70622e65c164413e7001f4b8e9361a0850171fc0cead935
test/extractor-tests/generated/StructPatFieldList/StructPatFieldList.ql fad84896295380e3576bfaef384ac88b2f96a73196d8df3ec39ecc6184ec053f 3dd63ce5d1ffd48c873397368c6229de8da37e8f694f395165af8257a4d2faf2
test/extractor-tests/generated/StructPatFieldList/StructPatFieldList_getField.ql 4e6fa98e48d474f31585a644d6045b7d8427a76bb04810728ad121a43b59e8a2 e3b1d915aae3e3c3df752146e222df71667f73731d7337cc2eb391b13f097315
@@ -1198,10 +1198,10 @@ test/extractor-tests/generated/UseTree/UseTree_getRename.ql ec3917501f3c89ac4974
test/extractor-tests/generated/UseTree/UseTree_getUseTreeList.ql c265a88347e813840969ae934dfd2904bc06f502de77709bc0b1c7255e46382a 52a239c8ea5fd8fbfbd606559d70ecadc769887437a9bcab6fb3e774208ad868
test/extractor-tests/generated/UseTreeList/UseTreeList.ql cd943c15c86e66244caafeb95b960a5c3d351d5edbd506258744fb60a61af3b2 cfa584cd9d8aa08267fd1106745a66226b2c99fadd1da65059cc7ecf2f2e68cf
test/extractor-tests/generated/UseTreeList/UseTreeList_getUseTree.ql dd72966b1cb7b04f0267503013809063fcfb145e2b2d7d5250d9f24d2e405f9a 75b953aa11c51ca0fe95e67d50d6238962d8df4a4b9054999a2c6338e5a5613d
test/extractor-tests/generated/Variant/Variant.ql c60dd31adac91e09f8b1e5523d6b859747e64ef072c077b5a3326763f9f461f7 55d6446a3a831ed1137264678c5df027eb94cb3570a88d364994851fe6236999
test/extractor-tests/generated/Variant/Variant.ql 861e349a2c11571eb027e740b4bf29c0ce98b0f1342e45b364bb5fcbaa487d91 5825b12837862765e23ed09c08c146cc292b2305aadc531ad826ad5bb36f9cdc
test/extractor-tests/generated/Variant/Variant_getAttr.ql dd38e48e1eb05ce280b880652a90010eb63f7de3be7232411ba6265691249420 f8980680104de1e5fd40f264d8d62346aacaf6403a5e051f6fd680e234c82c1f
test/extractor-tests/generated/Variant/Variant_getCrateOrigin.ql 99e79930f8ff87a25f256926e5c3ce1ee0847daf6fadc5445fb33c85328b4c61 2dd64a53813790654c83be25b5e175c9c5b388e758723c2138fff095353fdd7b
test/extractor-tests/generated/Variant/Variant_getExpr.ql ce00af303d28f60c5fd1dc7df628c7974aced21884e223a2f656cb4f0d1a74d5 9de51a65510cf9a15801d4207b616915bd959c95ec7330fdb502c5dff5b650cc
test/extractor-tests/generated/Variant/Variant_getDiscriminant.ql 2adba17d4acd790ea7ff738a23fc8d691e40bbc0e1770bc0f15a6a6f0f1b37f2 6e28a8aef3cde78ce8db50e4a48c663d1aacd7a4cc8c212e7c440160da7ae4c2
test/extractor-tests/generated/Variant/Variant_getExtendedCanonicalPath.ql fe6a4bfd1440e7629d47283910de84c5e8c2f5645512780e710f53540b5bc886 b1e31b765cb1a5fe063abb8c1b2115e881ae28aa3ccd39e088ff8f2af20d6cf4
test/extractor-tests/generated/Variant/Variant_getFieldList.ql 083c8cf61989663de33d99b72dec231c308ccc8bb6739921465c473a07e8ea03 d03bff6945853c940acdc053b813d53b008ddab9a8bd4307826433828d4763ce
test/extractor-tests/generated/Variant/Variant_getName.ql 0d7b47bec9f9031c67f7b684112a84a311ef9b2efeb260bd7cd6f424011ca0d8 73565e6f965dd7fd7bb9b3408c7d7b69120e1971b67ab307fed293eb663a59ae

32
rust/ql/.gitattributes generated vendored
View File

@@ -131,7 +131,6 @@
/lib/codeql/rust/elements/PtrTypeRepr.qll linguist-generated
/lib/codeql/rust/elements/RangeExpr.qll linguist-generated
/lib/codeql/rust/elements/RangePat.qll linguist-generated
/lib/codeql/rust/elements/RecordFieldList.qll linguist-generated
/lib/codeql/rust/elements/RefExpr.qll linguist-generated
/lib/codeql/rust/elements/RefPat.qll linguist-generated
/lib/codeql/rust/elements/RefTypeRepr.qll linguist-generated
@@ -153,6 +152,7 @@
/lib/codeql/rust/elements/StructExprField.qll linguist-generated
/lib/codeql/rust/elements/StructExprFieldList.qll linguist-generated
/lib/codeql/rust/elements/StructField.qll linguist-generated
/lib/codeql/rust/elements/StructFieldList.qll linguist-generated
/lib/codeql/rust/elements/StructPat.qll linguist-generated
/lib/codeql/rust/elements/StructPatField.qll linguist-generated
/lib/codeql/rust/elements/StructPatFieldList.qll linguist-generated
@@ -369,8 +369,6 @@
/lib/codeql/rust/elements/internal/RangeExprConstructor.qll linguist-generated
/lib/codeql/rust/elements/internal/RangePatConstructor.qll linguist-generated
/lib/codeql/rust/elements/internal/RangePatImpl.qll linguist-generated
/lib/codeql/rust/elements/internal/RecordFieldListConstructor.qll linguist-generated
/lib/codeql/rust/elements/internal/RecordFieldListImpl.qll linguist-generated
/lib/codeql/rust/elements/internal/RefExprConstructor.qll linguist-generated
/lib/codeql/rust/elements/internal/RefPatConstructor.qll linguist-generated
/lib/codeql/rust/elements/internal/RefTypeReprConstructor.qll linguist-generated
@@ -402,6 +400,8 @@
/lib/codeql/rust/elements/internal/StructExprFieldListConstructor.qll linguist-generated
/lib/codeql/rust/elements/internal/StructExprFieldListImpl.qll linguist-generated
/lib/codeql/rust/elements/internal/StructFieldConstructor.qll linguist-generated
/lib/codeql/rust/elements/internal/StructFieldListConstructor.qll linguist-generated
/lib/codeql/rust/elements/internal/StructFieldListImpl.qll linguist-generated
/lib/codeql/rust/elements/internal/StructPatConstructor.qll linguist-generated
/lib/codeql/rust/elements/internal/StructPatFieldConstructor.qll linguist-generated
/lib/codeql/rust/elements/internal/StructPatFieldListConstructor.qll linguist-generated
@@ -597,7 +597,6 @@
/lib/codeql/rust/elements/internal/generated/RangeExpr.qll linguist-generated
/lib/codeql/rust/elements/internal/generated/RangePat.qll linguist-generated
/lib/codeql/rust/elements/internal/generated/Raw.qll linguist-generated
/lib/codeql/rust/elements/internal/generated/RecordFieldList.qll linguist-generated
/lib/codeql/rust/elements/internal/generated/RefExpr.qll linguist-generated
/lib/codeql/rust/elements/internal/generated/RefPat.qll linguist-generated
/lib/codeql/rust/elements/internal/generated/RefTypeRepr.qll linguist-generated
@@ -619,6 +618,7 @@
/lib/codeql/rust/elements/internal/generated/StructExprField.qll linguist-generated
/lib/codeql/rust/elements/internal/generated/StructExprFieldList.qll linguist-generated
/lib/codeql/rust/elements/internal/generated/StructField.qll linguist-generated
/lib/codeql/rust/elements/internal/generated/StructFieldList.qll linguist-generated
/lib/codeql/rust/elements/internal/generated/StructPat.qll linguist-generated
/lib/codeql/rust/elements/internal/generated/StructPatField.qll linguist-generated
/lib/codeql/rust/elements/internal/generated/StructPatFieldList.qll linguist-generated
@@ -692,7 +692,7 @@
/test/extractor-tests/generated/AssocTypeArg/AssocTypeArg.ql linguist-generated
/test/extractor-tests/generated/AssocTypeArg/AssocTypeArg_getConstArg.ql linguist-generated
/test/extractor-tests/generated/AssocTypeArg/AssocTypeArg_getGenericArgList.ql linguist-generated
/test/extractor-tests/generated/AssocTypeArg/AssocTypeArg_getNameRef.ql linguist-generated
/test/extractor-tests/generated/AssocTypeArg/AssocTypeArg_getIdentifier.ql linguist-generated
/test/extractor-tests/generated/AssocTypeArg/AssocTypeArg_getParamList.ql linguist-generated
/test/extractor-tests/generated/AssocTypeArg/AssocTypeArg_getRetType.ql linguist-generated
/test/extractor-tests/generated/AssocTypeArg/AssocTypeArg_getReturnTypeSyntax.ql linguist-generated
@@ -782,7 +782,7 @@
/test/extractor-tests/generated/ExternCrate/ExternCrate_getAttr.ql linguist-generated
/test/extractor-tests/generated/ExternCrate/ExternCrate_getCrateOrigin.ql linguist-generated
/test/extractor-tests/generated/ExternCrate/ExternCrate_getExtendedCanonicalPath.ql linguist-generated
/test/extractor-tests/generated/ExternCrate/ExternCrate_getNameRef.ql linguist-generated
/test/extractor-tests/generated/ExternCrate/ExternCrate_getIdentifier.ql linguist-generated
/test/extractor-tests/generated/ExternCrate/ExternCrate_getRename.ql linguist-generated
/test/extractor-tests/generated/ExternCrate/ExternCrate_getVisibility.ql linguist-generated
/test/extractor-tests/generated/ExternItemList/ExternItemList.ql linguist-generated
@@ -790,8 +790,8 @@
/test/extractor-tests/generated/ExternItemList/ExternItemList_getExternItem.ql linguist-generated
/test/extractor-tests/generated/FieldExpr/FieldExpr.ql linguist-generated
/test/extractor-tests/generated/FieldExpr/FieldExpr_getAttr.ql linguist-generated
/test/extractor-tests/generated/FieldExpr/FieldExpr_getExpr.ql linguist-generated
/test/extractor-tests/generated/FieldExpr/FieldExpr_getNameRef.ql linguist-generated
/test/extractor-tests/generated/FieldExpr/FieldExpr_getContainer.ql linguist-generated
/test/extractor-tests/generated/FieldExpr/FieldExpr_getIdentifier.ql linguist-generated
/test/extractor-tests/generated/FnPtrTypeRepr/FnPtrTypeRepr.ql linguist-generated
/test/extractor-tests/generated/FnPtrTypeRepr/FnPtrTypeRepr_getAbi.ql linguist-generated
/test/extractor-tests/generated/FnPtrTypeRepr/FnPtrTypeRepr_getParamList.ql linguist-generated
@@ -951,7 +951,7 @@
/test/extractor-tests/generated/MethodCallExpr/MethodCallExpr_getArgList.ql linguist-generated
/test/extractor-tests/generated/MethodCallExpr/MethodCallExpr_getAttr.ql linguist-generated
/test/extractor-tests/generated/MethodCallExpr/MethodCallExpr_getGenericArgList.ql linguist-generated
/test/extractor-tests/generated/MethodCallExpr/MethodCallExpr_getNameRef.ql linguist-generated
/test/extractor-tests/generated/MethodCallExpr/MethodCallExpr_getIdentifier.ql linguist-generated
/test/extractor-tests/generated/MethodCallExpr/MethodCallExpr_getReceiver.ql linguist-generated
/test/extractor-tests/generated/MethodCallExpr/MethodCallExpr_getResolvedCrateOrigin.ql linguist-generated
/test/extractor-tests/generated/MethodCallExpr/MethodCallExpr_getResolvedPath.ql linguist-generated
@@ -1000,7 +1000,7 @@
/test/extractor-tests/generated/Path/PathPat_getResolvedPath.ql linguist-generated
/test/extractor-tests/generated/Path/PathSegment.ql linguist-generated
/test/extractor-tests/generated/Path/PathSegment_getGenericArgList.ql linguist-generated
/test/extractor-tests/generated/Path/PathSegment_getNameRef.ql linguist-generated
/test/extractor-tests/generated/Path/PathSegment_getIdentifier.ql linguist-generated
/test/extractor-tests/generated/Path/PathSegment_getParenthesizedArgList.ql linguist-generated
/test/extractor-tests/generated/Path/PathSegment_getRetType.ql linguist-generated
/test/extractor-tests/generated/Path/PathSegment_getReturnTypeSyntax.ql linguist-generated
@@ -1025,8 +1025,6 @@
/test/extractor-tests/generated/RangePat/RangePat_getEnd.ql linguist-generated
/test/extractor-tests/generated/RangePat/RangePat_getOperatorName.ql linguist-generated
/test/extractor-tests/generated/RangePat/RangePat_getStart.ql linguist-generated
/test/extractor-tests/generated/RecordFieldList/RecordFieldList.ql linguist-generated
/test/extractor-tests/generated/RecordFieldList/RecordFieldList_getField.ql linguist-generated
/test/extractor-tests/generated/RefExpr/RefExpr.ql linguist-generated
/test/extractor-tests/generated/RefExpr/RefExpr_getAttr.ql linguist-generated
/test/extractor-tests/generated/RefExpr/RefExpr_getExpr.ql linguist-generated
@@ -1086,17 +1084,19 @@
/test/extractor-tests/generated/StructExprField/StructExprField.ql linguist-generated
/test/extractor-tests/generated/StructExprField/StructExprField_getAttr.ql linguist-generated
/test/extractor-tests/generated/StructExprField/StructExprField_getExpr.ql linguist-generated
/test/extractor-tests/generated/StructExprField/StructExprField_getNameRef.ql linguist-generated
/test/extractor-tests/generated/StructExprField/StructExprField_getIdentifier.ql linguist-generated
/test/extractor-tests/generated/StructExprFieldList/StructExprFieldList.ql linguist-generated
/test/extractor-tests/generated/StructExprFieldList/StructExprFieldList_getAttr.ql linguist-generated
/test/extractor-tests/generated/StructExprFieldList/StructExprFieldList_getField.ql linguist-generated
/test/extractor-tests/generated/StructExprFieldList/StructExprFieldList_getSpread.ql linguist-generated
/test/extractor-tests/generated/StructField/StructField.ql linguist-generated
/test/extractor-tests/generated/StructField/StructField_getAttr.ql linguist-generated
/test/extractor-tests/generated/StructField/StructField_getExpr.ql linguist-generated
/test/extractor-tests/generated/StructField/StructField_getDefault.ql linguist-generated
/test/extractor-tests/generated/StructField/StructField_getName.ql linguist-generated
/test/extractor-tests/generated/StructField/StructField_getTypeRepr.ql linguist-generated
/test/extractor-tests/generated/StructField/StructField_getVisibility.ql linguist-generated
/test/extractor-tests/generated/StructFieldList/StructFieldList.ql linguist-generated
/test/extractor-tests/generated/StructFieldList/StructFieldList_getField.ql linguist-generated
/test/extractor-tests/generated/StructPat/StructPat.ql linguist-generated
/test/extractor-tests/generated/StructPat/StructPat_getPath.ql linguist-generated
/test/extractor-tests/generated/StructPat/StructPat_getResolvedCrateOrigin.ql linguist-generated
@@ -1104,7 +1104,7 @@
/test/extractor-tests/generated/StructPat/StructPat_getStructPatFieldList.ql linguist-generated
/test/extractor-tests/generated/StructPatField/StructPatField.ql linguist-generated
/test/extractor-tests/generated/StructPatField/StructPatField_getAttr.ql linguist-generated
/test/extractor-tests/generated/StructPatField/StructPatField_getNameRef.ql linguist-generated
/test/extractor-tests/generated/StructPatField/StructPatField_getIdentifier.ql linguist-generated
/test/extractor-tests/generated/StructPatField/StructPatField_getPat.ql linguist-generated
/test/extractor-tests/generated/StructPatFieldList/StructPatFieldList.ql linguist-generated
/test/extractor-tests/generated/StructPatFieldList/StructPatFieldList_getField.ql linguist-generated
@@ -1203,7 +1203,7 @@
/test/extractor-tests/generated/Variant/Variant.ql linguist-generated
/test/extractor-tests/generated/Variant/Variant_getAttr.ql linguist-generated
/test/extractor-tests/generated/Variant/Variant_getCrateOrigin.ql linguist-generated
/test/extractor-tests/generated/Variant/Variant_getExpr.ql linguist-generated
/test/extractor-tests/generated/Variant/Variant_getDiscriminant.ql linguist-generated
/test/extractor-tests/generated/Variant/Variant_getExtendedCanonicalPath.ql linguist-generated
/test/extractor-tests/generated/Variant/Variant_getFieldList.ql linguist-generated
/test/extractor-tests/generated/Variant/Variant_getName.ql linguist-generated

View File

@@ -329,7 +329,7 @@ module ExprTrees {
}
class FieldExprTree extends StandardPostOrderTree instanceof FieldExpr {
override AstNode getChildNode(int i) { i = 0 and result = super.getExpr() }
override AstNode getChildNode(int i) { i = 0 and result = super.getContainer() }
}
class IfExprTree extends PostOrderTree instanceof IfExpr {

View File

@@ -901,7 +901,7 @@ module MakeCfgNodes<LocationSig Loc, InputSig<Loc> Input> {
override predicate relevantChild(AstNode child) {
none()
or
child = this.getExpr()
child = this.getContainer()
}
}
@@ -935,26 +935,26 @@ module MakeCfgNodes<LocationSig Loc, InputSig<Loc> Input> {
int getNumberOfAttrs() { result = count(int i | exists(this.getAttr(i))) }
/**
* Gets the expression of this field expression, if it exists.
* Gets the container of this field expression, if it exists.
*/
ExprCfgNode getExpr() {
any(ChildMapping mapping).hasCfgChild(node, node.getExpr(), this, result)
ExprCfgNode getContainer() {
any(ChildMapping mapping).hasCfgChild(node, node.getContainer(), this, result)
}
/**
* Holds if `getExpr()` exists.
* Holds if `getContainer()` exists.
*/
predicate hasExpr() { exists(this.getExpr()) }
predicate hasContainer() { exists(this.getContainer()) }
/**
* Gets the name reference of this field expression, if it exists.
* Gets the identifier of this field expression, if it exists.
*/
NameRef getNameRef() { result = node.getNameRef() }
NameRef getIdentifier() { result = node.getIdentifier() }
/**
* Holds if `getNameRef()` exists.
* Holds if `getIdentifier()` exists.
*/
predicate hasNameRef() { exists(this.getNameRef()) }
predicate hasIdentifier() { exists(this.getIdentifier()) }
}
final private class ParentForExpr extends ParentAstNode, ForExpr {
@@ -2003,14 +2003,14 @@ module MakeCfgNodes<LocationSig Loc, InputSig<Loc> Input> {
predicate hasGenericArgList() { exists(this.getGenericArgList()) }
/**
* Gets the name reference of this method call expression, if it exists.
* Gets the identifier of this method call expression, if it exists.
*/
NameRef getNameRef() { result = node.getNameRef() }
NameRef getIdentifier() { result = node.getIdentifier() }
/**
* Holds if `getNameRef()` exists.
* Holds if `getIdentifier()` exists.
*/
predicate hasNameRef() { exists(this.getNameRef()) }
predicate hasIdentifier() { exists(this.getIdentifier()) }
/**
* Gets the receiver of this method call expression, if it exists.
@@ -3460,14 +3460,14 @@ module MakeCfgNodes<LocationSig Loc, InputSig<Loc> Input> {
cfgNode
)
or
pred = "getExpr" and
pred = "getContainer" and
parent =
any(Nodes::FieldExprCfgNode cfgNode, FieldExpr astNode |
astNode = cfgNode.getFieldExpr() and
child = getDesugared(astNode.getExpr()) and
child = getDesugared(astNode.getContainer()) and
i = -1 and
hasCfgNode(child) and
not child = cfgNode.getExpr().getAstNode()
not child = cfgNode.getContainer().getAstNode()
|
cfgNode
)

View File

@@ -150,7 +150,7 @@ final class TuplePositionContent extends FieldContent, TTuplePositionContent {
override FieldExprCfgNode getAnAccess() {
// TODO: limit to tuple types
result.getNameRef().getText().toInt() = pos
result.getIdentifier().getText().toInt() = pos
}
override string toString() { result = "tuple." + pos.toString() }
@@ -262,7 +262,7 @@ newtype TContent =
TTuplePositionContent(int pos) {
pos in [0 .. max([
any(TuplePat pat).getNumberOfFields(),
any(FieldExpr access).getNameRef().getText().toInt()
any(FieldExpr access).getIdentifier().getText().toInt()
]
)]
} or

View File

@@ -688,7 +688,7 @@ module RustDataFlow implements InputSig<Location> {
node1.asPat().(RefPatCfgNode).getPat() = node2.asPat()
or
exists(FieldExprCfgNode access |
node1.asExpr() = access.getExpr() and
node1.asExpr() = access.getContainer() and
node2.asExpr() = access and
access = c.(FieldContent).getAnAccess()
)
@@ -771,7 +771,7 @@ module RustDataFlow implements InputSig<Location> {
exists(AssignmentExprCfgNode assignment, FieldExprCfgNode access |
assignment.getLhs() = access and
node1.asExpr() = assignment.getRhs() and
node2.asExpr() = access.getExpr() and
node2.asExpr() = access.getContainer() and
access = c.getAnAccess()
)
}

View File

@@ -47,7 +47,7 @@ module Input implements InputSig<Location, RustDataFlow> {
private class MethodCallExprNameRef extends SourceBase, SinkBase {
private MethodCallExpr call;
MethodCallExprNameRef() { this = call.getNameRef() }
MethodCallExprNameRef() { this = call.getIdentifier() }
override MethodCallExpr getCall() { result = call }
}

View File

@@ -464,7 +464,7 @@ newtype TNode =
e =
[
any(IndexExprCfgNode i).getBase(), //
any(FieldExprCfgNode access).getExpr(), //
any(FieldExprCfgNode access).getContainer(), //
any(TryExprCfgNode try).getExpr(), //
any(PrefixExprCfgNode pe | pe.getOperatorName() = "*").getExpr(), //
any(AwaitExprCfgNode a).getExpr(), any(MethodCallExprCfgNode mc).getReceiver(), //

View File

@@ -134,7 +134,6 @@ import codeql.rust.elements.PrefixExpr
import codeql.rust.elements.PtrTypeRepr
import codeql.rust.elements.RangeExpr
import codeql.rust.elements.RangePat
import codeql.rust.elements.RecordFieldList
import codeql.rust.elements.RefExpr
import codeql.rust.elements.RefPat
import codeql.rust.elements.RefTypeRepr
@@ -156,6 +155,7 @@ import codeql.rust.elements.StructExpr
import codeql.rust.elements.StructExprField
import codeql.rust.elements.StructExprFieldList
import codeql.rust.elements.StructField
import codeql.rust.elements.StructFieldList
import codeql.rust.elements.StructPat
import codeql.rust.elements.StructPatField
import codeql.rust.elements.StructPatFieldList

View File

@@ -1,9 +1,9 @@
// generated by codegen, do not edit
/**
* This module provides the public class `RecordFieldList`.
* This module provides the public class `StructFieldList`.
*/
private import internal.RecordFieldListImpl
private import internal.StructFieldListImpl
import codeql.rust.elements.FieldList
import codeql.rust.elements.StructField
@@ -13,4 +13,4 @@ import codeql.rust.elements.StructField
* todo!()
* ```
*/
final class RecordFieldList = Impl::RecordFieldList;
final class StructFieldList = Impl::StructFieldList;

View File

@@ -8,7 +8,7 @@ import codeql.rust.elements.Attr
import codeql.rust.elements.GenericParamList
import codeql.rust.elements.Item
import codeql.rust.elements.Name
import codeql.rust.elements.RecordFieldList
import codeql.rust.elements.StructFieldList
import codeql.rust.elements.VariantDef
import codeql.rust.elements.Visibility
import codeql.rust.elements.WhereClause

View File

@@ -30,8 +30,8 @@ module Impl {
override string toStringImpl() {
exists(string abbr, string name |
abbr = this.getExpr().toAbbreviatedString() and
name = this.getNameRef().getText() and
abbr = this.getContainer().toAbbreviatedString() and
name = this.getIdentifier().getText() and
if abbr = "..." then result = "... ." + name else result = abbr + "." + name
)
}

View File

@@ -46,7 +46,7 @@ module Impl {
exists(string base, string separator |
base = this.getReceiver().toAbbreviatedString() and
(if base = "..." then separator = " ." else separator = ".") and
result = base + separator + this.getNameRef().toStringImpl() + "(...)"
result = base + separator + this.getIdentifier().toStringImpl() + "(...)"
)
}
}

View File

@@ -39,7 +39,7 @@ module Impl {
* Gets the text of this path, if it exists.
*/
pragma[nomagic]
string getText() { result = this.getSegment().getNameRef().getText() }
string getText() { result = this.getSegment().getIdentifier().getText() }
}
/** A simple identifier path. */
@@ -54,7 +54,7 @@ module Impl {
not ps.hasParenthesizedArgList() and
not ps.hasTypeRepr() and
not ps.hasReturnTypeSyntax() and
name = ps.getNameRef().getText()
name = ps.getIdentifier().getText()
)
}

View File

@@ -24,7 +24,7 @@ module Impl {
private string toAbbreviatedStringPart(int index) {
index = 0 and
if this.hasTypeRepr() then result = "<...>" else result = this.getNameRef().getText()
if this.hasTypeRepr() then result = "<...>" else result = this.getIdentifier().getText()
or
index = 1 and result = this.getGenericArgList().toAbbreviatedString()
}

View File

@@ -25,9 +25,9 @@ module Impl {
override string toStringImpl() { result = concat(int i | | this.toStringPart(i) order by i) }
private string toStringPart(int index) {
index = 0 and result = this.getNameRef().getText()
index = 0 and result = this.getIdentifier().getText()
or
index = 1 and this.hasNameRef() and result = ": "
index = 1 and this.hasIdentifier() and result = ": "
or
index = 2 and
result = this.getExpr().toAbbreviatedString()
@@ -44,9 +44,9 @@ module Impl {
* ```
*/
string getFieldName() {
result = this.getNameRef().getText()
result = this.getIdentifier().getText()
or
not this.hasNameRef() and
not this.hasIdentifier() and
result = this.getExpr().(PathExpr).getPath().(PathImpl::IdentPath).getName()
}
}

View File

@@ -1,14 +1,14 @@
// generated by codegen, remove this comment if you wish to edit this file
/**
* This module defines the hook used internally to tweak the characteristic predicate of
* `RecordFieldList` synthesized instances.
* `StructFieldList` synthesized instances.
* INTERNAL: Do not use.
*/
private import codeql.rust.elements.internal.generated.Raw
/**
* The characteristic predicate of `RecordFieldList` synthesized instances.
* The characteristic predicate of `StructFieldList` synthesized instances.
* INTERNAL: Do not use.
*/
predicate constructRecordFieldList(Raw::RecordFieldList id) { any() }
predicate constructStructFieldList(Raw::StructFieldList id) { any() }

View File

@@ -1,14 +1,14 @@
// generated by codegen, remove this comment if you wish to edit this file
/**
* This module provides a hand-modifiable wrapper around the generated class `RecordFieldList`.
* This module provides a hand-modifiable wrapper around the generated class `StructFieldList`.
*
* INTERNAL: Do not use.
*/
private import codeql.rust.elements.internal.generated.RecordFieldList
private import codeql.rust.elements.internal.generated.StructFieldList
/**
* INTERNAL: This module contains the customizable definition of `RecordFieldList` and should not
* INTERNAL: This module contains the customizable definition of `StructFieldList` and should not
* be referenced directly.
*/
module Impl {
@@ -18,5 +18,5 @@ module Impl {
* todo!()
* ```
*/
class RecordFieldList extends Generated::RecordFieldList { }
class StructFieldList extends Generated::StructFieldList { }
}

View File

@@ -25,7 +25,7 @@ module Impl {
/** Gets the record field named `name`, if any. */
pragma[nomagic]
StructField getStructField(string name) {
result = this.getFieldList().(RecordFieldList).getAField() and
result = this.getFieldList().(StructFieldList).getAField() and
result.getName().getText() = name
}

View File

@@ -24,9 +24,9 @@ module Impl {
override string toStringImpl() { result = concat(int i | | this.toStringPart(i) order by i) }
private string toStringPart(int index) {
index = 0 and result = this.getNameRef().getText()
index = 0 and result = this.getIdentifier().getText()
or
index = 1 and this.hasNameRef() and result = ": "
index = 1 and this.hasIdentifier() and result = ": "
or
index = 2 and
result = this.getPat().toAbbreviatedString()
@@ -43,9 +43,9 @@ module Impl {
* ```
*/
string getFieldName() {
result = this.getNameRef().getText()
result = this.getIdentifier().getText()
or
not this.hasNameRef() and
not this.hasIdentifier() and
result = this.getPat().(IdentPat).getName().getText()
}
}

View File

@@ -25,7 +25,7 @@ module Impl {
/** Gets the record field named `name`, if any. */
pragma[nomagic]
StructField getStructField(string name) {
result = this.getFieldList().(RecordFieldList).getAField() and
result = this.getFieldList().(StructFieldList).getAField() and
result.getName().getText() = name
}

View File

@@ -22,18 +22,18 @@ module Generated {
override string getAPrimaryQlClass() { result = "AsmRegSpec" }
/**
* Gets the name reference of this asm reg spec, if it exists.
* Gets the identifier of this asm reg spec, if it exists.
*/
NameRef getNameRef() {
NameRef getIdentifier() {
result =
Synth::convertNameRefFromRaw(Synth::convertAsmRegSpecToRaw(this)
.(Raw::AsmRegSpec)
.getNameRef())
.getIdentifier())
}
/**
* Holds if `getNameRef()` exists.
* Holds if `getIdentifier()` exists.
*/
final predicate hasNameRef() { exists(this.getNameRef()) }
final predicate hasIdentifier() { exists(this.getIdentifier()) }
}
}

View File

@@ -63,19 +63,19 @@ module Generated {
final predicate hasGenericArgList() { exists(this.getGenericArgList()) }
/**
* Gets the name reference of this assoc type argument, if it exists.
* Gets the identifier of this assoc type argument, if it exists.
*/
NameRef getNameRef() {
NameRef getIdentifier() {
result =
Synth::convertNameRefFromRaw(Synth::convertAssocTypeArgToRaw(this)
.(Raw::AssocTypeArg)
.getNameRef())
.getIdentifier())
}
/**
* Holds if `getNameRef()` exists.
* Holds if `getIdentifier()` exists.
*/
final predicate hasNameRef() { exists(this.getNameRef()) }
final predicate hasIdentifier() { exists(this.getIdentifier()) }
/**
* Gets the parameter list of this assoc type argument, if it exists.

View File

@@ -49,19 +49,19 @@ module Generated {
final int getNumberOfAttrs() { result = count(int i | exists(this.getAttr(i))) }
/**
* Gets the name reference of this extern crate, if it exists.
* Gets the identifier of this extern crate, if it exists.
*/
NameRef getNameRef() {
NameRef getIdentifier() {
result =
Synth::convertNameRefFromRaw(Synth::convertExternCrateToRaw(this)
.(Raw::ExternCrate)
.getNameRef())
.getIdentifier())
}
/**
* Holds if `getNameRef()` exists.
* Holds if `getIdentifier()` exists.
*/
final predicate hasNameRef() { exists(this.getNameRef()) }
final predicate hasIdentifier() { exists(this.getIdentifier()) }
/**
* Gets the rename of this extern crate, if it exists.

View File

@@ -46,31 +46,31 @@ module Generated {
final int getNumberOfAttrs() { result = count(int i | exists(this.getAttr(i))) }
/**
* Gets the expression of this field expression, if it exists.
* Gets the container of this field expression, if it exists.
*/
Expr getExpr() {
Expr getContainer() {
result =
Synth::convertExprFromRaw(Synth::convertFieldExprToRaw(this).(Raw::FieldExpr).getExpr())
Synth::convertExprFromRaw(Synth::convertFieldExprToRaw(this).(Raw::FieldExpr).getContainer())
}
/**
* Holds if `getExpr()` exists.
* Holds if `getContainer()` exists.
*/
final predicate hasExpr() { exists(this.getExpr()) }
final predicate hasContainer() { exists(this.getContainer()) }
/**
* Gets the name reference of this field expression, if it exists.
* Gets the identifier of this field expression, if it exists.
*/
NameRef getNameRef() {
NameRef getIdentifier() {
result =
Synth::convertNameRefFromRaw(Synth::convertFieldExprToRaw(this)
.(Raw::FieldExpr)
.getNameRef())
.getIdentifier())
}
/**
* Holds if `getNameRef()` exists.
* Holds if `getIdentifier()` exists.
*/
final predicate hasNameRef() { exists(this.getNameRef()) }
final predicate hasIdentifier() { exists(this.getIdentifier()) }
}
}

View File

@@ -47,19 +47,19 @@ module Generated {
final predicate hasGenericArgList() { exists(this.getGenericArgList()) }
/**
* Gets the name reference of this method call expression, if it exists.
* Gets the identifier of this method call expression, if it exists.
*/
NameRef getNameRef() {
NameRef getIdentifier() {
result =
Synth::convertNameRefFromRaw(Synth::convertMethodCallExprToRaw(this)
.(Raw::MethodCallExpr)
.getNameRef())
.getIdentifier())
}
/**
* Holds if `getNameRef()` exists.
* Holds if `getIdentifier()` exists.
*/
final predicate hasNameRef() { exists(this.getNameRef()) }
final predicate hasIdentifier() { exists(this.getIdentifier()) }
/**
* Gets the receiver of this method call expression, if it exists.

View File

@@ -290,17 +290,17 @@ private module Impl {
}
private Element getImmediateChildOfAsmRegSpec(AsmRegSpec e, int index, string partialPredicateCall) {
exists(int b, int bAstNode, int n, int nNameRef |
exists(int b, int bAstNode, int n, int nIdentifier |
b = 0 and
bAstNode = b + 1 + max(int i | i = -1 or exists(getImmediateChildOfAstNode(e, i, _)) | i) and
n = bAstNode and
nNameRef = n + 1 and
nIdentifier = n + 1 and
(
none()
or
result = getImmediateChildOfAstNode(e, index - b, partialPredicateCall)
or
index = n and result = e.getNameRef() and partialPredicateCall = "NameRef()"
index = n and result = e.getIdentifier() and partialPredicateCall = "Identifier()"
)
)
}
@@ -831,15 +831,15 @@ private module Impl {
PathSegment e, int index, string partialPredicateCall
) {
exists(
int b, int bAstNode, int n, int nGenericArgList, int nNameRef, int nParenthesizedArgList,
int b, int bAstNode, int n, int nGenericArgList, int nIdentifier, int nParenthesizedArgList,
int nRetType, int nReturnTypeSyntax, int nTypeRepr, int nTraitTypeRepr
|
b = 0 and
bAstNode = b + 1 + max(int i | i = -1 or exists(getImmediateChildOfAstNode(e, i, _)) | i) and
n = bAstNode and
nGenericArgList = n + 1 and
nNameRef = nGenericArgList + 1 and
nParenthesizedArgList = nNameRef + 1 and
nIdentifier = nGenericArgList + 1 and
nParenthesizedArgList = nIdentifier + 1 and
nRetType = nParenthesizedArgList + 1 and
nReturnTypeSyntax = nRetType + 1 and
nTypeRepr = nReturnTypeSyntax + 1 and
@@ -851,9 +851,11 @@ private module Impl {
or
index = n and result = e.getGenericArgList() and partialPredicateCall = "GenericArgList()"
or
index = nGenericArgList and result = e.getNameRef() and partialPredicateCall = "NameRef()"
index = nGenericArgList and
result = e.getIdentifier() and
partialPredicateCall = "Identifier()"
or
index = nNameRef and
index = nIdentifier and
result = e.getParenthesizedArgList() and
partialPredicateCall = "ParenthesizedArgList()"
or
@@ -999,13 +1001,13 @@ private module Impl {
private Element getImmediateChildOfStructExprField(
StructExprField e, int index, string partialPredicateCall
) {
exists(int b, int bAstNode, int n, int nAttr, int nExpr, int nNameRef |
exists(int b, int bAstNode, int n, int nAttr, int nExpr, int nIdentifier |
b = 0 and
bAstNode = b + 1 + max(int i | i = -1 or exists(getImmediateChildOfAstNode(e, i, _)) | i) and
n = bAstNode and
nAttr = n + 1 + max(int i | i = -1 or exists(e.getAttr(i)) | i) and
nExpr = nAttr + 1 and
nNameRef = nExpr + 1 and
nIdentifier = nExpr + 1 and
(
none()
or
@@ -1016,7 +1018,7 @@ private module Impl {
or
index = nAttr and result = e.getExpr() and partialPredicateCall = "Expr()"
or
index = nExpr and result = e.getNameRef() and partialPredicateCall = "NameRef()"
index = nExpr and result = e.getIdentifier() and partialPredicateCall = "Identifier()"
)
)
}
@@ -1051,14 +1053,14 @@ private module Impl {
StructField e, int index, string partialPredicateCall
) {
exists(
int b, int bAstNode, int n, int nAttr, int nExpr, int nName, int nTypeRepr, int nVisibility
int b, int bAstNode, int n, int nAttr, int nDefault, int nName, int nTypeRepr, int nVisibility
|
b = 0 and
bAstNode = b + 1 + max(int i | i = -1 or exists(getImmediateChildOfAstNode(e, i, _)) | i) and
n = bAstNode and
nAttr = n + 1 + max(int i | i = -1 or exists(e.getAttr(i)) | i) and
nExpr = nAttr + 1 and
nName = nExpr + 1 and
nDefault = nAttr + 1 and
nName = nDefault + 1 and
nTypeRepr = nName + 1 and
nVisibility = nTypeRepr + 1 and
(
@@ -1069,9 +1071,9 @@ private module Impl {
result = e.getAttr(index - n) and
partialPredicateCall = "Attr(" + (index - n).toString() + ")"
or
index = nAttr and result = e.getExpr() and partialPredicateCall = "Expr()"
index = nAttr and result = e.getDefault() and partialPredicateCall = "Default()"
or
index = nExpr and result = e.getName() and partialPredicateCall = "Name()"
index = nDefault and result = e.getName() and partialPredicateCall = "Name()"
or
index = nName and result = e.getTypeRepr() and partialPredicateCall = "TypeRepr()"
or
@@ -1083,13 +1085,13 @@ private module Impl {
private Element getImmediateChildOfStructPatField(
StructPatField e, int index, string partialPredicateCall
) {
exists(int b, int bAstNode, int n, int nAttr, int nNameRef, int nPat |
exists(int b, int bAstNode, int n, int nAttr, int nIdentifier, int nPat |
b = 0 and
bAstNode = b + 1 + max(int i | i = -1 or exists(getImmediateChildOfAstNode(e, i, _)) | i) and
n = bAstNode and
nAttr = n + 1 + max(int i | i = -1 or exists(e.getAttr(i)) | i) and
nNameRef = nAttr + 1 and
nPat = nNameRef + 1 and
nIdentifier = nAttr + 1 and
nPat = nIdentifier + 1 and
(
none()
or
@@ -1098,9 +1100,9 @@ private module Impl {
result = e.getAttr(index - n) and
partialPredicateCall = "Attr(" + (index - n).toString() + ")"
or
index = nAttr and result = e.getNameRef() and partialPredicateCall = "NameRef()"
index = nAttr and result = e.getIdentifier() and partialPredicateCall = "Identifier()"
or
index = nNameRef and result = e.getPat() and partialPredicateCall = "Pat()"
index = nIdentifier and result = e.getPat() and partialPredicateCall = "Pat()"
)
)
}
@@ -1639,7 +1641,7 @@ private module Impl {
AssocTypeArg e, int index, string partialPredicateCall
) {
exists(
int b, int bGenericArg, int n, int nConstArg, int nGenericArgList, int nNameRef,
int b, int bGenericArg, int n, int nConstArg, int nGenericArgList, int nIdentifier,
int nParamList, int nRetType, int nReturnTypeSyntax, int nTypeRepr, int nTypeBoundList
|
b = 0 and
@@ -1648,8 +1650,8 @@ private module Impl {
n = bGenericArg and
nConstArg = n + 1 and
nGenericArgList = nConstArg + 1 and
nNameRef = nGenericArgList + 1 and
nParamList = nNameRef + 1 and
nIdentifier = nGenericArgList + 1 and
nParamList = nIdentifier + 1 and
nRetType = nParamList + 1 and
nReturnTypeSyntax = nRetType + 1 and
nTypeRepr = nReturnTypeSyntax + 1 and
@@ -1665,9 +1667,11 @@ private module Impl {
result = e.getGenericArgList() and
partialPredicateCall = "GenericArgList()"
or
index = nGenericArgList and result = e.getNameRef() and partialPredicateCall = "NameRef()"
index = nGenericArgList and
result = e.getIdentifier() and
partialPredicateCall = "Identifier()"
or
index = nNameRef and result = e.getParamList() and partialPredicateCall = "ParamList()"
index = nIdentifier and result = e.getParamList() and partialPredicateCall = "ParamList()"
or
index = nParamList and result = e.getRetType() and partialPredicateCall = "RetType()"
or
@@ -1993,13 +1997,13 @@ private module Impl {
}
private Element getImmediateChildOfFieldExpr(FieldExpr e, int index, string partialPredicateCall) {
exists(int b, int bExpr, int n, int nAttr, int nExpr, int nNameRef |
exists(int b, int bExpr, int n, int nAttr, int nContainer, int nIdentifier |
b = 0 and
bExpr = b + 1 + max(int i | i = -1 or exists(getImmediateChildOfExpr(e, i, _)) | i) and
n = bExpr and
nAttr = n + 1 + max(int i | i = -1 or exists(e.getAttr(i)) | i) and
nExpr = nAttr + 1 and
nNameRef = nExpr + 1 and
nContainer = nAttr + 1 and
nIdentifier = nContainer + 1 and
(
none()
or
@@ -2008,9 +2012,9 @@ private module Impl {
result = e.getAttr(index - n) and
partialPredicateCall = "Attr(" + (index - n).toString() + ")"
or
index = nAttr and result = e.getExpr() and partialPredicateCall = "Expr()"
index = nAttr and result = e.getContainer() and partialPredicateCall = "Container()"
or
index = nExpr and result = e.getNameRef() and partialPredicateCall = "NameRef()"
index = nContainer and result = e.getIdentifier() and partialPredicateCall = "Identifier()"
)
)
}
@@ -2733,25 +2737,6 @@ private module Impl {
)
}
private Element getImmediateChildOfRecordFieldList(
RecordFieldList e, int index, string partialPredicateCall
) {
exists(int b, int bFieldList, int n, int nField |
b = 0 and
bFieldList = b + 1 + max(int i | i = -1 or exists(getImmediateChildOfFieldList(e, i, _)) | i) and
n = bFieldList and
nField = n + 1 + max(int i | i = -1 or exists(e.getField(i)) | i) and
(
none()
or
result = getImmediateChildOfFieldList(e, index - b, partialPredicateCall)
or
result = e.getField(index - n) and
partialPredicateCall = "Field(" + (index - n).toString() + ")"
)
)
}
private Element getImmediateChildOfRefExpr(RefExpr e, int index, string partialPredicateCall) {
exists(int b, int bExpr, int n, int nAttr, int nExpr |
b = 0 and
@@ -2900,6 +2885,25 @@ private module Impl {
)
}
private Element getImmediateChildOfStructFieldList(
StructFieldList e, int index, string partialPredicateCall
) {
exists(int b, int bFieldList, int n, int nField |
b = 0 and
bFieldList = b + 1 + max(int i | i = -1 or exists(getImmediateChildOfFieldList(e, i, _)) | i) and
n = bFieldList and
nField = n + 1 + max(int i | i = -1 or exists(e.getField(i)) | i) and
(
none()
or
result = getImmediateChildOfFieldList(e, index - b, partialPredicateCall)
or
result = e.getField(index - n) and
partialPredicateCall = "Field(" + (index - n).toString() + ")"
)
)
}
private Element getImmediateChildOfTryExpr(TryExpr e, int index, string partialPredicateCall) {
exists(int b, int bExpr, int n, int nAttr, int nExpr |
b = 0 and
@@ -3063,7 +3067,7 @@ private module Impl {
private Element getImmediateChildOfVariant(Variant e, int index, string partialPredicateCall) {
exists(
int b, int bVariantDef, int bAddressable, int n, int nAttr, int nExpr, int nFieldList,
int b, int bVariantDef, int bAddressable, int n, int nAttr, int nDiscriminant, int nFieldList,
int nName, int nVisibility
|
b = 0 and
@@ -3073,8 +3077,8 @@ private module Impl {
bVariantDef + 1 + max(int i | i = -1 or exists(getImmediateChildOfAddressable(e, i, _)) | i) and
n = bAddressable and
nAttr = n + 1 + max(int i | i = -1 or exists(e.getAttr(i)) | i) and
nExpr = nAttr + 1 and
nFieldList = nExpr + 1 and
nDiscriminant = nAttr + 1 and
nFieldList = nDiscriminant + 1 and
nName = nFieldList + 1 and
nVisibility = nName + 1 and
(
@@ -3087,9 +3091,9 @@ private module Impl {
result = e.getAttr(index - n) and
partialPredicateCall = "Attr(" + (index - n).toString() + ")"
or
index = nAttr and result = e.getExpr() and partialPredicateCall = "Expr()"
index = nAttr and result = e.getDiscriminant() and partialPredicateCall = "Discriminant()"
or
index = nExpr and result = e.getFieldList() and partialPredicateCall = "FieldList()"
index = nDiscriminant and result = e.getFieldList() and partialPredicateCall = "FieldList()"
or
index = nFieldList and result = e.getName() and partialPredicateCall = "Name()"
or
@@ -3335,13 +3339,13 @@ private module Impl {
private Element getImmediateChildOfExternCrate(
ExternCrate e, int index, string partialPredicateCall
) {
exists(int b, int bItem, int n, int nAttr, int nNameRef, int nRename, int nVisibility |
exists(int b, int bItem, int n, int nAttr, int nIdentifier, int nRename, int nVisibility |
b = 0 and
bItem = b + 1 + max(int i | i = -1 or exists(getImmediateChildOfItem(e, i, _)) | i) and
n = bItem and
nAttr = n + 1 + max(int i | i = -1 or exists(e.getAttr(i)) | i) and
nNameRef = nAttr + 1 and
nRename = nNameRef + 1 and
nIdentifier = nAttr + 1 and
nRename = nIdentifier + 1 and
nVisibility = nRename + 1 and
(
none()
@@ -3351,9 +3355,9 @@ private module Impl {
result = e.getAttr(index - n) and
partialPredicateCall = "Attr(" + (index - n).toString() + ")"
or
index = nAttr and result = e.getNameRef() and partialPredicateCall = "NameRef()"
index = nAttr and result = e.getIdentifier() and partialPredicateCall = "Identifier()"
or
index = nNameRef and result = e.getRename() and partialPredicateCall = "Rename()"
index = nIdentifier and result = e.getRename() and partialPredicateCall = "Rename()"
or
index = nRename and result = e.getVisibility() and partialPredicateCall = "Visibility()"
)
@@ -3584,7 +3588,7 @@ private module Impl {
MethodCallExpr e, int index, string partialPredicateCall
) {
exists(
int b, int bCallExprBase, int bResolvable, int n, int nGenericArgList, int nNameRef,
int b, int bCallExprBase, int bResolvable, int n, int nGenericArgList, int nIdentifier,
int nReceiver
|
b = 0 and
@@ -3595,8 +3599,8 @@ private module Impl {
max(int i | i = -1 or exists(getImmediateChildOfResolvable(e, i, _)) | i) and
n = bResolvable and
nGenericArgList = n + 1 and
nNameRef = nGenericArgList + 1 and
nReceiver = nNameRef + 1 and
nIdentifier = nGenericArgList + 1 and
nReceiver = nIdentifier + 1 and
(
none()
or
@@ -3606,9 +3610,11 @@ private module Impl {
or
index = n and result = e.getGenericArgList() and partialPredicateCall = "GenericArgList()"
or
index = nGenericArgList and result = e.getNameRef() and partialPredicateCall = "NameRef()"
index = nGenericArgList and
result = e.getIdentifier() and
partialPredicateCall = "Identifier()"
or
index = nNameRef and result = e.getReceiver() and partialPredicateCall = "Receiver()"
index = nIdentifier and result = e.getReceiver() and partialPredicateCall = "Receiver()"
)
)
}
@@ -4328,8 +4334,6 @@ private module Impl {
or
result = getImmediateChildOfRangePat(e, index, partialAccessor)
or
result = getImmediateChildOfRecordFieldList(e, index, partialAccessor)
or
result = getImmediateChildOfRefExpr(e, index, partialAccessor)
or
result = getImmediateChildOfRefPat(e, index, partialAccessor)
@@ -4346,6 +4350,8 @@ private module Impl {
or
result = getImmediateChildOfSliceTypeRepr(e, index, partialAccessor)
or
result = getImmediateChildOfStructFieldList(e, index, partialAccessor)
or
result = getImmediateChildOfTryExpr(e, index, partialAccessor)
or
result = getImmediateChildOfTupleExpr(e, index, partialAccessor)

View File

@@ -44,19 +44,19 @@ module Generated {
final predicate hasGenericArgList() { exists(this.getGenericArgList()) }
/**
* Gets the name reference of this path segment, if it exists.
* Gets the identifier of this path segment, if it exists.
*/
NameRef getNameRef() {
NameRef getIdentifier() {
result =
Synth::convertNameRefFromRaw(Synth::convertPathSegmentToRaw(this)
.(Raw::PathSegment)
.getNameRef())
.getIdentifier())
}
/**
* Holds if `getNameRef()` exists.
* Holds if `getIdentifier()` exists.
*/
final predicate hasNameRef() { exists(this.getNameRef()) }
final predicate hasIdentifier() { exists(this.getIdentifier()) }
/**
* Gets the parenthesized argument list of this path segment, if it exists.

View File

@@ -227,9 +227,9 @@ module Raw {
override string toString() { result = "AsmRegSpec" }
/**
* Gets the name reference of this asm reg spec, if it exists.
* Gets the identifier of this asm reg spec, if it exists.
*/
NameRef getNameRef() { asm_reg_spec_name_refs(this, result) }
NameRef getIdentifier() { asm_reg_spec_identifiers(this, result) }
}
/**
@@ -739,9 +739,9 @@ module Raw {
GenericArgList getGenericArgList() { path_segment_generic_arg_lists(this, result) }
/**
* Gets the name reference of this path segment, if it exists.
* Gets the identifier of this path segment, if it exists.
*/
NameRef getNameRef() { path_segment_name_refs(this, result) }
NameRef getIdentifier() { path_segment_identifiers(this, result) }
/**
* Gets the parenthesized argument list of this path segment, if it exists.
@@ -904,9 +904,9 @@ module Raw {
Expr getExpr() { struct_expr_field_exprs(this, result) }
/**
* Gets the name reference of this struct expression field, if it exists.
* Gets the identifier of this struct expression field, if it exists.
*/
NameRef getNameRef() { struct_expr_field_name_refs(this, result) }
NameRef getIdentifier() { struct_expr_field_identifiers(this, result) }
}
/**
@@ -951,9 +951,9 @@ module Raw {
Attr getAttr(int index) { struct_field_attrs(this, index, result) }
/**
* Gets the expression of this struct field, if it exists.
* Gets the default of this struct field, if it exists.
*/
Expr getExpr() { struct_field_exprs(this, result) }
Expr getDefault() { struct_field_defaults(this, result) }
/**
* Gets the name of this struct field, if it exists.
@@ -987,9 +987,9 @@ module Raw {
Attr getAttr(int index) { struct_pat_field_attrs(this, index, result) }
/**
* Gets the name reference of this struct pattern field, if it exists.
* Gets the identifier of this struct pattern field, if it exists.
*/
NameRef getNameRef() { struct_pat_field_name_refs(this, result) }
NameRef getIdentifier() { struct_pat_field_identifiers(this, result) }
/**
* Gets the pattern of this struct pattern field, if it exists.
@@ -1468,9 +1468,9 @@ module Raw {
GenericArgList getGenericArgList() { assoc_type_arg_generic_arg_lists(this, result) }
/**
* Gets the name reference of this assoc type argument, if it exists.
* Gets the identifier of this assoc type argument, if it exists.
*/
NameRef getNameRef() { assoc_type_arg_name_refs(this, result) }
NameRef getIdentifier() { assoc_type_arg_identifiers(this, result) }
/**
* Gets the parameter list of this assoc type argument, if it exists.
@@ -1927,14 +1927,14 @@ module Raw {
Attr getAttr(int index) { field_expr_attrs(this, index, result) }
/**
* Gets the expression of this field expression, if it exists.
* Gets the container of this field expression, if it exists.
*/
Expr getExpr() { field_expr_exprs(this, result) }
Expr getContainer() { field_expr_containers(this, result) }
/**
* Gets the name reference of this field expression, if it exists.
* Gets the identifier of this field expression, if it exists.
*/
NameRef getNameRef() { field_expr_name_refs(this, result) }
NameRef getIdentifier() { field_expr_identifiers(this, result) }
}
/**
@@ -2743,22 +2743,6 @@ module Raw {
Pat getStart() { range_pat_starts(this, result) }
}
/**
* INTERNAL: Do not use.
* A field list of a struct expression. For example:
* ```rust
* todo!()
* ```
*/
class RecordFieldList extends @record_field_list, FieldList {
override string toString() { result = "RecordFieldList" }
/**
* Gets the `index`th field of this record field list (0-based).
*/
StructField getField(int index) { record_field_list_fields(this, index, result) }
}
/**
* INTERNAL: Do not use.
* A reference expression. For example:
@@ -2966,6 +2950,22 @@ module Raw {
TypeRepr getTypeRepr() { slice_type_repr_type_reprs(this, result) }
}
/**
* INTERNAL: Do not use.
* A field list of a struct expression. For example:
* ```rust
* todo!()
* ```
*/
class StructFieldList extends @struct_field_list, FieldList {
override string toString() { result = "StructFieldList" }
/**
* Gets the `index`th field of this struct field list (0-based).
*/
StructField getField(int index) { struct_field_list_fields(this, index, result) }
}
/**
* INTERNAL: Do not use.
* A TryExpr. For example:
@@ -3137,9 +3137,9 @@ module Raw {
Attr getAttr(int index) { variant_attrs(this, index, result) }
/**
* Gets the expression of this variant, if it exists.
* Gets the discriminant of this variant, if it exists.
*/
Expr getExpr() { variant_exprs(this, result) }
Expr getDiscriminant() { variant_discriminants(this, result) }
/**
* Gets the field list of this variant, if it exists.
@@ -3427,9 +3427,9 @@ module Raw {
Attr getAttr(int index) { extern_crate_attrs(this, index, result) }
/**
* Gets the name reference of this extern crate, if it exists.
* Gets the identifier of this extern crate, if it exists.
*/
NameRef getNameRef() { extern_crate_name_refs(this, result) }
NameRef getIdentifier() { extern_crate_identifiers(this, result) }
/**
* Gets the rename of this extern crate, if it exists.
@@ -3706,9 +3706,9 @@ module Raw {
GenericArgList getGenericArgList() { method_call_expr_generic_arg_lists(this, result) }
/**
* Gets the name reference of this method call expression, if it exists.
* Gets the identifier of this method call expression, if it exists.
*/
NameRef getNameRef() { method_call_expr_name_refs(this, result) }
NameRef getIdentifier() { method_call_expr_identifiers(this, result) }
/**
* Gets the receiver of this method call expression, if it exists.
@@ -3854,7 +3854,7 @@ module Raw {
/**
* Gets the field list of this struct, if it exists.
*/
FieldList getFieldList() { struct_field_lists(this, result) }
FieldList getFieldList() { struct_field_lists_(this, result) }
/**
* Gets the generic parameter list of this struct, if it exists.
@@ -4124,7 +4124,7 @@ module Raw {
/**
* Gets the struct field list of this union, if it exists.
*/
RecordFieldList getStructFieldList() { union_struct_field_lists(this, result) }
StructFieldList getStructFieldList() { union_struct_field_lists(this, result) }
/**
* Gets the visibility of this union, if it exists.

View File

@@ -63,18 +63,18 @@ module Generated {
final predicate hasExpr() { exists(this.getExpr()) }
/**
* Gets the name reference of this struct expression field, if it exists.
* Gets the identifier of this struct expression field, if it exists.
*/
NameRef getNameRef() {
NameRef getIdentifier() {
result =
Synth::convertNameRefFromRaw(Synth::convertStructExprFieldToRaw(this)
.(Raw::StructExprField)
.getNameRef())
.getIdentifier())
}
/**
* Holds if `getNameRef()` exists.
* Holds if `getIdentifier()` exists.
*/
final predicate hasNameRef() { exists(this.getNameRef()) }
final predicate hasIdentifier() { exists(this.getIdentifier()) }
}
}

View File

@@ -50,17 +50,19 @@ module Generated {
final int getNumberOfAttrs() { result = count(int i | exists(this.getAttr(i))) }
/**
* Gets the expression of this struct field, if it exists.
* Gets the default of this struct field, if it exists.
*/
Expr getExpr() {
Expr getDefault() {
result =
Synth::convertExprFromRaw(Synth::convertStructFieldToRaw(this).(Raw::StructField).getExpr())
Synth::convertExprFromRaw(Synth::convertStructFieldToRaw(this)
.(Raw::StructField)
.getDefault())
}
/**
* Holds if `getExpr()` exists.
* Holds if `getDefault()` exists.
*/
final predicate hasExpr() { exists(this.getExpr()) }
final predicate hasDefault() { exists(this.getDefault()) }
/**
* Gets the name of this struct field, if it exists.

View File

@@ -1,6 +1,6 @@
// generated by codegen, do not edit
/**
* This module provides the generated definition of `RecordFieldList`.
* This module provides the generated definition of `StructFieldList`.
* INTERNAL: Do not import directly.
*/
@@ -10,7 +10,7 @@ import codeql.rust.elements.internal.FieldListImpl::Impl as FieldListImpl
import codeql.rust.elements.StructField
/**
* INTERNAL: This module contains the fully generated definition of `RecordFieldList` and should not
* INTERNAL: This module contains the fully generated definition of `StructFieldList` and should not
* be referenced directly.
*/
module Generated {
@@ -19,29 +19,29 @@ module Generated {
* ```rust
* todo!()
* ```
* INTERNAL: Do not reference the `Generated::RecordFieldList` class directly.
* Use the subclass `RecordFieldList`, where the following predicates are available.
* INTERNAL: Do not reference the `Generated::StructFieldList` class directly.
* Use the subclass `StructFieldList`, where the following predicates are available.
*/
class RecordFieldList extends Synth::TRecordFieldList, FieldListImpl::FieldList {
override string getAPrimaryQlClass() { result = "RecordFieldList" }
class StructFieldList extends Synth::TStructFieldList, FieldListImpl::FieldList {
override string getAPrimaryQlClass() { result = "StructFieldList" }
/**
* Gets the `index`th field of this record field list (0-based).
* Gets the `index`th field of this struct field list (0-based).
*/
StructField getField(int index) {
result =
Synth::convertStructFieldFromRaw(Synth::convertRecordFieldListToRaw(this)
.(Raw::RecordFieldList)
Synth::convertStructFieldFromRaw(Synth::convertStructFieldListToRaw(this)
.(Raw::StructFieldList)
.getField(index))
}
/**
* Gets any of the fields of this record field list.
* Gets any of the fields of this struct field list.
*/
final StructField getAField() { result = this.getField(_) }
/**
* Gets the number of fields of this record field list.
* Gets the number of fields of this struct field list.
*/
final int getNumberOfFields() { result = count(int i | exists(this.getField(i))) }
}

View File

@@ -48,19 +48,19 @@ module Generated {
final int getNumberOfAttrs() { result = count(int i | exists(this.getAttr(i))) }
/**
* Gets the name reference of this struct pattern field, if it exists.
* Gets the identifier of this struct pattern field, if it exists.
*/
NameRef getNameRef() {
NameRef getIdentifier() {
result =
Synth::convertNameRefFromRaw(Synth::convertStructPatFieldToRaw(this)
.(Raw::StructPatField)
.getNameRef())
.getIdentifier())
}
/**
* Holds if `getNameRef()` exists.
* Holds if `getIdentifier()` exists.
*/
final predicate hasNameRef() { exists(this.getNameRef()) }
final predicate hasIdentifier() { exists(this.getIdentifier()) }
/**
* Gets the pattern of this struct pattern field, if it exists.

View File

@@ -466,10 +466,6 @@ module Synth {
* INTERNAL: Do not use.
*/
TRangePat(Raw::RangePat id) { constructRangePat(id) } or
/**
* INTERNAL: Do not use.
*/
TRecordFieldList(Raw::RecordFieldList id) { constructRecordFieldList(id) } or
/**
* INTERNAL: Do not use.
*/
@@ -546,6 +542,10 @@ module Synth {
* INTERNAL: Do not use.
*/
TStructField(Raw::StructField id) { constructStructField(id) } or
/**
* INTERNAL: Do not use.
*/
TStructFieldList(Raw::StructFieldList id) { constructStructFieldList(id) } or
/**
* INTERNAL: Do not use.
*/
@@ -754,7 +754,7 @@ module Synth {
/**
* INTERNAL: Do not use.
*/
class TFieldList = TRecordFieldList or TTupleFieldList;
class TFieldList = TStructFieldList or TTupleFieldList;
/**
* INTERNAL: Do not use.
@@ -1524,12 +1524,6 @@ module Synth {
*/
TRangePat convertRangePatFromRaw(Raw::Element e) { result = TRangePat(e) }
/**
* INTERNAL: Do not use.
* Converts a raw element to a synthesized `TRecordFieldList`, if possible.
*/
TRecordFieldList convertRecordFieldListFromRaw(Raw::Element e) { result = TRecordFieldList(e) }
/**
* INTERNAL: Do not use.
* Converts a raw element to a synthesized `TRefExpr`, if possible.
@@ -1646,6 +1640,12 @@ module Synth {
*/
TStructField convertStructFieldFromRaw(Raw::Element e) { result = TStructField(e) }
/**
* INTERNAL: Do not use.
* Converts a raw element to a synthesized `TStructFieldList`, if possible.
*/
TStructFieldList convertStructFieldListFromRaw(Raw::Element e) { result = TStructFieldList(e) }
/**
* INTERNAL: Do not use.
* Converts a raw element to a synthesized `TStructPat`, if possible.
@@ -2177,7 +2177,7 @@ module Synth {
* Converts a raw DB element to a synthesized `TFieldList`, if possible.
*/
TFieldList convertFieldListFromRaw(Raw::Element e) {
result = convertRecordFieldListFromRaw(e)
result = convertStructFieldListFromRaw(e)
or
result = convertTupleFieldListFromRaw(e)
}
@@ -3124,12 +3124,6 @@ module Synth {
*/
Raw::Element convertRangePatToRaw(TRangePat e) { e = TRangePat(result) }
/**
* INTERNAL: Do not use.
* Converts a synthesized `TRecordFieldList` to a raw DB element, if possible.
*/
Raw::Element convertRecordFieldListToRaw(TRecordFieldList e) { e = TRecordFieldList(result) }
/**
* INTERNAL: Do not use.
* Converts a synthesized `TRefExpr` to a raw DB element, if possible.
@@ -3246,6 +3240,12 @@ module Synth {
*/
Raw::Element convertStructFieldToRaw(TStructField e) { e = TStructField(result) }
/**
* INTERNAL: Do not use.
* Converts a synthesized `TStructFieldList` to a raw DB element, if possible.
*/
Raw::Element convertStructFieldListToRaw(TStructFieldList e) { e = TStructFieldList(result) }
/**
* INTERNAL: Do not use.
* Converts a synthesized `TStructPat` to a raw DB element, if possible.
@@ -3777,7 +3777,7 @@ module Synth {
* Converts a synthesized `TFieldList` to a raw DB element, if possible.
*/
Raw::Element convertFieldListToRaw(TFieldList e) {
result = convertRecordFieldListToRaw(e)
result = convertStructFieldListToRaw(e)
or
result = convertTupleFieldListToRaw(e)
}

View File

@@ -114,7 +114,6 @@ import codeql.rust.elements.internal.PrefixExprConstructor
import codeql.rust.elements.internal.PtrTypeReprConstructor
import codeql.rust.elements.internal.RangeExprConstructor
import codeql.rust.elements.internal.RangePatConstructor
import codeql.rust.elements.internal.RecordFieldListConstructor
import codeql.rust.elements.internal.RefExprConstructor
import codeql.rust.elements.internal.RefPatConstructor
import codeql.rust.elements.internal.RefTypeReprConstructor
@@ -134,6 +133,7 @@ import codeql.rust.elements.internal.StructExprConstructor
import codeql.rust.elements.internal.StructExprFieldConstructor
import codeql.rust.elements.internal.StructExprFieldListConstructor
import codeql.rust.elements.internal.StructFieldConstructor
import codeql.rust.elements.internal.StructFieldListConstructor
import codeql.rust.elements.internal.StructPatConstructor
import codeql.rust.elements.internal.StructPatFieldConstructor
import codeql.rust.elements.internal.StructPatFieldListConstructor

View File

@@ -10,7 +10,7 @@ import codeql.rust.elements.Attr
import codeql.rust.elements.GenericParamList
import codeql.rust.elements.internal.ItemImpl::Impl as ItemImpl
import codeql.rust.elements.Name
import codeql.rust.elements.RecordFieldList
import codeql.rust.elements.StructFieldList
import codeql.rust.elements.internal.VariantDefImpl::Impl as VariantDefImpl
import codeql.rust.elements.Visibility
import codeql.rust.elements.WhereClause
@@ -78,9 +78,9 @@ module Generated {
/**
* Gets the struct field list of this union, if it exists.
*/
RecordFieldList getStructFieldList() {
StructFieldList getStructFieldList() {
result =
Synth::convertRecordFieldListFromRaw(Synth::convertUnionToRaw(this)
Synth::convertStructFieldListFromRaw(Synth::convertUnionToRaw(this)
.(Raw::Union)
.getStructFieldList())
}

View File

@@ -49,16 +49,17 @@ module Generated {
final int getNumberOfAttrs() { result = count(int i | exists(this.getAttr(i))) }
/**
* Gets the expression of this variant, if it exists.
* Gets the discriminant of this variant, if it exists.
*/
Expr getExpr() {
result = Synth::convertExprFromRaw(Synth::convertVariantToRaw(this).(Raw::Variant).getExpr())
Expr getDiscriminant() {
result =
Synth::convertExprFromRaw(Synth::convertVariantToRaw(this).(Raw::Variant).getDiscriminant())
}
/**
* Holds if `getExpr()` exists.
* Holds if `getDiscriminant()` exists.
*/
final predicate hasExpr() { exists(this.getExpr()) }
final predicate hasDiscriminant() { exists(this.getDiscriminant()) }
/**
* Gets the field list of this variant, if it exists.

View File

@@ -39,7 +39,7 @@ class StreamCipherInit extends Cryptography::CryptographicOperation::Range {
.(PathTypeRepr)
.getPath()
.getSegment()
.getNameRef()
.getIdentifier()
.getText()
) and
algorithmName = simplifyAlgorithmName(rawAlgorithmName)

View File

@@ -9,7 +9,7 @@ final class CloneCallable extends SummarizedCallable::Range {
// NOTE: The function target may not exist in the database, so we base this
// on method calls.
exists(MethodCallExpr c |
c.getNameRef().getText() = "clone" and
c.getIdentifier().getText() = "clone" and
c.getArgList().getNumberOfArgs() = 0 and
this = c.getResolvedCrateOrigin() + "::_::" + c.getResolvedPath()
)

View File

@@ -312,7 +312,7 @@ private class VariantItemNode extends ItemNode instanceof Variant {
override string getName() { result = Variant.super.getName().getText() }
override Namespace getNamespace() {
if super.getFieldList() instanceof RecordFieldList then result.isType() else result.isValue()
if super.getFieldList() instanceof StructFieldList then result.isType() else result.isValue()
}
override TypeParam getTypeParam(int i) {
@@ -471,7 +471,7 @@ private class StructItemNode extends ItemNode instanceof Struct {
override Namespace getNamespace() {
result.isType() // the struct itself
or
not super.getFieldList() instanceof RecordFieldList and
not super.getFieldList() instanceof StructFieldList and
result.isValue() // the constructor
}

View File

@@ -764,7 +764,7 @@ private module FieldExprMatchingInput implements MatchingInputSig {
Type getTypeArgument(TypeArgumentPosition apos, TypePath path) { none() }
AstNode getNodeAt(AccessPosition apos) {
result = this.getExpr() and
result = this.getContainer() and
apos.isSelf()
or
result = this and
@@ -903,7 +903,7 @@ private module Cached {
pragma[nomagic]
private Type getMethodCallExprLookupType(MethodCallExpr mce, string name) {
result = getLookupType(mce.getReceiver()) and
name = mce.getNameRef().getText()
name = mce.getIdentifier().getText()
}
/**
@@ -916,8 +916,8 @@ private module Cached {
pragma[nomagic]
private Type getFieldExprLookupType(FieldExpr fe, string name) {
result = getLookupType(fe.getExpr()) and
name = fe.getNameRef().getText()
result = getLookupType(fe.getContainer()) and
name = fe.getIdentifier().getText()
}
/**

View File

@@ -64,7 +64,7 @@ private class RegexInjectionDefaultBarrier extends RegexInjectionBarrier {
.(PathExpr)
.getPath()
.getSegment()
.getNameRef()
.getIdentifier()
.getText() = "escape"
}
}

View File

@@ -352,9 +352,9 @@ asm_reg_specs(
);
#keyset[id]
asm_reg_spec_name_refs(
asm_reg_spec_identifiers(
int id: @asm_reg_spec ref,
int name_ref: @name_ref ref
int identifier: @name_ref ref
);
@assoc_item =
@@ -481,7 +481,7 @@ extern_item_list_extern_items(
);
@field_list =
@record_field_list
@struct_field_list
| @tuple_field_list
;
@@ -788,9 +788,9 @@ path_segment_generic_arg_lists(
);
#keyset[id]
path_segment_name_refs(
path_segment_identifiers(
int id: @path_segment ref,
int name_ref: @name_ref ref
int identifier: @name_ref ref
);
#keyset[id]
@@ -930,9 +930,9 @@ struct_expr_field_exprs(
);
#keyset[id]
struct_expr_field_name_refs(
struct_expr_field_identifiers(
int id: @struct_expr_field ref,
int name_ref: @name_ref ref
int identifier: @name_ref ref
);
struct_expr_field_lists(
@@ -971,9 +971,9 @@ struct_field_attrs(
);
#keyset[id]
struct_field_exprs(
struct_field_defaults(
int id: @struct_field ref,
int expr: @expr ref
int default: @expr ref
);
#keyset[id]
@@ -1006,9 +1006,9 @@ struct_pat_field_attrs(
);
#keyset[id]
struct_pat_field_name_refs(
struct_pat_field_identifiers(
int id: @struct_pat_field ref,
int name_ref: @name_ref ref
int identifier: @name_ref ref
);
#keyset[id]
@@ -1414,9 +1414,9 @@ assoc_type_arg_generic_arg_lists(
);
#keyset[id]
assoc_type_arg_name_refs(
assoc_type_arg_identifiers(
int id: @assoc_type_arg ref,
int name_ref: @name_ref ref
int identifier: @name_ref ref
);
#keyset[id]
@@ -1747,15 +1747,15 @@ field_expr_attrs(
);
#keyset[id]
field_expr_exprs(
field_expr_containers(
int id: @field_expr ref,
int expr: @expr ref
int container: @expr ref
);
#keyset[id]
field_expr_name_refs(
field_expr_identifiers(
int id: @field_expr ref,
int name_ref: @name_ref ref
int identifier: @name_ref ref
);
fn_ptr_type_reprs(
@@ -2364,17 +2364,6 @@ range_pat_starts(
int start: @pat ref
);
record_field_lists(
unique int id: @record_field_list
);
#keyset[id, index]
record_field_list_fields(
int id: @record_field_list ref,
int index: int ref,
int field: @struct_field ref
);
ref_exprs(
unique int id: @ref_expr
);
@@ -2518,6 +2507,17 @@ slice_type_repr_type_reprs(
int type_repr: @type_repr ref
);
struct_field_lists(
unique int id: @struct_field_list
);
#keyset[id, index]
struct_field_list_fields(
int id: @struct_field_list ref,
int index: int ref,
int field: @struct_field ref
);
try_exprs(
unique int id: @try_expr
);
@@ -2648,9 +2648,9 @@ variant_attrs(
);
#keyset[id]
variant_exprs(
variant_discriminants(
int id: @variant ref,
int expr: @expr ref
int discriminant: @expr ref
);
#keyset[id]
@@ -2892,9 +2892,9 @@ extern_crate_attrs(
);
#keyset[id]
extern_crate_name_refs(
extern_crate_identifiers(
int id: @extern_crate ref,
int name_ref: @name_ref ref
int identifier: @name_ref ref
);
#keyset[id]
@@ -3158,9 +3158,9 @@ method_call_expr_generic_arg_lists(
);
#keyset[id]
method_call_expr_name_refs(
method_call_expr_identifiers(
int id: @method_call_expr ref,
int name_ref: @name_ref ref
int identifier: @name_ref ref
);
#keyset[id]
@@ -3275,7 +3275,7 @@ struct_attrs(
);
#keyset[id]
struct_field_lists(
struct_field_lists_(
int id: @struct ref,
int field_list: @field_list ref
);
@@ -3511,7 +3511,7 @@ union_names(
#keyset[id]
union_struct_field_lists(
int id: @union ref,
int struct_field_list: @record_field_list ref
int struct_field_list: @struct_field_list ref
);
#keyset[id]

View File

@@ -89,7 +89,6 @@ PrefixExpr/gen_prefix_expr.rs c4b53e87f370713b9a9e257be26d082b0761497bac19b1d740
PtrTypeRepr/gen_ptr_type_repr.rs 290d64a8ab4e8946b2e37496e7d2837529135e99b61cfb16a98c00f4d6ff8679 290d64a8ab4e8946b2e37496e7d2837529135e99b61cfb16a98c00f4d6ff8679
RangeExpr/gen_range_expr.rs 3f27cff9cc76b2703beff622d1453b84121e1970a869e45f9428deac92c4ecb0 3f27cff9cc76b2703beff622d1453b84121e1970a869e45f9428deac92c4ecb0
RangePat/gen_range_pat.rs 18b5169c3ab9230c95d86c4897f8343b2176d9602c9ea371c70c1eb0dbf89a28 18b5169c3ab9230c95d86c4897f8343b2176d9602c9ea371c70c1eb0dbf89a28
RecordFieldList/gen_record_field_list.rs f28f14c3d8ff7ae7b5f0bac076165cc7e98a2fdc5377c2a32a0e2e231a6173d9 f28f14c3d8ff7ae7b5f0bac076165cc7e98a2fdc5377c2a32a0e2e231a6173d9
RefExpr/gen_ref_expr.rs 82695467551def4a00c78aa1ea6a1460e9edbef7df2672f13daccb0ee5d6b4c6 82695467551def4a00c78aa1ea6a1460e9edbef7df2672f13daccb0ee5d6b4c6
RefPat/gen_ref_pat.rs aba7518649d9a37928e59a40d42f76cc0f4735e8daf711a3def6d2f0520e1f54 aba7518649d9a37928e59a40d42f76cc0f4735e8daf711a3def6d2f0520e1f54
RefTypeRepr/gen_ref_type_repr.rs 39a79cf148b7ee30e23a12c9349854dbe83aee1790153a388c43ff749907f8ea 39a79cf148b7ee30e23a12c9349854dbe83aee1790153a388c43ff749907f8ea
@@ -109,6 +108,7 @@ StructExpr/gen_struct_expr.rs 8dd9a578625a88623c725b8afdfd8b636e1c3c991fe96c55b2
StructExprField/gen_struct_expr_field.rs 4ccca8e8ad462b4873f5604f0afdd1836027b8d39e36fbe7d6624ef3e744a084 4ccca8e8ad462b4873f5604f0afdd1836027b8d39e36fbe7d6624ef3e744a084
StructExprFieldList/gen_struct_expr_field_list.rs 30a48484dbeca1fd8ead4b7b80f97bd583259e35dce2b590329c86a2d0e152de 30a48484dbeca1fd8ead4b7b80f97bd583259e35dce2b590329c86a2d0e152de
StructField/gen_struct_field.rs 024d30845e244dd535dfb6c30f16de0eec5acd3a257110eeffd260ec82f9edb2 024d30845e244dd535dfb6c30f16de0eec5acd3a257110eeffd260ec82f9edb2
StructFieldList/gen_struct_field_list.rs 9ee6167b3b2edd2ad49f8fe02d6ef67fb1dacf6807014a6a16597d2f40d3bbae 9ee6167b3b2edd2ad49f8fe02d6ef67fb1dacf6807014a6a16597d2f40d3bbae
StructPat/gen_struct_pat.rs 3f972ff8a76acb61ef48bdea92d2fac8b1005449d746e6188fd5486b1f542e5c 3f972ff8a76acb61ef48bdea92d2fac8b1005449d746e6188fd5486b1f542e5c
StructPatField/gen_struct_pat_field.rs dfdab8cef7dcfee40451744c8d2c7c4ae67fdb8bd054b894c08d62997942f364 dfdab8cef7dcfee40451744c8d2c7c4ae67fdb8bd054b894c08d62997942f364
StructPatFieldList/gen_struct_pat_field_list.rs 92490d79c975d25fd0d2e4a830a80abd896c5eb3b30fc54a3b386603ff09d693 92490d79c975d25fd0d2e4a830a80abd896c5eb3b30fc54a3b386603ff09d693

View File

@@ -91,7 +91,6 @@
/PtrTypeRepr/gen_ptr_type_repr.rs linguist-generated
/RangeExpr/gen_range_expr.rs linguist-generated
/RangePat/gen_range_pat.rs linguist-generated
/RecordFieldList/gen_record_field_list.rs linguist-generated
/RefExpr/gen_ref_expr.rs linguist-generated
/RefPat/gen_ref_pat.rs linguist-generated
/RefTypeRepr/gen_ref_type_repr.rs linguist-generated
@@ -111,6 +110,7 @@
/StructExprField/gen_struct_expr_field.rs linguist-generated
/StructExprFieldList/gen_struct_expr_field_list.rs linguist-generated
/StructField/gen_struct_field.rs linguist-generated
/StructFieldList/gen_struct_field_list.rs linguist-generated
/StructPat/gen_struct_pat.rs linguist-generated
/StructPatField/gen_struct_pat_field.rs linguist-generated
/StructPatFieldList/gen_struct_pat_field_list.rs linguist-generated

View File

@@ -1 +0,0 @@
| gen_asm_expr.rs:6:9:6:24 | AsmExpr | gen_asm_expr.rs:6:23:6:23 | _ |

View File

@@ -3,7 +3,7 @@ import codeql.rust.elements
import TestUtils
from
AssocTypeArg x, string hasConstArg, string hasGenericArgList, string hasNameRef,
AssocTypeArg x, string hasConstArg, string hasGenericArgList, string hasIdentifier,
string hasParamList, string hasRetType, string hasReturnTypeSyntax, string hasTypeRepr,
string hasTypeBoundList
where
@@ -11,12 +11,12 @@ where
not x.isUnknown() and
(if x.hasConstArg() then hasConstArg = "yes" else hasConstArg = "no") and
(if x.hasGenericArgList() then hasGenericArgList = "yes" else hasGenericArgList = "no") and
(if x.hasNameRef() then hasNameRef = "yes" else hasNameRef = "no") and
(if x.hasIdentifier() then hasIdentifier = "yes" else hasIdentifier = "no") and
(if x.hasParamList() then hasParamList = "yes" else hasParamList = "no") and
(if x.hasRetType() then hasRetType = "yes" else hasRetType = "no") and
(if x.hasReturnTypeSyntax() then hasReturnTypeSyntax = "yes" else hasReturnTypeSyntax = "no") and
(if x.hasTypeRepr() then hasTypeRepr = "yes" else hasTypeRepr = "no") and
if x.hasTypeBoundList() then hasTypeBoundList = "yes" else hasTypeBoundList = "no"
select x, "hasConstArg:", hasConstArg, "hasGenericArgList:", hasGenericArgList, "hasNameRef:",
hasNameRef, "hasParamList:", hasParamList, "hasRetType:", hasRetType, "hasReturnTypeSyntax:",
select x, "hasConstArg:", hasConstArg, "hasGenericArgList:", hasGenericArgList, "hasIdentifier:",
hasIdentifier, "hasParamList:", hasParamList, "hasRetType:", hasRetType, "hasReturnTypeSyntax:",
hasReturnTypeSyntax, "hasTypeRepr:", hasTypeRepr, "hasTypeBoundList:", hasTypeBoundList

View File

@@ -4,4 +4,4 @@ import TestUtils
from AssocTypeArg x
where toBeTested(x) and not x.isUnknown()
select x, x.getNameRef()
select x, x.getIdentifier()

View File

@@ -1,4 +0,0 @@
| gen_call_expr.rs:5:5:5:11 | foo(...) | gen_call_expr.rs:5:5:5:7 | foo |
| gen_call_expr.rs:6:5:6:23 | foo::<...>(...) | gen_call_expr.rs:6:5:6:19 | foo::<...> |
| gen_call_expr.rs:7:5:7:14 | ...(...) | gen_call_expr.rs:7:5:7:10 | foo[0] |
| gen_call_expr.rs:8:5:8:10 | foo(...) | gen_call_expr.rs:8:5:8:7 | foo |

View File

@@ -4,7 +4,7 @@ import TestUtils
from
ExternCrate x, string hasExtendedCanonicalPath, string hasCrateOrigin, int getNumberOfAttrs,
string hasNameRef, string hasRename, string hasVisibility
string hasIdentifier, string hasRename, string hasVisibility
where
toBeTested(x) and
not x.isUnknown() and
@@ -15,9 +15,9 @@ where
) and
(if x.hasCrateOrigin() then hasCrateOrigin = "yes" else hasCrateOrigin = "no") and
getNumberOfAttrs = x.getNumberOfAttrs() and
(if x.hasNameRef() then hasNameRef = "yes" else hasNameRef = "no") and
(if x.hasIdentifier() then hasIdentifier = "yes" else hasIdentifier = "no") and
(if x.hasRename() then hasRename = "yes" else hasRename = "no") and
if x.hasVisibility() then hasVisibility = "yes" else hasVisibility = "no"
select x, "hasExtendedCanonicalPath:", hasExtendedCanonicalPath, "hasCrateOrigin:", hasCrateOrigin,
"getNumberOfAttrs:", getNumberOfAttrs, "hasNameRef:", hasNameRef, "hasRename:", hasRename,
"getNumberOfAttrs:", getNumberOfAttrs, "hasIdentifier:", hasIdentifier, "hasRename:", hasRename,
"hasVisibility:", hasVisibility

View File

@@ -4,4 +4,4 @@ import TestUtils
from ExternCrate x
where toBeTested(x) and not x.isUnknown()
select x, x.getNameRef()
select x, x.getIdentifier()

View File

@@ -1 +1 @@
| gen_field_expr.rs:5:5:5:9 | x.foo | getNumberOfAttrs: | 0 | hasExpr: | yes | hasNameRef: | yes |
| gen_field_expr.rs:5:5:5:9 | x.foo | getNumberOfAttrs: | 0 | hasContainer: | yes | hasIdentifier: | yes |

View File

@@ -2,11 +2,12 @@
import codeql.rust.elements
import TestUtils
from FieldExpr x, int getNumberOfAttrs, string hasExpr, string hasNameRef
from FieldExpr x, int getNumberOfAttrs, string hasContainer, string hasIdentifier
where
toBeTested(x) and
not x.isUnknown() and
getNumberOfAttrs = x.getNumberOfAttrs() and
(if x.hasExpr() then hasExpr = "yes" else hasExpr = "no") and
if x.hasNameRef() then hasNameRef = "yes" else hasNameRef = "no"
select x, "getNumberOfAttrs:", getNumberOfAttrs, "hasExpr:", hasExpr, "hasNameRef:", hasNameRef
(if x.hasContainer() then hasContainer = "yes" else hasContainer = "no") and
if x.hasIdentifier() then hasIdentifier = "yes" else hasIdentifier = "no"
select x, "getNumberOfAttrs:", getNumberOfAttrs, "hasContainer:", hasContainer, "hasIdentifier:",
hasIdentifier

View File

@@ -4,4 +4,4 @@ import TestUtils
from FieldExpr x
where toBeTested(x) and not x.isUnknown()
select x, x.getExpr()
select x, x.getContainer()

View File

@@ -4,4 +4,4 @@ import TestUtils
from FieldExpr x
where toBeTested(x) and not x.isUnknown()
select x, x.getNameRef()
select x, x.getIdentifier()

View File

@@ -1,5 +0,0 @@
| gen_format_args_expr.rs:9:17:9:28 | FormatArgsExpr | 1 | gen_format_args_expr.rs:9:20:9:20 | x |
| gen_format_args_expr.rs:9:17:9:28 | FormatArgsExpr | 3 | gen_format_args_expr.rs:9:25:9:25 | y |
| gen_format_argument.rs:5:14:5:47 | FormatArgsExpr | 1 | gen_format_argument.rs:5:22:5:26 | value |
| gen_format_argument.rs:5:14:5:47 | FormatArgsExpr | 1 | gen_format_argument.rs:5:29:5:33 | width |
| gen_format_argument.rs:5:14:5:47 | FormatArgsExpr | 1 | gen_format_argument.rs:5:36:5:44 | precision |

View File

@@ -1,13 +0,0 @@
| gen_format.rs:7:21:7:46 | {value:#width$.precision$} | 0 | gen_format.rs:7:22:7:26 | value |
| gen_format.rs:7:21:7:46 | {value:#width$.precision$} | 1 | gen_format.rs:7:29:7:33 | width |
| gen_format.rs:7:21:7:46 | {value:#width$.precision$} | 2 | gen_format.rs:7:36:7:44 | precision |
| gen_format_args_expr.rs:7:19:7:21 | {b} | 0 | gen_format_args_expr.rs:7:20:7:20 | b |
| gen_format_args_expr.rs:7:27:7:31 | {a:?} | 0 | gen_format_args_expr.rs:7:28:7:28 | a |
| gen_format_args_expr.rs:9:19:9:21 | {x} | 0 | gen_format_args_expr.rs:9:20:9:20 | x |
| gen_format_args_expr.rs:9:24:9:26 | {y} | 0 | gen_format_args_expr.rs:9:25:9:25 | y |
| gen_format_argument.rs:5:21:5:46 | {value:#width$.precision$} | 0 | gen_format_argument.rs:5:22:5:26 | value |
| gen_format_argument.rs:5:21:5:46 | {value:#width$.precision$} | 1 | gen_format_argument.rs:5:29:5:33 | width |
| gen_format_argument.rs:5:21:5:46 | {value:#width$.precision$} | 2 | gen_format_argument.rs:5:36:5:44 | precision |
| gen_format_argument.rs:7:21:7:30 | {0:#1$.2$} | 0 | gen_format_argument.rs:7:22:7:22 | 0 |
| gen_format_argument.rs:7:21:7:30 | {0:#1$.2$} | 1 | gen_format_argument.rs:7:25:7:25 | 1 |
| gen_format_argument.rs:7:21:7:30 | {0:#1$.2$} | 2 | gen_format_argument.rs:7:28:7:28 | 2 |

View File

@@ -1 +0,0 @@
| gen_let_expr.rs:5:8:5:31 | let ... = maybe_some | gen_let_expr.rs:5:22:5:31 | maybe_some |

View File

@@ -1,2 +0,0 @@
| gen_match_expr.rs:5:5:8:5 | match x { ... } | gen_match_expr.rs:5:11:5:11 | x |
| gen_match_expr.rs:9:5:12:5 | match x { ... } | gen_match_expr.rs:9:11:9:11 | x |

View File

@@ -1,2 +1,2 @@
| gen_method_call_expr.rs:5:5:5:13 | x.foo(...) | hasArgList: | yes | getNumberOfAttrs: | 0 | hasResolvedPath: | no | hasResolvedCrateOrigin: | no | hasGenericArgList: | no | hasNameRef: | yes | hasReceiver: | yes |
| gen_method_call_expr.rs:6:5:6:25 | x.foo(...) | hasArgList: | yes | getNumberOfAttrs: | 0 | hasResolvedPath: | no | hasResolvedCrateOrigin: | no | hasGenericArgList: | yes | hasNameRef: | yes | hasReceiver: | yes |
| gen_method_call_expr.rs:5:5:5:13 | x.foo(...) | hasArgList: | yes | getNumberOfAttrs: | 0 | hasResolvedPath: | no | hasResolvedCrateOrigin: | no | hasGenericArgList: | no | hasIdentifier: | yes | hasReceiver: | yes |
| gen_method_call_expr.rs:6:5:6:25 | x.foo(...) | hasArgList: | yes | getNumberOfAttrs: | 0 | hasResolvedPath: | no | hasResolvedCrateOrigin: | no | hasGenericArgList: | yes | hasIdentifier: | yes | hasReceiver: | yes |

View File

@@ -4,7 +4,7 @@ import TestUtils
from
MethodCallExpr x, string hasArgList, int getNumberOfAttrs, string hasResolvedPath,
string hasResolvedCrateOrigin, string hasGenericArgList, string hasNameRef, string hasReceiver
string hasResolvedCrateOrigin, string hasGenericArgList, string hasIdentifier, string hasReceiver
where
toBeTested(x) and
not x.isUnknown() and
@@ -17,8 +17,8 @@ where
else hasResolvedCrateOrigin = "no"
) and
(if x.hasGenericArgList() then hasGenericArgList = "yes" else hasGenericArgList = "no") and
(if x.hasNameRef() then hasNameRef = "yes" else hasNameRef = "no") and
(if x.hasIdentifier() then hasIdentifier = "yes" else hasIdentifier = "no") and
if x.hasReceiver() then hasReceiver = "yes" else hasReceiver = "no"
select x, "hasArgList:", hasArgList, "getNumberOfAttrs:", getNumberOfAttrs, "hasResolvedPath:",
hasResolvedPath, "hasResolvedCrateOrigin:", hasResolvedCrateOrigin, "hasGenericArgList:",
hasGenericArgList, "hasNameRef:", hasNameRef, "hasReceiver:", hasReceiver
hasGenericArgList, "hasIdentifier:", hasIdentifier, "hasReceiver:", hasReceiver

View File

@@ -4,4 +4,4 @@ import TestUtils
from MethodCallExpr x
where toBeTested(x) and not x.isUnknown()
select x, x.getNameRef()
select x, x.getIdentifier()

View File

@@ -1,25 +1,25 @@
| gen_path.rs:5:9:5:18 | some_crate | hasGenericArgList: | no | hasNameRef: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path.rs:5:21:5:31 | some_module | hasGenericArgList: | no | hasNameRef: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path.rs:5:34:5:42 | some_item | hasGenericArgList: | no | hasNameRef: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path.rs:6:5:6:7 | foo | hasGenericArgList: | no | hasNameRef: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path.rs:6:10:6:12 | bar | hasGenericArgList: | no | hasNameRef: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_expr.rs:5:13:5:20 | variable | hasGenericArgList: | no | hasNameRef: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_expr.rs:6:13:6:15 | foo | hasGenericArgList: | no | hasNameRef: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_expr.rs:6:18:6:20 | bar | hasGenericArgList: | no | hasNameRef: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_expr.rs:7:13:7:15 | <...> | hasGenericArgList: | no | hasNameRef: | no | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | yes | hasTraitTypeRepr: | no |
| gen_path_expr.rs:7:14:7:14 | T | hasGenericArgList: | no | hasNameRef: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_expr.rs:7:18:7:20 | foo | hasGenericArgList: | no | hasNameRef: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_expr.rs:8:13:8:31 | <...> | hasGenericArgList: | no | hasNameRef: | no | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | yes | hasTraitTypeRepr: | yes |
| gen_path_expr.rs:8:14:8:21 | TypeRepr | hasGenericArgList: | no | hasNameRef: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_expr.rs:8:26:8:30 | Trait | hasGenericArgList: | no | hasNameRef: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_expr.rs:8:34:8:36 | foo | hasGenericArgList: | no | hasNameRef: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_pat.rs:5:11:5:11 | x | hasGenericArgList: | no | hasNameRef: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_pat.rs:6:9:6:11 | Foo | hasGenericArgList: | no | hasNameRef: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_pat.rs:6:14:6:16 | Bar | hasGenericArgList: | no | hasNameRef: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_type_repr.rs:5:14:5:16 | std | hasGenericArgList: | no | hasNameRef: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_type_repr.rs:5:19:5:29 | collections | hasGenericArgList: | no | hasNameRef: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_type_repr.rs:5:32:5:48 | HashMap::<...> | hasGenericArgList: | yes | hasNameRef: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_type_repr.rs:5:40:5:42 | i32 | hasGenericArgList: | no | hasNameRef: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_type_repr.rs:5:45:5:47 | i32 | hasGenericArgList: | no | hasNameRef: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_type_repr.rs:6:14:6:14 | X | hasGenericArgList: | no | hasNameRef: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_type_repr.rs:6:17:6:20 | Item | hasGenericArgList: | no | hasNameRef: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path.rs:5:9:5:18 | some_crate | hasGenericArgList: | no | hasIdentifier: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path.rs:5:21:5:31 | some_module | hasGenericArgList: | no | hasIdentifier: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path.rs:5:34:5:42 | some_item | hasGenericArgList: | no | hasIdentifier: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path.rs:6:5:6:7 | foo | hasGenericArgList: | no | hasIdentifier: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path.rs:6:10:6:12 | bar | hasGenericArgList: | no | hasIdentifier: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_expr.rs:5:13:5:20 | variable | hasGenericArgList: | no | hasIdentifier: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_expr.rs:6:13:6:15 | foo | hasGenericArgList: | no | hasIdentifier: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_expr.rs:6:18:6:20 | bar | hasGenericArgList: | no | hasIdentifier: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_expr.rs:7:13:7:15 | <...> | hasGenericArgList: | no | hasIdentifier: | no | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | yes | hasTraitTypeRepr: | no |
| gen_path_expr.rs:7:14:7:14 | T | hasGenericArgList: | no | hasIdentifier: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_expr.rs:7:18:7:20 | foo | hasGenericArgList: | no | hasIdentifier: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_expr.rs:8:13:8:31 | <...> | hasGenericArgList: | no | hasIdentifier: | no | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | yes | hasTraitTypeRepr: | yes |
| gen_path_expr.rs:8:14:8:21 | TypeRepr | hasGenericArgList: | no | hasIdentifier: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_expr.rs:8:26:8:30 | Trait | hasGenericArgList: | no | hasIdentifier: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_expr.rs:8:34:8:36 | foo | hasGenericArgList: | no | hasIdentifier: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_pat.rs:5:11:5:11 | x | hasGenericArgList: | no | hasIdentifier: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_pat.rs:6:9:6:11 | Foo | hasGenericArgList: | no | hasIdentifier: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_pat.rs:6:14:6:16 | Bar | hasGenericArgList: | no | hasIdentifier: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_type_repr.rs:5:14:5:16 | std | hasGenericArgList: | no | hasIdentifier: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_type_repr.rs:5:19:5:29 | collections | hasGenericArgList: | no | hasIdentifier: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_type_repr.rs:5:32:5:48 | HashMap::<...> | hasGenericArgList: | yes | hasIdentifier: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_type_repr.rs:5:40:5:42 | i32 | hasGenericArgList: | no | hasIdentifier: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_type_repr.rs:5:45:5:47 | i32 | hasGenericArgList: | no | hasIdentifier: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_type_repr.rs:6:14:6:14 | X | hasGenericArgList: | no | hasIdentifier: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |
| gen_path_type_repr.rs:6:17:6:20 | Item | hasGenericArgList: | no | hasIdentifier: | yes | hasParenthesizedArgList: | no | hasRetType: | no | hasReturnTypeSyntax: | no | hasTypeRepr: | no | hasTraitTypeRepr: | no |

View File

@@ -3,13 +3,13 @@ import codeql.rust.elements
import TestUtils
from
PathSegment x, string hasGenericArgList, string hasNameRef, string hasParenthesizedArgList,
PathSegment x, string hasGenericArgList, string hasIdentifier, string hasParenthesizedArgList,
string hasRetType, string hasReturnTypeSyntax, string hasTypeRepr, string hasTraitTypeRepr
where
toBeTested(x) and
not x.isUnknown() and
(if x.hasGenericArgList() then hasGenericArgList = "yes" else hasGenericArgList = "no") and
(if x.hasNameRef() then hasNameRef = "yes" else hasNameRef = "no") and
(if x.hasIdentifier() then hasIdentifier = "yes" else hasIdentifier = "no") and
(
if x.hasParenthesizedArgList()
then hasParenthesizedArgList = "yes"
@@ -19,7 +19,7 @@ where
(if x.hasReturnTypeSyntax() then hasReturnTypeSyntax = "yes" else hasReturnTypeSyntax = "no") and
(if x.hasTypeRepr() then hasTypeRepr = "yes" else hasTypeRepr = "no") and
if x.hasTraitTypeRepr() then hasTraitTypeRepr = "yes" else hasTraitTypeRepr = "no"
select x, "hasGenericArgList:", hasGenericArgList, "hasNameRef:", hasNameRef,
select x, "hasGenericArgList:", hasGenericArgList, "hasIdentifier:", hasIdentifier,
"hasParenthesizedArgList:", hasParenthesizedArgList, "hasRetType:", hasRetType,
"hasReturnTypeSyntax:", hasReturnTypeSyntax, "hasTypeRepr:", hasTypeRepr, "hasTraitTypeRepr:",
hasTraitTypeRepr

View File

@@ -4,4 +4,4 @@ import TestUtils
from PathSegment x
where toBeTested(x) and not x.isUnknown()
select x, x.getNameRef()
select x, x.getIdentifier()

View File

@@ -1,2 +0,0 @@
| gen_path_expr.rs:7:13:7:15 | <...> | gen_path_expr.rs:7:14:7:14 | T |
| gen_path_expr.rs:8:13:8:31 | <...> | gen_path_expr.rs:8:14:8:21 | TypeRepr |

View File

@@ -1,8 +0,0 @@
| gen_path_expr.rs:7:14:7:14 | T | hasPath: | yes |
| gen_path_expr.rs:7:14:7:14 | T | hasPath: | yes |
| gen_path_expr.rs:8:14:8:20 | TypeRepr | hasPath: | yes |
| gen_path_expr.rs:8:14:8:20 | TypeRepr | hasPath: | yes |
| gen_path_type_ref.rs:5:14:5:48 | ...::HashMap::<...> | hasPath: | yes |
| gen_path_type_ref.rs:5:40:5:42 | i32 | hasPath: | yes |
| gen_path_type_ref.rs:5:45:5:47 | i32 | hasPath: | yes |
| gen_path_type_ref.rs:6:14:6:20 | ...::Item | hasPath: | yes |

View File

@@ -1,8 +0,0 @@
| gen_path_expr.rs:7:14:7:14 | T | gen_path_expr.rs:7:14:7:14 | T |
| gen_path_expr.rs:7:14:7:14 | T | gen_path_expr.rs:7:14:7:14 | T |
| gen_path_expr.rs:8:14:8:20 | TypeRepr | gen_path_expr.rs:8:14:8:20 | TypeRepr |
| gen_path_expr.rs:8:14:8:20 | TypeRepr | gen_path_expr.rs:8:14:8:20 | TypeRepr |
| gen_path_type_ref.rs:5:14:5:48 | ...::HashMap::<...> | gen_path_type_ref.rs:5:14:5:48 | ...::HashMap::<...> |
| gen_path_type_ref.rs:5:40:5:42 | i32 | gen_path_type_ref.rs:5:40:5:42 | i32 |
| gen_path_type_ref.rs:5:45:5:47 | i32 | gen_path_type_ref.rs:5:45:5:47 | i32 |
| gen_path_type_ref.rs:6:14:6:20 | ...::Item | gen_path_type_ref.rs:6:14:6:20 | ...::Item |

View File

@@ -1,25 +0,0 @@
| gen_path.rs:5:9:5:18 | some_crate | gen_path.rs:5:9:5:18 | some_crate |
| gen_path.rs:5:9:5:31 | ...::some_module | gen_path.rs:5:21:5:31 | some_module |
| gen_path.rs:5:9:5:42 | ...::some_item | gen_path.rs:5:34:5:42 | some_item |
| gen_path.rs:6:5:6:7 | foo | gen_path.rs:6:5:6:7 | foo |
| gen_path.rs:6:5:6:12 | ...::bar | gen_path.rs:6:10:6:12 | bar |
| gen_path_expr.rs:5:13:5:20 | variable | gen_path_expr.rs:5:13:5:20 | variable |
| gen_path_expr.rs:6:13:6:15 | foo | gen_path_expr.rs:6:13:6:15 | foo |
| gen_path_expr.rs:6:13:6:20 | ...::bar | gen_path_expr.rs:6:18:6:20 | bar |
| gen_path_expr.rs:7:13:7:15 | <...> | gen_path_expr.rs:7:13:7:15 | <...> |
| gen_path_expr.rs:7:13:7:20 | ...::foo | gen_path_expr.rs:7:18:7:20 | foo |
| gen_path_expr.rs:7:14:7:14 | T | gen_path_expr.rs:7:14:7:14 | T |
| gen_path_expr.rs:8:13:8:31 | <...> | gen_path_expr.rs:8:13:8:31 | <...> |
| gen_path_expr.rs:8:13:8:36 | ...::foo | gen_path_expr.rs:8:34:8:36 | foo |
| gen_path_expr.rs:8:14:8:21 | TypeRepr | gen_path_expr.rs:8:14:8:21 | TypeRepr |
| gen_path_expr.rs:8:26:8:30 | Trait | gen_path_expr.rs:8:26:8:30 | Trait |
| gen_path_pat.rs:5:11:5:11 | x | gen_path_pat.rs:5:11:5:11 | x |
| gen_path_pat.rs:6:9:6:11 | Foo | gen_path_pat.rs:6:9:6:11 | Foo |
| gen_path_pat.rs:6:9:6:16 | ...::Bar | gen_path_pat.rs:6:14:6:16 | Bar |
| gen_path_type_repr.rs:5:14:5:16 | std | gen_path_type_repr.rs:5:14:5:16 | std |
| gen_path_type_repr.rs:5:14:5:29 | ...::collections | gen_path_type_repr.rs:5:19:5:29 | collections |
| gen_path_type_repr.rs:5:14:5:48 | ...::HashMap::<...> | gen_path_type_repr.rs:5:32:5:48 | HashMap::<...> |
| gen_path_type_repr.rs:5:40:5:42 | i32 | gen_path_type_repr.rs:5:40:5:42 | i32 |
| gen_path_type_repr.rs:5:45:5:47 | i32 | gen_path_type_repr.rs:5:45:5:47 | i32 |
| gen_path_type_repr.rs:6:14:6:14 | X | gen_path_type_repr.rs:6:14:6:14 | X |
| gen_path_type_repr.rs:6:14:6:20 | ...::Item | gen_path_type_repr.rs:6:17:6:20 | Item |

View File

@@ -1,4 +0,0 @@
| gen_record_expr.rs:5:17:5:34 | Foo {...} | hasResolvedPath: | no | hasResolvedCrateOrigin: | no | hasPath: | yes | hasRecordExprFieldList: | yes |
| gen_record_expr.rs:6:18:6:38 | Foo {...} | hasResolvedPath: | no | hasResolvedCrateOrigin: | no | hasPath: | yes | hasRecordExprFieldList: | yes |
| gen_record_expr.rs:7:5:7:22 | Foo {...} | hasResolvedPath: | no | hasResolvedCrateOrigin: | no | hasPath: | yes | hasRecordExprFieldList: | yes |
| gen_record_expr.rs:8:5:8:14 | Foo {...} | hasResolvedPath: | no | hasResolvedCrateOrigin: | no | hasPath: | yes | hasRecordExprFieldList: | yes |

View File

@@ -1,4 +0,0 @@
| gen_record_expr.rs:5:17:5:34 | Foo {...} | gen_record_expr.rs:5:17:5:19 | Foo |
| gen_record_expr.rs:6:18:6:38 | Foo {...} | gen_record_expr.rs:6:18:6:20 | Foo |
| gen_record_expr.rs:7:5:7:22 | Foo {...} | gen_record_expr.rs:7:5:7:7 | Foo |
| gen_record_expr.rs:8:5:8:14 | Foo {...} | gen_record_expr.rs:8:5:8:7 | Foo |

View File

@@ -1,4 +0,0 @@
| gen_record_expr.rs:5:17:5:34 | Foo {...} | gen_record_expr.rs:5:21:5:34 | RecordExprFieldList |
| gen_record_expr.rs:6:18:6:38 | Foo {...} | gen_record_expr.rs:6:22:6:38 | RecordExprFieldList |
| gen_record_expr.rs:7:5:7:22 | Foo {...} | gen_record_expr.rs:7:9:7:22 | RecordExprFieldList |
| gen_record_expr.rs:8:5:8:14 | Foo {...} | gen_record_expr.rs:8:9:8:14 | RecordExprFieldList |

View File

@@ -1,2 +0,0 @@
| gen_record_expr_field.rs:5:11:5:14 | a: 1 | getNumberOfAttrs: | 0 | hasExpr: | yes | hasNameRef: | yes |
| gen_record_expr_field.rs:5:17:5:20 | b: 2 | getNumberOfAttrs: | 0 | hasExpr: | yes | hasNameRef: | yes |

View File

@@ -1,2 +0,0 @@
| gen_record_expr_field.rs:5:11:5:14 | a: 1 | gen_record_expr_field.rs:5:14:5:14 | 1 |
| gen_record_expr_field.rs:5:17:5:20 | b: 2 | gen_record_expr_field.rs:5:20:5:20 | 2 |

View File

@@ -1,2 +0,0 @@
| gen_record_expr_field.rs:5:11:5:14 | a: 1 | gen_record_expr_field.rs:5:11:5:11 | a |
| gen_record_expr_field.rs:5:17:5:20 | b: 2 | gen_record_expr_field.rs:5:17:5:17 | b |

Some files were not shown because too many files have changed in this diff Show More