How to use eventcore write an echo server?
Dejan Lekic
dejan.lekic at gmail.com
Thu Mar 14 18:49:54 UTC 2024
On Tuesday, 12 March 2024 at 05:13:26 UTC, zoujiaqing wrote:
> How to fix it? than you ;)
Try the following:
```
class Connection
{
StreamSocketFD client;
ubyte[1024] buf = void;
// Add these two lines before the constructor:
nothrow:
@safe:
this(StreamSocketFD client)
```
Also you will need to either comment out calls to writeln() or
surround them in try/catch as writeln() may throw so it can't
really be called in nothrow code... For starters just comment all
calls to writeln() out to make it compile, and then move from
there.
More information about the Digitalmars-d-learn
mailing list