Deny unreachable-pub
It's very useful when `pub` is equivalent to "this is crate's public API", let's enforce this! Ideally, we should enforce it for local `cargo test`, and only during CI, but that needs https://github.com/rust-lang/cargo/issues/5034.
This commit is contained in:
@@ -1,8 +1,8 @@
|
||||
//! This file is actually hand-written, but the submodules are indeed generated.
|
||||
#[rustfmt::skip]
|
||||
mod nodes;
|
||||
pub(crate) mod nodes;
|
||||
#[rustfmt::skip]
|
||||
mod tokens;
|
||||
pub(crate) mod tokens;
|
||||
|
||||
use crate::{
|
||||
AstNode,
|
||||
@@ -10,7 +10,7 @@ use crate::{
|
||||
SyntaxNode,
|
||||
};
|
||||
|
||||
pub use {nodes::*, tokens::*};
|
||||
pub(crate) use nodes::*;
|
||||
|
||||
// Stmt is the only nested enum, so it's easier to just hand-write it
|
||||
impl AstNode for Stmt {
|
||||
|
||||
Reference in New Issue
Block a user