lhames added a comment.

The preferred solution to this is actually to wrap the call with cantFail (See 
http://llvm.org/docs/ProgrammersManual.html#using-cantfail-to-simplify-safe-callsites)
 -- it will handle both the assertion and consumption of the value for you, and 
will simplify calls that return an Expected<T>.


Repository:
  rL LLVM

https://reviews.llvm.org/D36728



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to