stdInputRange

Dejan Lekic dejan.lekic at gmail.com
Sun Jul 20 10:30:40 UTC 2025


I've tested your code on the source code itself and it works as 
expected:

```
» ./salih2 < salih2.d
import std;

struct StdinByChar
{
   @property bool empty()
   {
     if(isEmpty)
       return true;

     if(!hasChar)
     {
       auto buff = new char[1];
       stdin.rawRead(buff);

       if (buff[0] == 0x7E) // tilde (
Range is empty!

```


More information about the Digitalmars-d-learn mailing list