ruby-changes:59539
From: Jeremy <ko1@a...>
Date: Sat, 28 Dec 2019 08:04:53 +0900 (JST)
Subject: [ruby-changes:59539] f05416c91f (master): Fix coroutine copy implementation on OpenBSD
https://git.ruby-lang.org/ruby.git/commit/?id=f05416c91f From f05416c91f4656db652ad9e63c5aa049dd5c0936 Mon Sep 17 00:00:00 2001 From: Jeremy Evans <code@j...> Date: Fri, 27 Dec 2019 15:01:01 -0800 Subject: Fix coroutine copy implementation on OpenBSD OpenBSD is the only platform that uses this support by default, and it did not work because while OpenBSD supports alloca, it does not include alloca.h. This should be backported to Ruby 2.7. From George Koehler diff --git a/coroutine/copy/Context.h b/coroutine/copy/Context.h index 1319f55..5e5d9e0 100644 --- a/coroutine/copy/Context.h +++ b/coroutine/copy/Context.h @@ -12,7 +12,11 @@ https://github.com/ruby/ruby/blob/trunk/coroutine/copy/Context.h#L12 #include <setjmp.h> #include <string.h> #include <stdlib.h> + +/* OpenBSD supports alloca, but does not include alloca.h */ +#ifndef __OpenBSD__ #include <alloca.h> +#endif #define COROUTINE __attribute__((noreturn)) void -- cgit v0.10.2 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/