o:$YARD::CodeObjects::MethodObject:@scope:
instance:@visibility:public:
@pathI"Thread#kill:EF:@parameters[�:@files[[I"
thread.c;T0:@current_file_has_commentsF:
@name:	kill:@source_type:c:
@tags[�:@docstringIC:YARD::Docstring"�Terminates <i>thr</i> and schedules another thread to be run. If this thread
is already marked to be killed, <code>exit</code> returns the
<code>Thread</code>. If this is the main thread, or the last thread, exits
the process.;F:@objectIu:YARD::StubProxyThread#kill;F:
@summary0:@ref_tags[�;[o:YARD::Tags::OverloadTag
:@tag_nameI"
overload;F:
@text0;:	exit:@types0:@signatureI"	exit;F;IC;"�;F;Iu;Thread#kill;F;0;[�;[o:YARD::Tags::Tag
;I"return;F;I"�;F;0;[I"nil;F;0:	@allI"@return [nil];F;[�;Iu;Thread#kill;Fo;
;I"
overload;F;0;;;0;I"	kill;F;IC;"�;F;Iu;Thread#kill;F;0;[�;[o; 
;I"return;F;I"�;F;0;[I"nil;F;0;!I"@return [nil];F;[�;Iu;Thread#kill;Fo;
;I"
overload;F;0;:terminate;0;I"terminate;F;IC;"�;F;Iu;Thread#kill;F;0;[�;[o; 
;I"return;F;I"�;F;0;[I"nil;F;0;!I"@return [nil];F;[�;Iu;Thread#kill;F;!I"FTerminates <i>thr</i> and schedules another thread to be run. If this thread
is already marked to be killed, <code>exit</code> returns the
<code>Thread</code>. If this is the main thread, or the last thread, exits
the process.


@overload exit
  @return [nil]
@overload kill
  @return [nil]
@overload terminate
  @return [nil];F:@namespaceIu;Thread;F:@docstring_extra0:@sourceI"�/*
 *  call-seq:
 *     thr.exit        -> thr or nil
 *     thr.kill        -> thr or nil
 *     thr.terminate   -> thr or nil
 *
 *  Terminates <i>thr</i> and schedules another thread to be run. If this thread
 *  is already marked to be killed, <code>exit</code> returns the
 *  <code>Thread</code>. If this is the main thread, or the last thread, exits
 *  the process.
 */

VALUE
rb_thread_kill(VALUE thread)
{
    rb_thread_t *th;

    GetThreadPtr(thread, th);

    if (th != GET_THREAD() && th->safe_level < 4) {
    rb_secure(4);
    }
    if (th->status == THREAD_TO_KILL || th->status == THREAD_KILLED) {
    return thread;
    }
    if (th == th->vm->main_thread) {
    rb_exit(EXIT_SUCCESS);
    }

    thread_debug("rb_thread_kill: %p (%p)\n", (void *)th, (void *)th->thread_id);

    rb_threadptr_interrupt(th);
    th->thrown_errinfo = eKillSignal;
    th->status = THREAD_TO_KILL;

    return thread;
};F