Skip to content

Commit

Permalink
Temporarily allow dead code for trivia functions
Browse files Browse the repository at this point in the history
Will probably be using these in future soon, so decided to not feature gate for luau
  • Loading branch information
JohnnyMorganz committed Mar 2, 2022
1 parent 5845127 commit 503eb47
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/formatters/trivia_util.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1032,6 +1032,7 @@ pub fn get_last_stmt_trailing_trivia(last_stmt: LastStmt) -> (LastStmt, Vec<Toke
#[derive(Clone, Copy)]
pub enum CommentSearch {
// Only care about singleline comments
#[allow(dead_code)]
Single,
// Looking for all comments
All,
Expand Down Expand Up @@ -1074,6 +1075,7 @@ pub fn contains_comments(node: impl Node) -> bool {
node.tokens().into_iter().any(token_contains_comments)
}

#[allow(dead_code)]
pub fn contains_singleline_comments(node: impl Node) -> bool {
node.tokens()
.into_iter()
Expand Down

0 comments on commit 503eb47

Please sign in to comment.