mirror of
https://github.com/github/codeql.git
synced 2025-12-16 16:53:25 +01:00
Cargo: align rust toolchain version with internal repository
Also: * remove new warnings raised by the rust toolchain * run new formatting and linting * update the rust toolchain used by `cargo` While we keep `bazel` builds using the same toolchain as internally (now a nightly one), I opted for using a stable toolchain for `cargo`. The nightly toolchain is only required internally for build reasons, we should keep not using any unstable rust features in our sources.
This commit is contained in:
@@ -23,7 +23,7 @@ fn class_name(type_name: &str) -> String {
|
||||
"AsmOptions" => "AsmOptionsList".to_owned(),
|
||||
"MacroStmts" => "MacroBlockExpr".to_owned(),
|
||||
_ if type_name.starts_with("Record") => type_name.replacen("Record", "Struct", 1),
|
||||
_ if type_name.ends_with("Type") => format!("{}Repr", type_name),
|
||||
_ if type_name.ends_with("Type") => format!("{type_name}Repr"),
|
||||
_ => type_name.to_owned(),
|
||||
}
|
||||
}
|
||||
@@ -171,7 +171,7 @@ fn get_trait_fields(trait_name: &str) -> Vec<FieldInfo> {
|
||||
],
|
||||
"HasArgList" => vec![FieldInfo::optional("arg_list", "ArgList")],
|
||||
"HasDocComments" => vec![],
|
||||
_ => panic!("Unknown trait {}", trait_name),
|
||||
_ => panic!("Unknown trait {trait_name}"),
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user