xref: /third_party/node/src/node_process-inl.h
  • Home
  • History
  • Annotate Annotate
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
  • only in /third_party/node/src/
11cb0ef41Sopenharmony_ci#ifndef SRC_NODE_PROCESS_INL_H_
21cb0ef41Sopenharmony_ci#define SRC_NODE_PROCESS_INL_H_
31cb0ef41Sopenharmony_ci
41cb0ef41Sopenharmony_ci#if defined(NODE_WANT_INTERNALS) && NODE_WANT_INTERNALS
51cb0ef41Sopenharmony_ci
61cb0ef41Sopenharmony_ci#include "node_process.h"
71cb0ef41Sopenharmony_ci#include "v8.h"
81cb0ef41Sopenharmony_ci#include "debug_utils-inl.h"
91cb0ef41Sopenharmony_ci
101cb0ef41Sopenharmony_cinamespace node {
111cb0ef41Sopenharmony_ci
121cb0ef41Sopenharmony_ci// Call process.emitWarning(str), fmt is a snprintf() format string
131cb0ef41Sopenharmony_citemplate <typename... Args>
141cb0ef41Sopenharmony_ciinline v8::Maybe<bool> ProcessEmitWarning(Environment* env,
151cb0ef41Sopenharmony_ci                                          const char* fmt,
161cb0ef41Sopenharmony_ci                                          Args&&... args) {
171cb0ef41Sopenharmony_ci  std::string warning = SPrintF(fmt, std::forward<Args>(args)...);
181cb0ef41Sopenharmony_ci
191cb0ef41Sopenharmony_ci  return ProcessEmitWarningGeneric(env, warning.c_str());
201cb0ef41Sopenharmony_ci}
211cb0ef41Sopenharmony_ci
221cb0ef41Sopenharmony_ci}  // namespace node
231cb0ef41Sopenharmony_ci
241cb0ef41Sopenharmony_ci#endif  // defined(NODE_WANT_INTERNALS) && NODE_WANT_INTERNALS
251cb0ef41Sopenharmony_ci
261cb0ef41Sopenharmony_ci#endif  // SRC_NODE_PROCESS_INL_H_
27

Indexes created Thu Nov 07 10:32:03 CST 2024