Skip to content

Commit

Permalink
refactor: rename private mod to __private (#31)
Browse files Browse the repository at this point in the history
  • Loading branch information
m4tx authored Sep 22, 2024
1 parent 7eb06ee commit 5027745
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion flareon-macros/src/form.rs
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ impl FormDeriveBuilder {
let fields_as_from_context = &self.fields_as_from_context;

quote! {
#[#crate_ident::private::async_trait]
#[#crate_ident::__private::async_trait]
#[automatically_derived]
impl #crate_ident::forms::Form for #name {
type Context = #context_struct_name;
Expand Down
4 changes: 3 additions & 1 deletion flareon/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,10 @@ pub mod db;
mod error;
pub mod forms;
mod headers;
// Not public API. Referenced by macro-generated code.
#[doc(hidden)]
pub mod private;
#[path = "private.rs"]
pub mod __private;
pub mod request;
pub mod response;
pub mod router;
Expand Down
2 changes: 2 additions & 0 deletions flareon/src/private.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,6 @@
//!
//! This is to avoid the need to add them as dependencies to the crate that uses
//! the macros.
//!
//! This is not a public API and should not be used directly.
pub use async_trait::async_trait;

0 comments on commit 5027745

Please sign in to comment.