From: John McCall Date: Thu, 14 Jan 2010 19:12:17 +0000 (+0000) Subject: Document the extensions I made to the diagnostics-formatting system yesterday. X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=3a47e23471ea2edec6464bfe7fd6d54d9a04271f;p=clang Document the extensions I made to the diagnostics-formatting system yesterday. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@93439 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/docs/InternalsManual.html b/docs/InternalsManual.html index f39224f47d..5d75eaa453 100644 --- a/docs/InternalsManual.html +++ b/docs/InternalsManual.html @@ -289,7 +289,7 @@ Clang:

Example:"must be a %select{unary|binary|unary or binary}2 operator" Class:Integers -Description:This format specifier is used to merge multiple +Description:

This format specifier is used to merge multiple related diagnostics together into one common one, without requiring the difference to be specified as an English string argument. Instead of specifying the string, the diagnostic gets an integer argument and the @@ -298,7 +298,8 @@ Clang:

it is 1 it prints 'binary' if it is 2, it prints 'unary or binary'. This allows other language translations to substitute reasonable words (or entire phrases) based on the semantics of the diagnostic instead of having to do - things textually. + things textually.

+

The selected string does undergo formatting.

"plural" format Example:"you have %1 %plural{1:mouse|:mice}1 connected to @@ -330,6 +331,15 @@ Clang:

abort, as will a failure to match the argument against any expression.

+"ordinal" format +Example:"ambiguity in %ordinal0 argument" +Class:Integers +Description:

This is a formatter which represents the + argument number as an ordinal: the value 1 becomes 1st, + 3 becomes 3rd, and so on. Values less than 1 + are not supported.

+

This formatter is currently hard-coded to use English ordinals.

+ "objcclass" format Example:"method %objcclass0 not found" Class:DeclarationName