Skip to content

Commit 009ef66

Browse files
cpuctz
authored andcommitted
fix rust 1.94 ambiguous panic macro warnings
``` error: `panic` is ambiguous --> src/./alg_tests.rs:699:26 | 699 | unhandled => panic!("extend der2text for tag 0x{unhandled:x?}"), | ^^^^^ ambiguous name | = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release! = note: for more information, see issue #147319 <rust-lang/rust#147319> = note: ambiguous because of a conflict between a name from a glob import and an outer scope during import or macro resolution ```
1 parent c41360d commit 009ef66

3 files changed

Lines changed: 3 additions & 1 deletion

File tree

src/alg_tests.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414

1515
#![allow(clippy::duplicate_mod)]
1616

17+
use std::panic;
1718
use std::prelude::v1::*;
1819

1920
use base64::{Engine as _, engine::general_purpose};

src/cert.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -395,6 +395,7 @@ mod tests {
395395
use super::*;
396396
#[cfg(feature = "alloc")]
397397
use crate::crl::RevocationReason;
398+
use std::panic;
398399
use std::prelude::v1::*;
399400

400401
#[test]

src/crl/types.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -925,7 +925,7 @@ mod tests {
925925

926926
use pki_types::CertificateDer;
927927
use std::prelude::v1::*;
928-
use std::println;
928+
use std::{panic, println};
929929

930930
use super::*;
931931
use crate::cert::Cert;

0 commit comments

Comments
 (0)