[libcxx-commits] [libcxx] [libc++][math] Mathematical Special Functions: Hermite Polynomial (PR #89982)

Mark de Wever via libcxx-commits libcxx-commits at lists.llvm.org
Thu Apr 25 10:01:57 PDT 2024


================
@@ -0,0 +1,45 @@
+// -*- C++ -*-
+//===----------------------------------------------------------------------===//
+//
+// 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_EXPERIMENTAL_MATH
+#define _LIBCPP_EXPERIMENTAL_MATH
+
+#include <experimental/__config>
+
+#if _LIBCPP_STD_VER >= 17
+
+#  include <experimental/__math/hermite.h>
+#  include <type_traits> // enable_if_t, is_integral_v
+
+_LIBCPP_BEGIN_NAMESPACE_EXPERIMENTAL
+
+inline _LIBCPP_HIDE_FROM_ABI double hermite(unsigned __n, double __x) { return __libcpp_hermite(__n, __x); }
----------------
mordante wrote:

All function calls should be qualified. This guards against ADL lookups. (That is not really an issue here, but we like to do it consistently.)
```suggestion
inline _LIBCPP_HIDE_FROM_ABI double hermite(unsigned __n, double __x) { return std::__libcpp_hermite(__n, __x); }
```

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


More information about the libcxx-commits mailing list