From: Skgland Date: Wed, 22 Apr 2026 20:42:35 +0000 (+0200) Subject: fix unused import warning on windows X-Git-Url: https://git.sagredo.dev/?a=commitdiff_plain;h=67659216669cf71a2db54ab80bb4f065c19a2642;p=scryer-prolog.git fix unused import warning on windows --- diff --git a/src/machine/streams.rs b/src/machine/streams.rs index 94a9b34d..9a2d56f4 100644 --- a/src/machine/streams.rs +++ b/src/machine/streams.rs @@ -23,7 +23,7 @@ use std::fmt::Debug; use std::fs::{File, OpenOptions}; use std::hash::Hash; use std::io; -use std::io::{Cursor, ErrorKind, IsTerminal, Read, Seek, SeekFrom, Write}; +use std::io::{Cursor, ErrorKind, Read, Seek, SeekFrom, Write}; use std::mem::ManuallyDrop; use std::net::{Shutdown, TcpStream}; use std::ops::{Deref, DerefMut}; @@ -657,6 +657,8 @@ impl Stream { #[inline] pub fn stdin(arena: &mut Arena, add_history: bool) -> Stream { + #[cfg(unix)] + use std::io::IsTerminal; #[cfg(unix)] if !std::io::stdin().is_terminal() { use std::os::unix::io::{FromRawFd, RawFd};