About
Contact
QtCreator
KDevelop
Solarized
1
use
crate
::
os
::
fd
::{
AsFd
,
AsRawFd
};
2
3
pub
fn
is_terminal
(
fd
: &
impl
AsFd
) ->
bool
{
4
let
fd
: BorrowedFd<'_>
=
fd
.
as_fd
();
5
unsafe
{
libc
::
isatty
(
fd
.
as_raw_fd
()) !=
0
}
6
}
7