gofractally / psibase

Open source protocol enabling communities to easily self-host web applications
https://docs.psibase.io
MIT License
28 stars 7 forks source link

`ToSchema` derive disrupts `#[allow(non_snake_case)]` #781

Open James-Mart opened 4 months ago

James-Mart commented 4 months ago

Not high priority, but some of our services will have extra warnings:

image

image

swatanabe commented 4 months ago

I can't reproduce this.

Both of the following compile without warnings:

#[derive(ToSchema)]
#[fracpack(fracpack_mod = "fracpack")]
#[allow(non_snake_case)]
pub struct Foo {
    pub Bar: i8,
}
#[allow(non_snake_case)]
mod service {
    #[derive(ToSchema)]
    #[fracpack(fracpack_mod = "fracpack")]
    pub struct Foo {
        pub Bar: i8,
    }
}