void RocketServerFrameContext::sendError(RocketException&& rex) { DCHECK(connection_); Serializer writer; ErrorFrame(streamId_, std::move(rex)).serialize(writer); connection_->send(std::move(writer).move()); }
Diagnostics::ArgStream Diagnostics::pushErrorFrame(const SourceRange &Range, ErrorType Error) { Frames.insert(Frames.begin(), ErrorFrame()); ErrorFrame &Last = Frames.front(); Last.Range = Range; Last.Type = Error; ArgStream Out = { &Last.Args }; return Out; }