mirror of
https://github.com/rtic-rs/rtic.git
synced 2024-12-26 11:59:33 +01:00
Fix so deny(missing_docs) work
This commit is contained in:
parent
8e316deae8
commit
6bbcfbec4d
37 changed files with 58 additions and 2 deletions
|
@ -1,6 +1,9 @@
|
|||
//! examples/async-task-multiple-prios.rs
|
||||
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
#![feature(type_alias_impl_trait)]
|
||||
#![deny(missing_docs)]
|
||||
|
||||
use panic_semihosting as _;
|
||||
|
||||
|
|
|
@ -1,6 +1,9 @@
|
|||
//! examples/async-task.rs
|
||||
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
#![feature(type_alias_impl_trait)]
|
||||
#![deny(missing_docs)]
|
||||
|
||||
use panic_semihosting as _;
|
||||
|
||||
|
|
|
@ -6,6 +6,7 @@
|
|||
#![no_main]
|
||||
#![no_std]
|
||||
#![feature(type_alias_impl_trait)]
|
||||
#![deny(missing_docs)]
|
||||
|
||||
use panic_semihosting as _;
|
||||
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
#![deny(warnings)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
#![deny(missing_docs)]
|
||||
|
||||
use panic_semihosting as _;
|
||||
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
#![deny(unsafe_code)]
|
||||
#![deny(warnings)]
|
||||
#![deny(missing_docs)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
#![deny(unsafe_code)]
|
||||
#![deny(warnings)]
|
||||
#![deny(missing_docs)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
#![deny(unsafe_code)]
|
||||
#![deny(warnings)]
|
||||
#![deny(missing_docs)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
#![feature(type_alias_impl_trait)]
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
#![deny(unsafe_code)]
|
||||
#![deny(warnings)]
|
||||
#![deny(missing_docs)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
#![deny(unsafe_code)]
|
||||
#![deny(warnings)]
|
||||
#![deny(missing_docs)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
#![feature(type_alias_impl_trait)]
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
#![deny(unsafe_code)]
|
||||
#![deny(warnings)]
|
||||
#![deny(missing_docs)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
#![deny(unsafe_code)]
|
||||
#![deny(warnings)]
|
||||
#![deny(missing_docs)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
#![deny(unsafe_code)]
|
||||
#![deny(warnings)]
|
||||
#![deny(missing_docs)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
#![deny(unsafe_code)]
|
||||
#![deny(warnings)]
|
||||
#![deny(missing_docs)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
#![deny(unsafe_code)]
|
||||
#![deny(warnings)]
|
||||
#![deny(missing_docs)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
#![feature(type_alias_impl_trait)]
|
||||
#![deny(unsafe_code)]
|
||||
#![deny(missing_docs)]
|
||||
#![deny(warnings)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
#![deny(unsafe_code)]
|
||||
#![deny(warnings)]
|
||||
#![deny(missing_docs)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
#![feature(type_alias_impl_trait)]
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
#![deny(unsafe_code)]
|
||||
#![deny(warnings)]
|
||||
#![deny(missing_docs)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
#![feature(type_alias_impl_trait)]
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
// #![deny(unsafe_code)]
|
||||
#![deny(warnings)]
|
||||
#![deny(missing_docs)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
#![feature(type_alias_impl_trait)]
|
||||
|
@ -9,6 +10,7 @@
|
|||
use core::marker::PhantomData;
|
||||
use panic_semihosting as _;
|
||||
|
||||
/// Not sync
|
||||
pub struct NotSync {
|
||||
_0: PhantomData<*const ()>,
|
||||
data: u32,
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
#![deny(unsafe_code)]
|
||||
#![deny(warnings)]
|
||||
#![deny(missing_docs)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
#![feature(type_alias_impl_trait)]
|
||||
|
|
|
@ -1,5 +1,8 @@
|
|||
//! examples/peripherals-taken.rs
|
||||
|
||||
#![deny(unsafe_code)]
|
||||
#![deny(warnings)]
|
||||
#![deny(missing_docs)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
|
||||
|
|
|
@ -3,6 +3,7 @@
|
|||
#![no_main]
|
||||
#![no_std]
|
||||
#![feature(type_alias_impl_trait)]
|
||||
#![deny(missing_docs)]
|
||||
|
||||
use panic_semihosting as _;
|
||||
use rtic::app;
|
||||
|
|
|
@ -1,9 +1,11 @@
|
|||
//! examples/ramfunc.rs
|
||||
|
||||
#![deny(warnings)]
|
||||
#![deny(missing_docs)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
#![feature(type_alias_impl_trait)]
|
||||
|
||||
use panic_semihosting as _;
|
||||
|
||||
#[rtic::app(
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
#![deny(unsafe_code)]
|
||||
#![deny(warnings)]
|
||||
#![deny(missing_docs)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
#![deny(unsafe_code)]
|
||||
#![deny(warnings)]
|
||||
#![deny(missing_docs)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
#![deny(missing_docs)]
|
||||
|
||||
use panic_semihosting as _; // panic handler
|
||||
use rtic::app;
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
#![deny(unsafe_code)]
|
||||
#![deny(warnings)]
|
||||
#![deny(missing_docs)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
#![feature(type_alias_impl_trait)]
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
#![deny(unsafe_code)]
|
||||
#![deny(warnings)]
|
||||
#![deny(missing_docs)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
#![feature(type_alias_impl_trait)]
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
#![deny(unsafe_code)]
|
||||
#![deny(warnings)]
|
||||
#![deny(missing_docs)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
|
||||
|
|
|
@ -1,7 +1,8 @@
|
|||
//! [compile-pass] check that `#[cfg]` attributes applied on resources work
|
||||
//!
|
||||
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
#![deny(missing_docs)]
|
||||
|
||||
use panic_semihosting as _;
|
||||
|
||||
|
|
|
@ -1,5 +1,8 @@
|
|||
//! examples/h-task-main.rs
|
||||
|
||||
#![deny(unsafe_code)]
|
||||
#![deny(warnings)]
|
||||
#![deny(missing_docs)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
|
||||
|
|
|
@ -1,5 +1,8 @@
|
|||
//! examples/t-idle-main.rs
|
||||
|
||||
#![deny(unsafe_code)]
|
||||
#![deny(warnings)]
|
||||
#![deny(missing_docs)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
|
||||
|
|
|
@ -2,11 +2,12 @@
|
|||
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
#![deny(missing_docs)]
|
||||
|
||||
use core::marker::PhantomData;
|
||||
|
||||
use panic_semihosting as _;
|
||||
|
||||
/// Not send
|
||||
pub struct NotSend {
|
||||
_0: PhantomData<*const ()>,
|
||||
}
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
#![deny(unsafe_code)]
|
||||
#![deny(warnings)]
|
||||
#![deny(missing_docs)]
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
#![feature(type_alias_impl_trait)]
|
||||
|
|
|
@ -1,10 +1,14 @@
|
|||
//! examples/zero-prio-task.rs
|
||||
|
||||
#![no_main]
|
||||
#![no_std]
|
||||
#![feature(type_alias_impl_trait)]
|
||||
#![deny(missing_docs)]
|
||||
|
||||
use core::marker::PhantomData;
|
||||
use panic_semihosting as _;
|
||||
|
||||
/// Does not impl send
|
||||
pub struct NotSend {
|
||||
_0: PhantomData<*const ()>,
|
||||
}
|
||||
|
|
|
@ -50,6 +50,7 @@ pub fn codegen(ctxt: Context, app: &App) -> (TokenStream2, TokenStream2) {
|
|||
|
||||
fields.push(quote!(
|
||||
#(#cfgs)*
|
||||
#[allow(missing_docs)]
|
||||
pub #name: &#lt mut #ty
|
||||
));
|
||||
|
||||
|
@ -88,6 +89,7 @@ pub fn codegen(ctxt: Context, app: &App) -> (TokenStream2, TokenStream2) {
|
|||
let constructor = quote!(
|
||||
impl<'a> #ident<'a> {
|
||||
#[inline(always)]
|
||||
#[allow(missing_docs)]
|
||||
pub unsafe fn new() -> Self {
|
||||
#ident {
|
||||
#(#values,)*
|
||||
|
|
|
@ -114,6 +114,7 @@ pub fn codegen(ctxt: Context, app: &App, analysis: &Analysis) -> TokenStream2 {
|
|||
#(#cfgs)*
|
||||
impl<'a> #internal_context_name<'a> {
|
||||
#[inline(always)]
|
||||
#[allow(missing_docs)]
|
||||
pub unsafe fn new(#core) -> Self {
|
||||
#internal_context_name {
|
||||
__rtic_internal_p: ::core::marker::PhantomData,
|
||||
|
|
|
@ -47,16 +47,19 @@ pub fn codegen(ctxt: Context, app: &App) -> (TokenStream2, TokenStream2) {
|
|||
|
||||
fields.push(quote!(
|
||||
#(#cfgs)*
|
||||
#[allow(missing_docs)]
|
||||
pub #name: &#lt #mut_ #ty
|
||||
));
|
||||
} else if access.is_shared() {
|
||||
fields.push(quote!(
|
||||
#(#cfgs)*
|
||||
#[allow(missing_docs)]
|
||||
pub #name: &'a #ty
|
||||
));
|
||||
} else {
|
||||
fields.push(quote!(
|
||||
#(#cfgs)*
|
||||
#[allow(missing_docs)]
|
||||
pub #name: shared_resources::#shared_name<'a>
|
||||
));
|
||||
|
||||
|
@ -103,6 +106,7 @@ pub fn codegen(ctxt: Context, app: &App) -> (TokenStream2, TokenStream2) {
|
|||
let constructor = quote!(
|
||||
impl<'a> #ident<'a> {
|
||||
#[inline(always)]
|
||||
#[allow(missing_docs)]
|
||||
pub unsafe fn new() -> Self {
|
||||
#ident {
|
||||
#(#values,)*
|
||||
|
|
Loading…
Reference in a new issue