Skip to content

Commit 44030da

Browse files
Cargo format
Signed-off-by: Dusan Malusev <[email protected]>
1 parent f104e43 commit 44030da

File tree

1 file changed

+4
-7
lines changed

1 file changed

+4
-7
lines changed

hosts-edit/src/commands/remove.rs

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,8 @@ pub(crate) fn execute(
66
reader: &mut impl Read,
77
writer: &mut impl Write,
88
host: String,
9-
) -> Result<(), Box<dyn std::error::Error>>
10-
{
11-
let tokens = Tokenizer::new_with_reader(reader)
12-
.parse()?
13-
.get_tokens();
9+
) -> Result<(), Box<dyn std::error::Error>> {
10+
let tokens = Tokenizer::new_with_reader(reader).parse()?.get_tokens();
1411

1512
let mut parser = Parser::builder()
1613
.visitor(Visitor::new(host.as_str()))
@@ -50,7 +47,7 @@ impl<'a> Visitor<'a> {
5047
}
5148

5249
#[inline(always)]
53-
pub /*const*/ fn get_start(&self) -> Option<usize> {
50+
pub fn get_start(&self) -> Option<usize> {
5451
if self.hosts_on_line > 1 {
5552
self.host_to_remove_pos.or(Some(self.start))
5653
} else {
@@ -59,7 +56,7 @@ impl<'a> Visitor<'a> {
5956
}
6057

6158
#[inline(always)]
62-
pub /*const*/ fn get_end(&self) -> Option<usize> {
59+
pub fn get_end(&self) -> Option<usize> {
6360
if self.hosts_on_line > 1 {
6461
self.host_to_remove_pos.or(Some(self.end))
6562
} else {

0 commit comments

Comments
 (0)