rsmith added a comment. Please add serialisation code for the push count for PCH. Should it be an error if the count is nonzero at the end of the TU?
What happens if there are trailing tokens after the pragma? ================ Comment at: clang/include/clang/Basic/DiagnosticParseKinds.td:1027 @@ +1026,3 @@ +def warn_pragma_force_cuda_host_device_bad_arg : Warning< + "Incorrect use of #pragma clang force_cuda_host_device begin|end">; + ---------------- Diagnostics should start with a lowercase letter. ================ Comment at: clang/test/Parser/cuda-force-host-device-templates.cu:8 @@ +7,3 @@ +template <typename T> +T foo() { // expected-note {{declared here}} + return T(); ---------------- You need this to return `auto` to trigger the eager instantiation codepath I was concerned about. https://reviews.llvm.org/D24975 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits