DevTools: Replace camel case variable names (#32726)

* refactor: rename to snake case

* refactor: more renaming

* chore: format

* chore: clean
This commit is contained in:
eri 2024-07-08 13:18:35 +02:00 committed by GitHub
parent b243457ccc
commit 2888193cfe
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
22 changed files with 363 additions and 323 deletions

View file

@ -16,12 +16,14 @@ pub struct PerformanceActor {
}
#[derive(Serialize)]
#[serde(rename_all = "camelCase")]
struct PerformanceFeatures {
withMarkers: bool,
withMemory: bool,
withTicks: bool,
withAllocations: bool,
withJITOptimizations: bool,
with_markers: bool,
with_memory: bool,
with_ticks: bool,
with_allocations: bool,
#[serde(rename = "withJITOptimizations")]
with_jitoptimizations: bool,
}
#[derive(Serialize)]
@ -69,11 +71,11 @@ impl Actor for PerformanceActor {
from: self.name(),
traits: PerformanceTraits {
features: PerformanceFeatures {
withMarkers: true,
withMemory: true,
withTicks: true,
withAllocations: true,
withJITOptimizations: true,
with_markers: true,
with_memory: true,
with_ticks: true,
with_allocations: true,
with_jitoptimizations: true,
},
},
};
@ -104,7 +106,7 @@ impl PerformanceActor {
pub fn description() -> ActorDescription {
ActorDescription {
category: "actor",
typeName: "performance",
type_name: "performance",
methods: vec![Method {
name: "canCurrentlyRecord",
request: Value::Object(