[llvm] [clang] [clang][MBD] set up module build daemon infrastructure (PR #67562)

Jan Svoboda via cfe-commits cfe-commits at lists.llvm.org
Thu Jan 4 10:32:29 PST 2024


================
@@ -0,0 +1,48 @@
+//===------------------------------ Utils.h -------------------------------===//
+//
+// 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
+//
+//===----------------------------------------------------------------------===//
+//
+// Functions required by both the frontend and the module build daemon
+//
+//===----------------------------------------------------------------------===//
+
+#ifndef LLVM_CLANG_TOOLING_MODULEBUILDDAEMON_UTILS_H
+#define LLVM_CLANG_TOOLING_MODULEBUILDDAEMON_UTILS_H
+
+#include "llvm/Support/Error.h"
+
+#include <string>
+
+#ifdef _WIN32
+#include <afunix.h>
+#else
+#include <sys/un.h>
+#endif
+
+namespace clang::tooling::cc1modbuildd {
+
+constexpr const std::string_view SOCKET_FILE_NAME = "mbd.sock";
----------------
jansvoboda11 wrote:

You should be able to drop `const` here, since that's implied by `constexpr`.

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


More information about the cfe-commits mailing list