Add an io_limit keyword

This commit is contained in:
Nigel Tao committed 2018-12-09 09:03:21 +11:00
1 parent 3aff5e6f42
commit e992921dce
10 files changed
+159 -32

No files matched your search

+10 -2
View File
@@ -344,8 +344,16 @@ func (h *resumabilityHelper) doExpr1(r resumabilities, n *a.Expr, sef subExprFil
}
func (h *resumabilityHelper) doIOBind(r resumabilities, n *a.IOBind, depth uint32) error {
// Ignore the IOBind fields, as they should be I/O types and therefore not
// resumable.
if n.IO() != nil {
if err := h.doExpr(r, n.IO()); err != nil {
return err
}
}
if n.Limit() != nil {
if err := h.doExpr(r, n.Limit()); err != nil {
return err
}
}
return h.doBlock(r, n.Body(), depth)
}