================
@@ -5632,6 +5656,30 @@ struct FormatStyle {
   /// \version 9
   std::vector<std::string> TypenameMacros;
 
+  /// A vector of macros that should be interpreted as try blocks
+  /// instead of as function calls.
+  ///
+  /// These are expected to be macros of the form:
+  /// \code
+  ///   TRY_MACRO(...) {
+  ///     ...
+  ///   } CATCH_MACRO(...) {
+  ///     ...
+  ///   }
+  /// \endcode
+  ///
+  /// The parenthesized arguments are optional for both try and catch macros.
+  ///
+  /// In the .clang-format configuration file, this can be configured like:
+  /// \code{.yaml}
+  ///   TryMacros: [TRY_MACRO]
+  /// \endcode
+  ///
+  /// For example: `KJ_TRY
+  /// 
<https://github.com/capnproto/capnproto/blob/master/kjdoc/tour.md#throwing-and-catching-exceptions>`_
+  /// \version 23
+  std::vector<std::string> TryMacros;
----------------
HazardyKnusperkeks wrote:

`Try` comes before `Type`, please sort accordingly.

https://github.com/llvm/llvm-project/pull/183352
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to