Skip to content

Commit ee65d4b

Browse files
authored
Merge pull request #74 from rust3ds/version-bump
Edition, dependency and CI update (with fmt)
2 parents bb643c7 + 6354296 commit ee65d4b

File tree

10 files changed

+34
-26
lines changed

10 files changed

+34
-26
lines changed

.github/workflows/ci.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
matrix:
1515
toolchain:
1616
# Run against a "known good" nightly. Rustc version is 1 day behind the toolchain date
17-
- nightly-2024-02-18
17+
- nightly-2025-07-25
1818
# Check for breakage on latest nightly
1919
- nightly
2020

@@ -50,7 +50,7 @@ jobs:
5050
fail-fast: false
5151
matrix:
5252
toolchain:
53-
- nightly-2024-02-18
53+
- nightly-2025-07-25
5454
- nightly
5555
continue-on-error: ${{ matrix.toolchain == 'nightly' }}
5656
runs-on: ubuntu-latest
@@ -80,7 +80,7 @@ jobs:
8080
args: --doc --package citro3d
8181

8282
- name: Upload citra logs and capture videos
83-
uses: actions/upload-artifact@v3
83+
uses: actions/upload-artifact@v4
8484
if: success() || failure() # always run unless the workflow was cancelled
8585
with:
8686
name: citra-logs-${{ matrix.toolchain }}

.github/workflows/docs.yml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ jobs:
2323

2424
- uses: rust3ds/test-runner/setup@v1
2525
with:
26-
toolchain: nightly-2024-02-18
26+
toolchain: nightly-2025-07-25
2727

2828
- name: Build workspace docs
2929
run: cargo 3ds --verbose doc --verbose --no-deps --workspace
@@ -43,7 +43,7 @@ jobs:
4343
run: cp -R ./target/armv6k-nintendo-3ds/doc ./_site/crates
4444

4545
- name: Upload docs
46-
uses: actions/upload-pages-artifact@v2
46+
uses: actions/upload-pages-artifact@v3
4747

4848
deploy:
4949
runs-on: ubuntu-latest
@@ -60,5 +60,4 @@ jobs:
6060
steps:
6161
- name: Deploy to GitHub Pages
6262
id: deployment
63-
uses: actions/deploy-pages@v2
64-
63+
uses: actions/deploy-pages@v4

citro3d-macros/Cargo.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
[package]
22
name = "citro3d-macros"
33
version = "0.1.0"
4-
edition = "2021"
4+
edition = "2024"
55
authors = ["Rust3DS Org"]
66
license = "MIT OR Apache-2.0"
77

88
[lib]
99
proc-macro = true
1010

1111
[dependencies]
12-
litrs = { version = "0.4.0", default-features = false }
13-
quote = "1.0.32"
12+
litrs = { version = "0.5.1", default-features = false }
13+
quote = "1.0.40"

citro3d-macros/src/lib.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,10 @@ fn include_shader_impl(input: TokenStream) -> Result<TokenStream, Box<dyn Error>
7979
let cwd = env::current_dir()
8080
.map_err(|err| format!("unable to determine current directory: {err}"))?;
8181

