kbobyrev added inline comments.
================ Comment at: clang-tools-extra/clangd/benchmarks/IndexBenchmark.cpp:45 + if (!JSONArray) { + llvm::errs() << "Couldn't parse request.\n"; + } ---------------- ilya-biryukov wrote: > kbobyrev wrote: > > ilya-biryukov wrote: > > > Return from function after error? > > I thought that this should panic instead of returning empty `Requests`: > > otherwise it wouldn't be possible to detect problems in the benchmark > > driver in test, for example (it will just run benchmark over empty list of > > requests instead of doing something useful). > Let's "panic" explicitly, e.g. with `exit(1)`. > We're currently triggering undefined behaviour, not something we want to do. Good point; fixed! https://reviews.llvm.org/D51971 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits