aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAyose <ayosec@gmail.com>2025-07-23 00:00:00 +0000
committerAyose <ayosec@gmail.com>2025-07-23 00:00:00 +0000
commit4f83bcb58e5e5e260da4785069fa6e322fc06136 (patch)
treee89678ef565560367369b2603e9b3187c064e908
parenta247c96e9f59ee73908ace776dde3812557c8b83 (diff)
downloadr-alacritty-4f83bcb58e5e5e260da4785069fa6e322fc06136.tar.gz
r-alacritty-4f83bcb58e5e5e260da4785069fa6e322fc06136.tar.bz2
r-alacritty-4f83bcb58e5e5e260da4785069fa6e322fc06136.zip
Remove memoffset crate.
Since Rust 1.77, `offset_of` is available in the std.
-rw-r--r--Cargo.lock10
-rw-r--r--alacritty/Cargo.toml1
-rw-r--r--alacritty/src/renderer/graphics/shader.rs4
3 files changed, 2 insertions, 13 deletions
diff --git a/Cargo.lock b/Cargo.lock
index 1b38fb1d..d0534cc3 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -50,7 +50,6 @@ dependencies = [
"home",
"libc",
"log",
- "memoffset",
"notify",
"objc2 0.6.1",
"objc2-app-kit 0.3.1",
@@ -1058,15 +1057,6 @@ dependencies = [
]
[[package]]
-name = "memoffset"
-version = "0.9.0"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "5a634b1c61a95585bd15607c6ab0c4e5b226e695ff2800ba0cdccddf208c406c"
-dependencies = [
- "autocfg",
-]
-
-[[package]]
name = "miniz_oxide"
version = "0.8.9"
source = "registry+https://github.com/rust-lang/crates.io-index"
diff --git a/alacritty/Cargo.toml b/alacritty/Cargo.toml
index 59bbad8b..852d3a7a 100644
--- a/alacritty/Cargo.toml
+++ b/alacritty/Cargo.toml
@@ -32,7 +32,6 @@ glutin = { version = "0.32.2", default-features = false, features = ["egl", "wgl
home = "0.5.5"
libc = "0.2"
log = { version = "0.4", features = ["std", "serde"] }
-memoffset = "0.9.0"
notify = "8.0.0"
parking_lot = "0.12.0"
serde_json = "1"
diff --git a/alacritty/src/renderer/graphics/shader.rs b/alacritty/src/renderer/graphics/shader.rs
index 650af0a5..d203f8be 100644
--- a/alacritty/src/renderer/graphics/shader.rs
+++ b/alacritty/src/renderer/graphics/shader.rs
@@ -149,7 +149,7 @@ fn define_vertex_attributes(shader_version: ShaderVersion) -> (GLuint, GLuint) {
1,
gl::$type,
mem::size_of::<Vertex>() as i32,
- memoffset::offset_of!(Vertex, $field) as *const _,
+ mem::offset_of!(Vertex, $field) as *const _,
);
attr_index += 1;
@@ -164,7 +164,7 @@ fn define_vertex_attributes(shader_version: ShaderVersion) -> (GLuint, GLuint) {
gl::$type,
gl::FALSE,
mem::size_of::<Vertex>() as i32,
- memoffset::offset_of!(Vertex, $field) as *const _,
+ mem::offset_of!(Vertex, $field) as *const _,
);
attr_index += 1;