https://bugs.llvm.org/show_bug.cgi?id=38129
Bug ID: 38129
Summary: alloc_size attribute does not work on functions
returning a struct containing a pointer
Product: clang
Version: trunk
Hardware: PC
OS: All
Status: NEW
Severity: enhancement
Priority: P
Component: C++
Assignee: unassignedclangb...@nondot.org
Reporter: gonzalob...@gmail.com
CC: dgre...@apple.com, llvm-bugs@lists.llvm.org
I am trying to implementing P0901r0 [0] in jemalloc. The signature of the new
memory allocation function looks like this:
typedef struct {
void *ptr;
size_t usize;
} smallocx_return_t;
smallocx_return_t je_smallocx(size_t size, int flags);
I have to set the alloc_size attribute for smallocx_return_t.ptr, but AFAICT
this is not currently possible.
[0]: http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2018/p0901r0.html
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs