>From d925137368cdc3c2b30b5be367e17c2f323b794c Mon Sep 17 00:00:00 2001 From: Jyotsna Verma Date: Fri, 19 Apr 2013 09:10:45 -0500 Subject: [PATCH] Use explicit declaration of malloc, free and assert in SemaTemplate/example-dynarray.cpp. Don't include and as they (or the header files included in them) may not be available for all the targets and cause the test to fail. --- test/SemaTemplate/example-dynarray.cpp | 13 ++++++++++--- 1 files changed, 10 insertions(+), 3 deletions(-) diff --git a/test/SemaTemplate/example-dynarray.cpp b/test/SemaTemplate/example-dynarray.cpp index 266d2d4..3310159 100644 --- a/test/SemaTemplate/example-dynarray.cpp +++ b/test/SemaTemplate/example-dynarray.cpp @@ -1,8 +1,15 @@ // RUN: %clangxx -emit-llvm -c -o - %s -// XFAIL: hexagon #include -#include -#include + +extern void free(void *ptr); +extern void *malloc(size_t size); + +extern void __assert_fail (__const char *__assertion, __const char *__file, + unsigned int __line, __const char *__function) + __attribute__ ((__noreturn__)); + +#define assert(expr) \ + ((expr) ? (void)(0) : __assert_fail (#expr, __FILE__, __LINE__, __func__)) // Placement new requires to be included, but we don't support that yet. void* operator new(size_t, void* ptr) throw() { -- 1.7.6.4