[libcxx-commits] [libcxx] [libc++][z/OS] Move z/OS to new locale API and resolve all name collisions (PR #165428)

Louis Dionne via libcxx-commits libcxx-commits at lists.llvm.org
Tue Oct 28 16:42:32 PDT 2025


================
@@ -0,0 +1,51 @@
+//===-----------------------------------------------------------------------===//
+//
+// 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 _LIBCPP___SUPPORT_IBMVASPRINTF_H
+#define _LIBCPP___SUPPORT_IBMVASPRINTF_H
+
+#include <cstdlib>  // malloc, realloc
+#include <stdarg.h> // va_copy, va_end
+#include <stdio.h>  // vsnprintf
+
+_LIBCPP_BEGIN_NAMESPACE_STD
+namespace __ibm {
+
+inline _LIBCPP_HIDE_FROM_ABI
+_LIBCPP_ATTRIBUTE_FORMAT(__printf__, 2, 0) int vasprintf(char** strp, const char* fmt, va_list ap) {
----------------
ldionne wrote:

This should be a reserved identifier, and so should all the variables and parameter names.

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


More information about the libcxx-commits mailing list