Skip to content

Commit

Permalink
visitor: Add debug log for FmtVisitor::visit_stmt()
Browse files Browse the repository at this point in the history
  • Loading branch information
kamalmarhubi committed May 30, 2016
1 parent 7f0d87c commit 80c56a0
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/visitor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,10 @@ pub struct FmtVisitor<'a> {

impl<'a> FmtVisitor<'a> {
fn visit_stmt(&mut self, stmt: &ast::Stmt) {
debug!("visit_stmt: {:?} {:?}",
self.codemap.lookup_char_pos(stmt.span.lo),
self.codemap.lookup_char_pos(stmt.span.hi));

match stmt.node {
ast::StmtKind::Decl(ref decl, _) => {
if let ast::DeclKind::Item(ref item) = decl.node {
Expand Down

0 comments on commit 80c56a0

Please sign in to comment.