devtools: Standardize variable naming for TargetConfigurationActor#43937
Closed
thebabalola wants to merge 1 commit into
Closed
devtools: Standardize variable naming for TargetConfigurationActor#43937thebabalola wants to merge 1 commit into
thebabalola wants to merge 1 commit into
Conversation
The variable names for the `TargetConfigurationActor` in `watcher.rs` did not follow the naming convention used elsewhere in the devtools crate, where variables holding an actor struct should end in `_actor` and variables holding an actor name string should end in `_name`. The `target_configuration` field on `WatcherActor` holds a name string, so it has been renamed to `target_configuration_name`. The local variable in `WatcherActor::new` holds the actor struct itself, so it has been renamed to `target_configuration_actor`. This makes the relationship between the two explicit at the call site (`target_configuration_name: target_configuration_actor.name()`) and matches the convention followed by the other actors in the same file. Testing: No functional changes; `cargo check -p servo-devtools` passes cleanly. Part of servo#43606 Signed-off-by: thebabalola <t.babalolajoseph@gmail.com>
Member
|
Sorry, the changes in this PR will be superseded by #43915 since that also removes the use of actor variables. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Renames the
target_configurationfield and local variable inwatcher.rsto use the_nameand_actorsuffixes, following the convention already used by other actors in the file (thread_actor,tab_name, etc.).target_configuration: Stringfield →target_configuration_name: Stringlet target_configuration = ...local →let target_configuration_actor = ....name()call, registry insertion, struct literal)Part of #43606.