rjmccall added inline comments.
================ Comment at: lib/Sema/SemaDecl.cpp:7129 + NewVD->getType().getAddressSpace() != LangAS::opencl_constant) || NewVD->hasExternalStorage()) { if (!T->isSamplerT() && ---------------- Seeing criteria like this, and a lot of the other things you've modified, makes me feel like we should just have a VarDecl::getStorageDuration(). ================ Comment at: lib/Sema/SemaDecl.cpp:10286 + // these variables must be a compile time constant. + VDecl->getType().getAddressSpace() == LangAS::opencl_constant) CheckForConstantInitializer(Init, DclT); ---------------- Should this rule apply even in C++ mode? I can't remember if there are any OpenCL/C++ hybrids. https://reviews.llvm.org/D32977 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits