From d5634164cb86771fc279468cbb93e311c1ad3089 Mon Sep 17 00:00:00 2001 From: Divy Srivastava Date: Sat, 14 Jan 2023 20:18:58 -0800 Subject: chore: use rustfmt imports_granularity option (#17421) Closes https://github.com/denoland/deno/issues/2699 Closes https://github.com/denoland/deno/issues/2347 Uses unstable rustfmt features. Since dprint invokes `rustfmt` we do not need to switch the cargo toolchain to nightly. Do we care about formatting stability of our codebase across Rust versions? (I don't) --- test_napi/src/async.rs | 3 ++- test_napi/src/object_wrap.rs | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) (limited to 'test_napi/src') diff --git a/test_napi/src/async.rs b/test_napi/src/async.rs index 0df4990ab..51e6edac9 100644 --- a/test_napi/src/async.rs +++ b/test_napi/src/async.rs @@ -6,7 +6,8 @@ use crate::napi_new_property; use napi_sys::Status::napi_ok; use napi_sys::ValueType::napi_function; use napi_sys::*; -use std::os::raw::{c_char, c_void}; +use std::os::raw::c_char; +use std::os::raw::c_void; use std::ptr; pub struct Baton { diff --git a/test_napi/src/object_wrap.rs b/test_napi/src/object_wrap.rs index 493cb05b3..5a6e36589 100644 --- a/test_napi/src/object_wrap.rs +++ b/test_napi/src/object_wrap.rs @@ -5,7 +5,8 @@ use crate::napi_get_callback_info; use crate::napi_new_property; use napi_sys::ValueType::napi_number; use napi_sys::*; -use std::os::raw::{c_char, c_void}; +use std::os::raw::c_char; +use std::os::raw::c_void; use std::ptr; pub struct NapiObject { -- cgit v1.2.3