Skip to content

Commit

Permalink
Fix bug when compiling without js_doc feature
Browse files Browse the repository at this point in the history
  • Loading branch information
oscartbeaumont committed Oct 5, 2023
1 parent 1bbdfe9 commit 21ff50b
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 4 deletions.
4 changes: 3 additions & 1 deletion src/lang/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,9 @@ compile_error!("`js_doc` feature requires `typescript` feature to be enabled");
/// Also requires `typescript` feature to be enabled.
#[cfg(all(feature = "js_doc", feature = "typescript"))]
#[cfg_attr(docsrs, doc(cfg(all(feature = "js_doc", feature = "typescript"))))]
pub mod js_doc;
pub mod js_doc {
pub use super::ts::js_doc::*;
}

// /// [Rust](https://www.rust-lang.org) language exporter.
// #[cfg(feature = "rust")]
Expand Down
2 changes: 1 addition & 1 deletion src/lang/ts/comments.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use crate::js_doc;
use super::js_doc;

use super::{CommentFormatterArgs, CommentFormatterFn};

Expand Down
2 changes: 0 additions & 2 deletions src/lang/js_doc.rs → src/lang/ts/js_doc.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
use std::borrow::Borrow;

use crate::*;

pub use super::ts::*;

pub fn typedef_named_datatype(
Expand Down
1 change: 1 addition & 0 deletions src/lang/ts/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ mod context;
mod error;
mod export_config;
mod formatter;
pub(crate) mod js_doc;
mod reserved_terms;

pub use context::*;
Expand Down

0 comments on commit 21ff50b

Please sign in to comment.