<div dir="ltr">I am going to move the constructor to private for now, this should eliminate any disagreement about whether to add null checks, as it is now literally impossible to construct one with a null pointer.  For now this doesn't matter since nobody is even using the MemoryBuffer constructor except from internally.  We can re-visit this in the future if we have need for external users to construct one with a MemoryBuffer.</div><br><div class="gmail_quote"><div dir="ltr">On Fri, Feb 24, 2017 at 7:18 AM Zachary Turner <<a href="mailto:zturner@google.com">zturner@google.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I left out unit tests since we'd essentially be duplicating the unit tests of MemoryBuffer, and because it involves the file system (also this is temporary code until DataBuffer stuff goes away).  Lmk if you disagree though <br class="gmail_msg"><div class="gmail_quote gmail_msg"><div dir="ltr" class="gmail_msg">On Fri, Feb 24, 2017 at 2:53 AM Pavel Labath via Phabricator <<a href="mailto:reviews@reviews.llvm.org" class="gmail_msg" target="_blank">reviews@reviews.llvm.org</a>> wrote:<br class="gmail_msg"></div><blockquote class="gmail_quote gmail_msg" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">labath added a comment.<br class="gmail_msg">
<br class="gmail_msg">
I am not sure if this is a voting situation, but I agree with what Zachary said above.<br class="gmail_msg">
<br class="gmail_msg">
Since we're already speaking about tests, it looks like the new DataBufferLLVM class could use a unit test or two, just so we get in the habit of writing those.<br class="gmail_msg">
<br class="gmail_msg">
<br class="gmail_msg">
<a href="https://reviews.llvm.org/D30054" rel="noreferrer" class="gmail_msg" target="_blank">https://reviews.llvm.org/D30054</a><br class="gmail_msg">
<br class="gmail_msg">
<br class="gmail_msg">
<br class="gmail_msg">
</blockquote></div></blockquote></div>