summaryrefslogtreecommitdiff
path: root/cont.c
diff options
context:
space:
mode:
Diffstat (limited to 'cont.c')
-rw-r--r--cont.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/cont.c b/cont.c
index c164a3554b..fb0959d1b9 100644
--- a/cont.c
+++ b/cont.c
@@ -1422,6 +1422,21 @@ rb_fiber_s_current(VALUE klass)
return rb_fiber_current();
}
+
+
+/*
+ * Document-class: FiberError
+ *
+ * Raised when an invalid operation is attempted on a Fiber, in
+ * particular when attempting to call/resume a dead fiber,
+ * attempting to yield from the root fiber, or calling a fiber across
+ * threads.
+ *
+ * fiber = Fiber.new{}
+ * fiber.resume #=> nil
+ * fiber.resume #=> FiberError: dead fiber called
+ */
+
void
Init_Cont(void)
{