1
Fork 0
mirror of https://github.com/RGBCube/alejandra synced 2025-08-02 21:47:48 +00:00

refactor: remove unused function

This commit is contained in:
Kevin Amado 2022-02-23 14:48:34 -05:00
parent cd4f66b144
commit fe21dd7821

View file

@ -134,23 +134,7 @@ impl Children {
}) })
} }
pub fn drain_comment<F: FnMut(String)>(&mut self, mut callback: F) { // #[deprecated]
if let Some(child) = self.peek_next() {
if let rnix::SyntaxKind::TOKEN_COMMENT = child.element.kind() {
callback(
child
.element
.as_token()
.as_ref()
.unwrap()
.text()
.to_string(),
);
self.move_next();
}
}
}
pub fn drain_comments<F: FnMut(String)>(&mut self, mut callback: F) { pub fn drain_comments<F: FnMut(String)>(&mut self, mut callback: F) {
while let Some(child) = self.peek_next() { while let Some(child) = self.peek_next() {
match child.element.kind() { match child.element.kind() {