[clang] [Clang][Sema] Disallow applying `onwership_returns` to functions that return non-pointers (PR #99564)

Aaron Ballman via cfe-commits cfe-commits at lists.llvm.org
Sat Jul 27 08:06:45 PDT 2024


================
@@ -231,6 +231,10 @@ Crash and bug fixes
 Improvements
 ^^^^^^^^^^^^
 
+- Improved the handling of the `ownership_returns` attribute. Now, Clang reports an
+  error if the attribute is attached to a function that returns a non-pointer value.
----------------
AaronBallman wrote:

```suggestion
- Improved the handling of the ``ownership_returns`` attribute. Now, Clang reports an
  error if the attribute is attached to a function that returns a non-pointer value.
```

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


More information about the cfe-commits mailing list