82-
let invoking_source_file = shader_source_filename.span().source_file().path();
82+
let invoking_source_file = shader_source_filename
83+
.span()
84+
.local_file()
85+
.expect("source file not found");
8386
let Some(invoking_source_dir) = invoking_source_file.parent() else {
8487
return Ok(quote! {
8588
compile_error!(

citro3d-sys/Cargo.toml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,17 +2,17 @@
22
name = "citro3d-sys"
33
version = "0.1.0"
44
authors = ["Rust3DS Org", "panicbit <[email protected]>"]
5-
edition = "2021"
5+
edition = "2024"
66
license = "Zlib"
77
links = "citro3d"
88

99
[dependencies]
10-
libc = "0.2.116"
10+
libc = "0.2.175"
1111
ctru-sys = { git = "https://github.com/rust3ds/ctru-rs.git" }
1212

1313
[build-dependencies]
14-
bindgen = { version = "0.68.1", features = ["experimental"] }
15-
cc = "1.0.83"
14+
bindgen = { version = "0.72", features = ["experimental"] }
15+
cc = "1.0"
1616
doxygen-rs = "0.4.2"
1717

1818
[dev-dependencies]

citro3d-sys/build.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ fn main() {
5858
.header(three_ds_h.to_str().unwrap())
5959
.header(citro3d_h.to_str().unwrap())
6060
.header(tex3ds_h.to_str().unwrap())
61-
.rust_target(RustTarget::Nightly)
61+
.rust_target(RustTarget::nightly())
6262
.use_core()
6363
.trust_clang_mangling(false)
6464
.layout_tests(false)

citro3d/Cargo.toml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,19 +3,19 @@ name = "citro3d"
33
authors = ["Rust3DS Org"]
44
license = "MIT OR Apache-2.0"
55
version = "0.1.0"
6-
edition = "2021"
6+
edition = "2024"
77

88
[dependencies]
9-
glam = { version = "0.24.2", optional = true }
9+
glam = { version = "0.30.5", optional = true }
1010
approx = { version = "0.5.1", optional = true }
11-
bitflags = "1.3.2"
12-
bytemuck = { version = "1.10.0", features = ["extern_crate_std"] }
11+
bitflags = "2.9.1"
12+
bytemuck = { version = "1.23.2", features = ["extern_crate_std"] }
1313
citro3d-macros = { version = "0.1.0", path = "../citro3d-macros" }
1414
citro3d-sys = { git = "https://github.com/rust3ds/citro3d-rs.git" }
1515
ctru-rs = { git = "https://github.com/rust3ds/ctru-rs.git" }
1616
ctru-sys = { git = "https://github.com/rust3ds/ctru-rs.git" }
17-
document-features = "0.2.7"
18-
libc = "0.2.125"
17+
document-features = "0.2.11"
18+
libc = "0.2.175"
1919

2020
[features]
2121
default = ["glam"]

citro3d/src/render.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use std::cell::RefMut;
55
use std::rc::Rc;
66

77
use citro3d_sys::{
8-
C3D_RenderTarget, C3D_RenderTargetCreate, C3D_RenderTargetDelete, C3D_DEPTHTYPE,
8+
C3D_DEPTHTYPE, C3D_RenderTarget, C3D_RenderTargetCreate, C3D_RenderTargetDelete,
99
};
1010
use ctru::services::gfx::Screen;
1111
use ctru::services::gspgpu::FramebufferFormat;

citro3d/src/shader.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,7 @@ impl Library {
175175

176176
/// Get the [`Entrypoint`] at the given index, if present.
177177
#[must_use]
178-
pub fn get(&self, index: usize) -> Option<Entrypoint> {
178+
pub fn get(&self, index: usize) -> Option<Entrypoint<'_>> {
179179
if index < self.len() {
180180
Some(Entrypoint {
181181
ptr: unsafe { (*self.0).DVLE.add(index) },

citro3d/src/uniform.rs

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
use std::ops::Range;
55

66
use crate::math::{FVec4, IVec, Matrix4};
7-
use crate::{shader, Instance};
7+
use crate::{Instance, shader};
88

99
/// The index of a uniform within a [`shader::Program`].
1010
#[derive(Copy, Clone, Debug, PartialEq, Eq, PartialOrd, Ord)]
@@ -82,7 +82,13 @@ impl Uniform {
8282
index,
8383
self.index_range(),
8484
);
85-
assert!(self.index_range().end.0 as usize >= self.len() + index.0 as usize, "tried to bind a uniform that would overflow the uniform buffer. index was {:?}, size was {} max is {:?}", index, self.len(), self.index_range().end);
85+
assert!(
86+
self.index_range().end.0 as usize >= self.len() + index.0 as usize,
87+
"tried to bind a uniform that would overflow the uniform buffer. index was {:?}, size was {} max is {:?}",
88+
index,
89+
self.len(),
90+
self.index_range().end
91+
);
8692
let set_fvs = |fs: &[FVec4]| {
8793
for (off, f) in fs.iter().enumerate() {
8894
unsafe {

0 commit comments

Comments
 (0)