diff options
author | Edwin Cheng <[email protected]> | 2021-04-03 05:50:55 +0100 |
---|---|---|
committer | Edwin Cheng <[email protected]> | 2021-04-03 05:50:55 +0100 |
commit | 20d55ce44d4260b6dce220ba64ce81f55299d2ce (patch) | |
tree | 69585b1cd0b39294bb6f08b392957a4037214b1d /crates/mbe/src/syntax_bridge.rs | |
parent | b5804296ddceec7694d4787cec8ede726d64b8d2 (diff) |
Allow include! an empty content file
Diffstat (limited to 'crates/mbe/src/syntax_bridge.rs')
-rw-r--r-- | crates/mbe/src/syntax_bridge.rs | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/crates/mbe/src/syntax_bridge.rs b/crates/mbe/src/syntax_bridge.rs index 9d433b3b0..ae0780072 100644 --- a/crates/mbe/src/syntax_bridge.rs +++ b/crates/mbe/src/syntax_bridge.rs | |||
@@ -325,9 +325,6 @@ trait TokenConvertor { | |||
325 | while self.peek().is_some() { | 325 | while self.peek().is_some() { |
326 | self.collect_leaf(&mut subtree.token_trees); | 326 | self.collect_leaf(&mut subtree.token_trees); |
327 | } | 327 | } |
328 | if subtree.token_trees.is_empty() { | ||
329 | return None; | ||
330 | } | ||
331 | if subtree.token_trees.len() == 1 { | 328 | if subtree.token_trees.len() == 1 { |
332 | if let tt::TokenTree::Subtree(first) = &subtree.token_trees[0] { | 329 | if let tt::TokenTree::Subtree(first) = &subtree.token_trees[0] { |
333 | return Some(first.clone()); | 330 | return Some(first.clone()); |