Changeset 973b92a in git for external/fastjet/internal
- Timestamp:
- Oct 9, 2015, 2:47:38 PM (9 years ago)
- Branches:
- ImprovedOutputFile, Timing, dual_readout, llp, master
- Children:
- 8713dee
- Parents:
- f118021
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
external/fastjet/internal/DnnPlane.hh
rf118021 r973b92a 1 1 //FJSTARTHEADER 2 // $Id: DnnPlane.hh 3 442 2014-07-24 07:20:49Z salam $2 // $Id: DnnPlane.hh 3918 2015-07-03 14:19:13Z salam $ 3 3 // 4 4 // Copyright (c) 2005-2014, Matteo Cacciari, Gavin P. Salam and Gregory Soyez … … 190 190 // no crash... that's done by checking (near != NULL) 191 191 if ((std::abs(dist-mindist)<DISTANCE_FOR_CGAL_CHECKS) && 192 (near != NULL) &&192 _is_not_null(near) && // GPS cf. note below about != NULL with clang/CGAL 193 193 (_euclid_distance(candidate, near->point())<DISTANCE_FOR_CGAL_CHECKS)){ 194 194 // we're in a situation where there might be a rounding issue, … … 222 222 /// then use CGAL to compare the distances. 223 223 static const double DISTANCE_FOR_CGAL_CHECKS; 224 225 226 /// small routine to check if if a vertex handle is not null. 227 /// 228 /// This is centralised here because of the need for a not-very 229 /// readable workaround for certain CGAL/clang++ compiler 230 /// combinations. 231 inline static bool _is_not_null(const Vertex_handle & vh) { 232 // as found in issue 2015-07-clang61+CGAL, the form 233 // vh != NULL 234 // appears to be broken with CGAL-3.6 and clang-3.6.0/.1 235 // 236 // The not very "readable" 237 // vh.operator->() 238 // does the job instead 239 return vh.operator->(); 240 } 224 241 225 242 }; … … 237 254 inline bool DnnPlane::Valid(const int index) const { 238 255 if (index >= 0 && index < static_cast<int>(_supervertex.size())) { 239 return (_supervertex[index].vertex != NULL);} else {return false;} } 256 return _is_not_null(_supervertex[index].vertex); 257 } 258 else { 259 return false; 260 } 261 } 262 240 263 241 264 inline EtaPhi DnnPlane::etaphi(const int i) const {
Note:
See TracChangeset
for help on using the changeset viewer.