Skip to content

Commit 4875f4a

Browse files
committed
various updates
1 parent 29faec9 commit 4875f4a

File tree

18 files changed

+11
-33
lines changed

18 files changed

+11
-33
lines changed

Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ error = {git = "https://github.com/mejrs/error", rev = "82c78704fec42b0c35eb65dd
6363
[features]
6464
pyo3 = ["dep:pyo3", "rs3cache_backend/pyo3", "rs3cache_macros"]
6565
mockdata = ["rs3cache_backend/mockdata"]
66+
save_mockdata = []
6667
fast = []
6768
rs3 = ["rs3cache_backend/sqlite", "filetime"]
6869
osrs = ["rs3cache_backend/dat2"]

osrs_py/rust-toolchain.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
[toolchain]
2-
channel = "nightly-2024-03-01"
2+
channel = "nightly-2025-03-01"
33
components = [ "rustfmt", "clippy" ]
44
profile = "minimal"

rs3_py/rust-toolchain.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
[toolchain]
2-
channel = "nightly-2024-03-01"
2+
channel = "nightly-2025-03-01"
33
components = [ "rustfmt", "clippy" ]
44
profile = "minimal"

rs3cache_backend/src/lib.rs

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,7 @@
11
//! Core cache interpreting utilities.
22
3-
#![feature(
4-
lint_reasons,
5-
error_generic_member_access,
6-
error_iter,
7-
cfg_eval,
8-
try_blocks,
9-
array_chunks,
10-
if_let_guard,
11-
let_chains,
12-
error_in_core
13-
)]
14-
#![allow(clippy::result_large_err)]
3+
#![feature(error_generic_member_access, error_iter, cfg_eval, try_blocks, array_chunks, if_let_guard, let_chains)]
4+
#![allow(clippy::result_large_err, unexpected_cfgs)]
155
#![warn(
166
unused_qualifications,
177
unused_import_braces,

rs3cache_backend/src/meta.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -317,8 +317,6 @@ impl IndexMetadata {
317317
)
318318
.collect();
319319

320-
debug_assert!(!buffer.has_remaining());
321-
322320
Ok(Self { metadatas })
323321
}
324322

rs3cache_backend/src/xtea.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
#![cfg(feature = "dat2")]
2-
31
use std::{collections::HashMap, fs::File, io::BufReader, path::Path};
42

53
use ::error::Context;

rs3cache_utils/src/lib.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
//! Miscellanious utilities.
22
#![forbid(unsafe_code)]
3-
#![feature(lint_reasons)]
43
#![warn(
54
unused_crate_dependencies,
65
unused_imports,

rust-toolchain.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
[toolchain]
2-
channel = "nightly-2024-03-01"
2+
channel = "nightly-2025-03-01"
33
components = [ "rustfmt", "clippy" ]
44
profile = "minimal"

rustfmt.toml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,7 @@ trailing_comma = "Vertical"
4343
match_block_trailing_comma = false
4444
blank_lines_upper_bound = 1
4545
blank_lines_lower_bound = 0
46-
edition = "2018"
47-
version = "One"
46+
edition = "2021"
4847
inline_attribute_width = 0
4948
merge_derives = true
5049
use_try_shorthand = false
@@ -55,7 +54,6 @@ color = "Auto"
5554
unstable_features = false
5655
disable_all_formatting = false
5756
skip_children = false
58-
hide_parse_errors = false
5957
error_on_line_overflow = false
6058
error_on_unformatted = false
6159
ignore = []

src/definitions/mapsquares/legacy.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,6 @@ impl Iterator for MapSquareIterator {
5252
impl ExactSizeIterator for MapSquareIterator {}
5353

5454
/// Iterates over [`GroupMapSquare`] in arbitrary order.
55-
5655
pub struct GroupMapSquareIterator {
5756
inner: CacheIndex<index::Initial>,
5857
range_i: RangeInclusive<i32>,

src/definitions/mapsquares/osrs.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,6 @@ impl Iterator for MapSquareIterator {
9595
impl ExactSizeIterator for MapSquareIterator {}
9696

9797
/// Iterates over [`GroupMapSquare`] in arbitrary order.
98-
9998
pub struct GroupMapSquareIterator {
10099
inner: CacheIndex<index::Initial>,
101100
range_i: RangeInclusive<i32>,

src/definitions/mapsquares/rs3.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,6 @@ impl Iterator for MapSquareIterator {
4646
impl ExactSizeIterator for MapSquareIterator {}
4747

4848
/// Iterates over [`GroupMapSquare`] in arbitrary order.
49-
5049
pub struct GroupMapSquareIterator {
5150
index: CacheIndex<index::Initial>,
5251
range_i: RangeInclusive<i32>,

src/definitions/sprites.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,6 @@ pub fn get_mapscenes(scale: u32, config: &crate::cli::Config) -> CacheResult<BTr
200200
/// # Panics
201201
///
202202
/// **Panics** if `scale == 0`.
203-
204203
pub fn dumps(scale: u32, ids: Vec<u32>, config: &crate::cli::Config) -> CacheResult<BTreeMap<(u32, u32), Sprite>> {
205204
assert_ne!(scale, 0);
206205

src/definitions/textures.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
#![cfg(feature = "osrs")]
2-
31
use std::{
42
collections::HashMap,
53
fs::{self, File},

src/ffi/python/mapsquares.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ impl PyMapSquare {
165165
})
166166
.context(error::Integrity)?
167167
} else {
168-
locations.ok_or(rs3cache_backend::error::CacheError::Xtea { i: self.i(), j: self.j() })?
168+
locations.ok_or(error::CacheError::Xtea { i: self.i(), j: self.j() })?
169169
};
170170

171171
#[cfg(feature = "legacy")]

src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#![doc = include_str!("../README.md")]
2-
#![feature(cfg_eval, doc_cfg, doc_auto_cfg, option_get_or_insert_default, lazy_cell, try_blocks, yeet_expr)]
2+
#![feature(cfg_eval, doc_cfg, doc_auto_cfg, try_blocks, yeet_expr)]
33
#![allow(clippy::too_many_arguments, clippy::type_complexity)]
44
#![warn(
55
unused_qualifications,

src/renderers/map.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -306,7 +306,7 @@ pub fn save_smallest(config: &Config, name: &str, i: u8, j: u8, imgs: [Img; 4])
306306
#[doc(hidden)]
307307
#[cfg(feature = "rs3")]
308308
pub fn render_bench() -> CacheResult<()> {
309-
let config = crate::cli::Config::default();
309+
let config = Config::default();
310310
let path = "test_data/tiles";
311311
fs::create_dir_all(path).unwrap();
312312
let coordinates: Vec<(u8, u8)> = iproduct!(45..55, 45..55).collect();

src/renderers/map/base.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ pub fn put(
102102
120 => (6, 4, 4),
103103
121 | 122 => (87, 70, 62),
104104
125 | 126 => (50, 44, 36),
105-
unknown => unimplemented!("unimplemented texture id {}", unknown),
105+
unknown => (78, 95, 129), // unimplemented!("unimplemented texture id {}", unknown),
106106
};
107107
let fill = Rgba([red, green, blue, 255]);
108108

0 commit comments

Comments
 (0)