link against isl libraries first
[pet.git] / clang_compatibility.h
blobcebdef942fffdd4160be6cdd9f3f431fce9fe234
1 #ifndef PET_CLANG_COMPATIBILITY_H
2 #define PET_CLANG_COMPATIBILITY_H
4 #include "config.h"
6 #ifdef HAVE_BEGIN_END_LOC
7 template <typename T>
8 inline clang::SourceLocation begin_loc(T *decl)
10 return decl->getBeginLoc();
12 template <typename T>
13 inline clang::SourceLocation end_loc(T *decl)
15 return decl->getEndLoc();
17 #else
18 template <typename T>
19 inline clang::SourceLocation begin_loc(T *decl)
21 return decl->getLocStart();
23 template <typename T>
24 inline clang::SourceLocation end_loc(T *decl)
26 return decl->getLocEnd();
28 #endif
30 #endif