Files
Clang-C/Rewrite.bf
2026-01-29 19:12:36 +01:00

74 lines
2.3 KiB
Beef

// This file was auto-generated by Cpp2Beef
using System;
using System.Interop;
namespace LibClang;
static
{
/*===-- clang-c/Rewrite.h - C CXRewriter --------------------------*- 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 *|
|* *|
|*===----------------------------------------------------------------------===*/
}
public struct CXRewriter : this(void* ptr);
extension Clang
{
/**
* Create CXRewriter.
*/
[Import(Clang.dll)] [LinkName("clang_CXRewriter_create")] public static extern CXRewriter CXRewriter_Create(CXTranslationUnit TU);
/**
* Insert the specified string at the specified location in the original buffer.
*/
[Import(Clang.dll)] [LinkName("clang_CXRewriter_insertTextBefore")] public static extern void CXRewriter_InsertTextBefore(CXRewriter Rew, CXSourceLocation Loc, c_char* Insert);
/**
* Replace the specified range of characters in the input with the specified
* replacement.
*/
[Import(Clang.dll)] [LinkName("clang_CXRewriter_replaceText")] public static extern void CXRewriter_ReplaceText(CXRewriter Rew, CXSourceRange ToBeReplaced, c_char* Replacement);
/**
* Remove the specified range.
*/
[Import(Clang.dll)] [LinkName("clang_CXRewriter_removeText")] public static extern void CXRewriter_RemoveText(CXRewriter Rew, CXSourceRange ToBeRemoved);
/**
* Save all changed files to disk.
* Returns 1 if any files were not saved successfully, returns 0 otherwise.
*/
[Import(Clang.dll)] [LinkName("clang_CXRewriter_overwriteChangedFiles")] public static extern c_int CXRewriter_OverwriteChangedFiles(CXRewriter Rew);
/**
* Write out rewritten version of the main file to stdout.
*/
[Import(Clang.dll)] [LinkName("clang_CXRewriter_writeMainFileToStdOut")] public static extern void CXRewriter_WriteMainFileToStdOut(CXRewriter Rew);
/**
* Free the given CXRewriter.
*/
[Import(Clang.dll)] [LinkName("clang_CXRewriter_dispose")] public static extern void CXRewriter_Dispose(CXRewriter Rew);
}