From 65f9badbcd825ecb85553b50efc6d974f6be1d6d Mon Sep 17 00:00:00 2001 From: Yuta Saito Date: Sat, 3 Aug 2024 07:51:49 +0000 Subject: [PATCH] [wasm] Add shims for aliased errno constants in WASILibc overlay We provide shims for errno constants in WASILibc overlay since wasi-libc's errno.h defines those constants in a way that cannot be imported by ClangImporter. However, some errno constants are aliased in wasi-libc, and we didn't provided shims for them. This patch adds those missing shims. --- stdlib/public/Platform/WASILibc.swift.gyb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/stdlib/public/Platform/WASILibc.swift.gyb b/stdlib/public/Platform/WASILibc.swift.gyb index f3d5f2486701a..9331e3f6a8420 100644 --- a/stdlib/public/Platform/WASILibc.swift.gyb +++ b/stdlib/public/Platform/WASILibc.swift.gyb @@ -73,6 +73,7 @@ posix_error_codes = [ "EADDRNOTAVAIL", "EAFNOSUPPORT", "EAGAIN", + "EWOULDBLOCK", "EALREADY", "EBADF", "EBADMSG", @@ -125,6 +126,7 @@ posix_error_codes = [ "ENOTRECOVERABLE", "ENOTSOCK", "ENOTSUP", + "EOPNOTSUPP", "ENOTTY", "ENXIO", "EOVERFLOW",