[libc-commits] [libc] [libc][stdio] Add fopen_s and bootstrap annex k. (PR #152248)

Muhammad Bassiouni via libc-commits libc-commits at lists.llvm.org
Fri Aug 8 10:27:22 PDT 2025


================
@@ -0,0 +1,21 @@
+//===-- Definition of type constraint_handler_t ---------------------------===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
+//
+//===----------------------------------------------------------------------===//
+
+#ifndef LLVM_LIBC_INCLUDE_LLVM_LIBC_TYPES_CONSTRAINT_HANDLER_T_H
+#define LLVM_LIBC_INCLUDE_LLVM_LIBC_TYPES_CONSTRAINT_HANDLER_T_H
+
+#include "errno_t.h"
+
+#ifdef LIBC_HAS_ANNEX_K
+
+typedef void (*constraint_handler_t)(const char *__restrict msg,
+                                     void *__restrict ptr, errno_t error);
----------------
bassiounix wrote:

since it's a typedef, I can actually remove the name of args. But this will lead in confusion as "where to put what"?

https://github.com/llvm/llvm-project/pull/152248


More information about the libc-commits mailing list