1void *alloc(unsigned long)__attribute__((alloc_size(1)));
2
3_Bool sta(void)
4{
5	void *ptr = alloc(4);
6	return __builtin_object_size(ptr, 0) == 4;
7}
8
9_Bool dyn(unsigned long n)
10{
11	void *ptr = alloc(n);
12	return __builtin_object_size(ptr, 0) == n;
13}
14
15/*
16 * check-name: builtin-objsize-dyn
17 * check-command: test-linearize -Wno-decl $file
18 * check-known-to-fail
19 *
20 * check-output-ignore
21 * check-output-returns: 1
22 */
23