-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Open
Labels
A-Code-BlocksArea: Code blocksArea: Code blocks
Description
This issue originally came up here.
It seems like in some cases, the "Copy to clipboard button" copies incorrect code to the clipboard. For example (from that issue), we get this:
#![allow(unused_variables)]
#![feature(panic_implementation)]
#![feature(core_intrinsics)]
#![no_std]
#![no_main]
fn main() {
use core::intrinsics;
use core::panic::PanicInfo;
#[panic_implementation]
#[no_mangle]
fn panic(_info: &PanicInfo) -> ! {
unsafe { intrinsics::abort() }
}
#[no_mangle]
pub fn _start() -> ! {
loop {}
}
}
where we'd expect this:
#![feature(panic_implementation)]
#![feature(core_intrinsics)]
#![no_std]
#![no_main]
use core::intrinsics;
use core::panic::PanicInfo;
#[panic_implementation]
#[no_mangle]
fn panic(_info: &PanicInfo) -> ! {
unsafe { intrinsics::abort() }
}
#[no_mangle]
pub fn _start() -> ! {
loop {}
}
Edit: I guess it has something to do with a number of span class="hidden"
s being created. What's the motivation behind these?
Metadata
Metadata
Assignees
Labels
A-Code-BlocksArea: Code blocksArea: Code blocks