Add missing core::panic::PanicInfo imports in code snippets (#440)

This commit is contained in:
Philipp Oppermann
2018-06-14 08:24:37 +02:00
committed by GitHub
parent 34f5733114
commit 3372966664
3 changed files with 8 additions and 0 deletions

View File

@@ -200,6 +200,8 @@ To tell the Rust compiler that we don't want to use the normal entry point chain
#![no_std]
#![no_main]
use core::panic::PanicInfo;
/// This function is called on panic.
#[panic_implementation]
#[no_mangle]
@@ -313,6 +315,8 @@ A minimal freestanding Rust binary looks like this:
#![no_std] // don't link the Rust standard library
#![no_main] // disable all Rust-level entry points
use core::panic::PanicInfo;
/// This function is called on panic.
#[panic_implementation]
#[no_mangle]