aboutsummaryrefslogtreecommitdiffstats
path: root/components/devtools/actor.rs
diff options
context:
space:
mode:
Diffstat (limited to 'components/devtools/actor.rs')
-rw-r--r--components/devtools/actor.rs12
1 files changed, 6 insertions, 6 deletions
diff --git a/components/devtools/actor.rs b/components/devtools/actor.rs
index 54b59bc8d79..178b840ebce 100644
--- a/components/devtools/actor.rs
+++ b/components/devtools/actor.rs
@@ -85,7 +85,7 @@ impl ActorRegistry {
}
pub fn register_script_actor(&self, script_id: String, actor: String) {
- println!("registering {:s} ({:s})", actor.as_slice(), script_id.as_slice());
+ println!("registering {} ({})", actor.as_slice(), script_id.as_slice());
let mut script_actors = self.script_actors.borrow_mut();
script_actors.insert(script_id, actor);
}
@@ -103,19 +103,19 @@ impl ActorRegistry {
pub fn actor_to_script(&self, actor: String) -> String {
for (key, value) in self.script_actors.borrow().iter() {
- println!("checking {:s}", value.as_slice());
+ println!("checking {}", value.as_slice());
if value.as_slice() == actor.as_slice() {
return key.to_string();
}
}
- panic!("couldn't find actor named {:s}", actor)
+ panic!("couldn't find actor named {}", actor)
}
/// Create a unique name based on a monotonically increasing suffix
pub fn new_name(&self, prefix: &str) -> String {
let suffix = self.next.get();
self.next.set(suffix + 1);
- format!("{:s}{:u}", prefix, suffix)
+ format!("{}{}", prefix, suffix)
}
/// Add an actor to the registry of known actors that can receive messages.
@@ -154,11 +154,11 @@ impl ActorRegistry {
-> Result<(), ()> {
let to = msg.get(&"to".to_string()).unwrap().as_string().unwrap();
match self.actors.get(&to.to_string()) {
- None => println!("message received for unknown actor \"{:s}\"", to),
+ None => println!("message received for unknown actor \"{}\"", to),
Some(actor) => {
let msg_type = msg.get(&"type".to_string()).unwrap().as_string().unwrap();
if !try!(actor.handle_message(self, &msg_type.to_string(), msg, stream)) {
- println!("unexpected message type \"{:s}\" found for actor \"{:s}\"",
+ println!("unexpected message type \"{}\" found for actor \"{}\"",
msg_type, to);
}
}