@@ -296,46 +296,17 @@ object Decorators {
296296 def derivedCons (x1 : T , xs1 : List [T ]) =
297297 if (xs.head eq x1) && (xs.tail eq xs1) then xs else x1 :: xs1
298298
299- /* This extension defines the following string formatters:
300- * i, e, ex, em, exm
301- * String formatters ending in `m` produce a message, the others produce a string.
302- * Details are as follows:
303- *
304- * i : Gneral purpose string interpolator that uses Formtting.show to print compiler data
305- * e : Like `i`, but with logic that limits the size of messages and that
306- * filters out nonsensical messages after the first error is reported.
307- * `e` or its variants should be used for error messages and warnings instead of `i`.
308- * ex : Like `e`, but it assembles additional info on type variables and for
309- * disambiguating symbols.
310- * em : Like `e`, but producing a message
311- * exm: Like `ex`, but producing a message
312- */
313299 extension (sc : StringContext )
300+
314301 /** General purpose string formatting */
315302 def i (args : Shown * )(using Context ): String =
316303 new StringFormatter (sc).assemble(args)
317304
318- /** Formatting for error messages: Like `i`, with two modifications
319- * - limit size of messages
320- * - mark some parts of messages with <nonsensical> tags, so that
321- * error messages after the first one are filtered out if some of
322- * their arguments are "non-sensical".
305+ /** Interpolator yielding an error message, which undergoes
306+ * the formatting defined in Message.
323307 */
324- def e (args : Shown * )(using Context ): String =
325- new StringFormatter (sc).assemble(args)
326-
327- /** A NoExplanation message formatted with `e` */
328308 def em (args : Shown * )(using Context ): NoExplanation =
329- NoExplanation (e(args* ))
330-
331- def exm (args : Shown * )(using Context ): NoExplanation =
332- NoExplanation (ex(args* ))
333-
334- /** Formatting with added explanations: Like `em`, but add explanations to
335- * give more info about type variables and to disambiguate where needed.
336- */
337- def ex (args : Shown * )(using Context ): String =
338- new StringFormatter (sc).assemble(args)
309+ NoExplanation (i(args* ))
339310
340311 extension [T <: AnyRef ](arr : Array [T ])
341312 def binarySearch (x : T | Null ): Int = java.util.Arrays .binarySearch(arr.asInstanceOf [Array [Object | Null ]], x)
0 commit comments