[clang] [clang-repl] Add call to 'InitializeAllAsmParsers' (PR #86727)

Andrew V. Teylu via cfe-commits cfe-commits at lists.llvm.org
Tue Mar 26 13:32:48 PDT 2024


aytey wrote:

> This my first PR against LLVM; does something like this need tests? I'm 100% happy to add tests for this, but are there some examples of "good" `clang-repl` tests I can learn from/extend from?

Maybe this is reasonable:

```cpp
// REQUIRES: host-supports-jit, x86_64-linux
// UNSUPPORTED: system-aix
//
// RUN: rm -rf %t
// RUN: mkdir -p %t
// RUN: split-file %s %t
//
// RUN: cat %t/inline-asm.txt | clang-repl

//--- inline-asm.cpp
__asm(".globl _ZSt21ios_base_library_initv");
int x;

//--- inline-asm.txt
#include "inline-asm.cpp"
x = 10;
%quit
```

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


More information about the cfe-commits mailing list