mirror of
https://github.com/github/codeql.git
synced 2025-12-17 17:23:36 +01:00
31 lines
998 B
Plaintext
Generated
31 lines
998 B
Plaintext
Generated
// generated by codegen, do not edit
|
|
import codeql.rust.elements
|
|
import TestUtils
|
|
|
|
query predicate instances(StructField x, string isUnsafe__label, string isUnsafe) {
|
|
toBeTested(x) and
|
|
not x.isUnknown() and
|
|
isUnsafe__label = "isUnsafe:" and
|
|
if x.isUnsafe() then isUnsafe = "yes" else isUnsafe = "no"
|
|
}
|
|
|
|
query predicate getAttr(StructField x, int index, Attr getAttr) {
|
|
toBeTested(x) and not x.isUnknown() and getAttr = x.getAttr(index)
|
|
}
|
|
|
|
query predicate getDefault(StructField x, Expr getDefault) {
|
|
toBeTested(x) and not x.isUnknown() and getDefault = x.getDefault()
|
|
}
|
|
|
|
query predicate getName(StructField x, Name getName) {
|
|
toBeTested(x) and not x.isUnknown() and getName = x.getName()
|
|
}
|
|
|
|
query predicate getTypeRepr(StructField x, TypeRepr getTypeRepr) {
|
|
toBeTested(x) and not x.isUnknown() and getTypeRepr = x.getTypeRepr()
|
|
}
|
|
|
|
query predicate getVisibility(StructField x, Visibility getVisibility) {
|
|
toBeTested(x) and not x.isUnknown() and getVisibility = x.getVisibility()
|
|
}
|