1f4a2713aSLionel Sambuc // RUN: %clang_cc1 %s -triple thumbv7-apple-ios -target-abi aapcs -verify -fsyntax-only 2*0a6a1f1dSLionel Sambuc // RUN: %clang_cc1 %s -triple thumbv7m-apple-macho -target-abi aapcs -verify -fsyntax-only 3f4a2713aSLionel Sambuc // expected-no-diagnostics 4f4a2713aSLionel Sambuc 5f4a2713aSLionel Sambuc // ARM's AAPCS normally has size_t defined as unsigned int, but on Darwin 6f4a2713aSLionel Sambuc // some embedded targets use AAPCS with the iOS header files, which define 7f4a2713aSLionel Sambuc // size_t as unsigned long. Make sure that works. 8f4a2713aSLionel Sambuc typedef unsigned long size_t; 9f4a2713aSLionel Sambuc void* malloc(size_t); operator new(size_t size)10f4a2713aSLionel Sambucvoid* operator new(size_t size) 11f4a2713aSLionel Sambuc { 12f4a2713aSLionel Sambuc return (malloc(size)); 13f4a2713aSLionel Sambuc } 14