diff options
| author | nsfisis <nsfisis@gmail.com> | 2026-07-11 16:33:05 +0900 |
|---|---|---|
| committer | nsfisis <nsfisis@gmail.com> | 2026-07-11 16:33:05 +0900 |
| commit | 27d00055df8691a6bd99aaf38633a7338b16cc6a (patch) | |
| tree | 4af17ccff5f8c2d09156fa62c559e60e3e683dac /crates/shirabe/src/util/error_handler.rs | |
| parent | 1ec2220def43e37e5a65b96dde93c19b493258f4 (diff) | |
| download | php-shirabe-27d00055df8691a6bd99aaf38633a7338b16cc6a.tar.gz php-shirabe-27d00055df8691a6bd99aaf38633a7338b16cc6a.tar.zst php-shirabe-27d00055df8691a6bd99aaf38633a7338b16cc6a.zip | |
chore: use fully-qualified name for Rc/RefCell
Diffstat (limited to 'crates/shirabe/src/util/error_handler.rs')
| -rw-r--r-- | crates/shirabe/src/util/error_handler.rs | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/crates/shirabe/src/util/error_handler.rs b/crates/shirabe/src/util/error_handler.rs index 45ad28a8..7a9cf9c2 100644 --- a/crates/shirabe/src/util/error_handler.rs +++ b/crates/shirabe/src/util/error_handler.rs @@ -7,14 +7,13 @@ use shirabe_php_shim::{ STDERR, debug_backtrace, error_reporting, filter_var_boolean, fwrite, ini_get, set_error_handler, }; -use std::cell::{Cell, RefCell}; -use std::rc::Rc; +use std::cell::Cell; // PHP keeps `$io` / `$hasShownDeprecationNotice` as process-global statics. Composer runs // single-threaded, so thread-locals on the main thread reproduce that faithfully while letting // us hold the same shared (`Rc<RefCell<dyn IOInterface>>`) IO instance the application uses. thread_local! { - static IO: RefCell<Option<Rc<RefCell<dyn IOInterface>>>> = const { RefCell::new(None) }; + static IO: std::cell::RefCell<Option<std::rc::Rc<std::cell::RefCell<dyn IOInterface>>>> = const { std::cell::RefCell::new(None) }; static HAS_SHOWN_DEPRECATION_NOTICE: Cell<i64> = const { Cell::new(0) }; } @@ -88,7 +87,7 @@ impl ErrorHandler { Ok(true) } - pub fn register(io: Option<Rc<RefCell<dyn IOInterface>>>) { + pub fn register(io: Option<std::rc::Rc<std::cell::RefCell<dyn IOInterface>>>) { set_error_handler(|level, message, file, line| { Self::handle(level, message.to_string(), file.to_string(), line).unwrap_or(true) }); |
