Clarify that stdout my not be done before exitCode

Closes #31666

Change-Id: If1ba66d72a57a3ca2ce38d9a8101de2f13baa639
Reviewed-on: https://dart-review.googlesource.com/71384
Commit-Queue: Nate Bosch <nbosch@google.com>
Reviewed-by: Lasse R.H. Nielsen <lrn@google.com>
diff --git a/sdk/lib/io/process.dart b/sdk/lib/io/process.dart
index 3c7e1c2..b6c616a 100644
--- a/sdk/lib/io/process.dart
+++ b/sdk/lib/io/process.dart
@@ -288,6 +288,11 @@
    * which will be returned as the negative number `-1073741819`. To
    * get the original 32-bit value use `(0x100000000 + exitCode) &
    * 0xffffffff`.
+   *
+   * There is no guarantee that [stdout] and [stderr] have finished reporting
+   * the buffered output of the process when the returned future completes.
+   * To be sure that all output is captured,
+   * wait for the done event on the streams.
    */
   Future<int> get exitCode;