[fpc-pascal]Read STIN on FreeBSD
Si.
si at chemicalterrorism.com
Thu Mar 8 20:17:10 CET 2001
so how would one do say echo "hello world" | freepascal-program
Is that possible on FreeBSD ?
Si.
> -----Original Message-----
> From: fpc-pascal-admin at deadlock.et.tudelft.nl
> [mailto:fpc-pascal-admin at deadlock.et.tudelft.nl]On Behalf Of Marco van
> de Voort
> Sent: 08 March 2001 18:59
> To: fpc-pascal at deadlock.et.tudelft.nl
> Subject: Re: [fpc-pascal]Read STIN on FreeBSD
>
>
> > Perhaps I misunderstand the question,
> >
> > but couldn't you use Readln, read, or keypressed/readkey? (if
> you use the
> > CRT unit). Under most systems (and Pascals), stdin is assigned
> to be the
> > default for readln (and likewise stdout for writeln). So, to read in a
> > string from the standard input, you could use:
> >
> > var
> > st:string;
> > begin
> > readln(st);
> > end;
> >
> >
> > If you were looking for a charicter by charicter basis, you could use
> > readkey. If you need more examples, let me know.
>
>
> It is possible to use readkey under FreeBSD, but from the ncrt
> unit, not the
> CRT unit. The Linux Crt unit is very Linux specific, and was not
> portable to
> FreeBSD.
>
>
> _______________________________________________
> fpc-pascal maillist - fpc-pascal at lists.freepascal.org
> http://lists.freepascal.org/mailman/listinfo/fpc-pascal
>
More information about the fpc-pascal
mailing list