mirror of
https://github.com/emilk/egui.git
synced 2026-09-02 06:40:06 -04:00
Enable the clippy::std_instead_of_core lint (#8394)
Prefer `core::` over `std::` where either work * Part of https://github.com/emilk/egui/issues/5735
This commit is contained in:
@@ -55,10 +55,10 @@ impl TextureWrapModeExt for egui::TextureWrapMode {
|
||||
#[derive(Debug)]
|
||||
pub struct PainterError(String);
|
||||
|
||||
impl std::error::Error for PainterError {}
|
||||
impl core::error::Error for PainterError {}
|
||||
|
||||
impl std::fmt::Display for PainterError {
|
||||
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
||||
impl core::fmt::Display for PainterError {
|
||||
fn fmt(&self, f: &mut core::fmt::Formatter<'_>) -> core::fmt::Result {
|
||||
write!(f, "OpenGL: {}", self.0)
|
||||
}
|
||||
}
|
||||
@@ -219,7 +219,7 @@ impl Painter {
|
||||
let a_tc_loc = gl.get_attrib_location(program, "a_tc").unwrap();
|
||||
let a_srgba_loc = gl.get_attrib_location(program, "a_srgba").unwrap();
|
||||
|
||||
let stride = std::mem::size_of::<Vertex>() as i32;
|
||||
let stride = core::mem::size_of::<Vertex>() as i32;
|
||||
let buffer_infos = vec![
|
||||
vao::BufferInfo {
|
||||
location: a_pos_loc,
|
||||
|
||||
Reference in New Issue
Block a user