35 lines · c
1//===-- ResourceScriptCppFilter.h ------------------------------*- C++ -*-===//2//3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.4// See https://llvm.org/LICENSE.txt for license information.5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception6//7//===---------------------------------------------------------------------===//8//9// This filters the input to llvm-rc for preprocessor markers, removing10// preprocessing directives that a preprocessor can output or leave behind.11//12// It also filters out any contribution from files named *.h or *.c, based13// on preprocessor line markers. When preprocessing RC files, the included14// headers can leave behind C declarations, that RC doesn't understand.15// Rc.exe simply discards anything that comes from files named *.h or *.h.16//17// https://msdn.microsoft.com/en-us/library/windows/desktop/aa381033(v=vs.85).aspx18//19//===---------------------------------------------------------------------===//20 21#ifndef LLVM_TOOLS_LLVMRC_RESOURCESCRIPTCPPFILTER_H22#define LLVM_TOOLS_LLVMRC_RESOURCESCRIPTCPPFILTER_H23 24#include "llvm/ADT/StringRef.h"25 26#include <string>27 28namespace llvm {29 30std::string filterCppOutput(StringRef Input);31 32} // namespace llvm33 34#endif35