From 6194adf8ea121de428b0dc515ebe46e184a29ab7 Mon Sep 17 00:00:00 2001 From: Michael Thomsen Date: Thu, 9 Feb 2023 14:15:09 +0000 Subject: [PATCH] Cross-link from Exception to Error Change-Id: I6179032ac6cfd1057911e7421843475504974850 CoreLibraryReviewExempt: Documentation only. Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/282024 Reviewed-by: Lasse Nielsen Reviewed-by: Erik Ernst Commit-Queue: Michael Thomsen --- sdk/lib/core/exceptions.dart | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sdk/lib/core/exceptions.dart b/sdk/lib/core/exceptions.dart index f522d27699a..c4c441bc1d8 100644 --- a/sdk/lib/core/exceptions.dart +++ b/sdk/lib/core/exceptions.dart @@ -16,6 +16,9 @@ part of dart.core; /// is discouraged in library code since it doesn't give users a precise /// type they can catch. It may be reasonable to use instances of this /// class in tests or during development. +/// +/// For failures that are not intended to be caught, use [Error] +/// and its subclasses. @pragma('flutter:keep-to-string-in-subtypes') abstract class Exception { factory Exception([var message]) => _Exception(message);