Files
carbon-lang/toolchain/lower/testdata/interop/cpp
Boaz Brickner 2cb0df42e0 Add C++ interop inline function tests (#5406)
This shows that `inline` is ignored and the function definition is not
generated.

Demo:

```c++
// hello_world.h

inline void hello_world() {}
```

```carbon
// main.carbon

library "Main";

import Cpp library "hello_world.h";

fn Run() -> i32 {
  Cpp.hello_world();
  return 0;
}
```

```shell
$ bazel-bin/toolchain/carbon compile main.carbon
$ bazel-bin/toolchain/carbon link main.o --output=demo
ld.lld: error: undefined symbol: hello_world()
>>> referenced by main.carbon:8
>>>               main.o:(main)
error: linker command failed with exit code 1 (use -v to see invocation)
```

Part of #5405.
2025-05-09 16:33:16 +00:00
..