mirror of
https://github.com/danbulant/oxc
synced 2026-05-25 12:51:57 +00:00
refactor(traverse): do not expose TraverseCtx::new (#3226)
Creating a `TraverseCtx` with `TraverseCtx::new` should be an internal API within `oxc_traverse`. Don't expose it outside the crate.
This commit is contained in:
parent
6ac8a8479e
commit
132db7d2a1
1 changed files with 1 additions and 1 deletions
|
|
@ -34,7 +34,7 @@ pub enum FinderRet<T> {
|
||||||
// Public methods
|
// Public methods
|
||||||
impl<'a> TraverseCtx<'a> {
|
impl<'a> TraverseCtx<'a> {
|
||||||
/// Create new traversal context.
|
/// Create new traversal context.
|
||||||
pub fn new(allocator: &'a Allocator) -> Self {
|
pub(crate) fn new(allocator: &'a Allocator) -> Self {
|
||||||
let mut stack = Vec::with_capacity(INITIAL_STACK_CAPACITY);
|
let mut stack = Vec::with_capacity(INITIAL_STACK_CAPACITY);
|
||||||
stack.push(Ancestor::None);
|
stack.push(Ancestor::None);
|
||||||
Self { stack, ast: AstBuilder::new(allocator) }
|
Self { stack, ast: AstBuilder::new(allocator) }
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue