title: Exception order when multiple are possible
body: <p>If a function has 2 arguments and both produce exceptions, what order would you have them raised in and where would you define it?</p>
  
  <p>This came up when I was writing a test for a function that would take a directory on disk and compress it into a file. For instance:</p>
  
  <pre><code>void Compress(string dirPath, string filePath);
  </code></pre>
  
  <p>I haven't written the function yet and I'm putting my tests in place.</p>
  
  <p>The thing is, if the directory path doesn't exist I'd have an exception for a missing directory thrown and if the file had write permissions in the way I'd have an exception thrown to show that. However, what if both paths would cause exceptions? Would I throw the first, the second, another third one, or is it an unknown state? We'd also considered having a single exception to say "Something broke", but the message would be different in each case so doesn't really help.</p>
  
  <p>I've thought of a few ways around it such as always throwing based upon left to right processing of the arguments, or stating "If dirPath is invalid then X is thrown else if filePath is invalid then Y is thrown" and placing that with the interface definition so that whoever implements it should (hopefully) follow this specification.</p>
  
  <p>Just wondering what approach people would take to this problem.</p>
  
  <p>For reference, this is in C# but I don't think this is a language specific problem.</p>