cushon / issues-import

0 stars 0 forks source link

PreconditionsTooManyArgs complains about legitimate additional arguments to assertion #259

Closed cushon closed 9 years ago

cushon commented 9 years ago

Original issue created by gintas@google.com on 2014-07-25 at 11:01 AM


The PreconditionsTooManyArgs is overzealous.

The check assumes that the number of slots in the format string must exactly match the number of arguments. However, the check methods actually support more arguments than slots. Snippet of javadoc:

cushon commented 9 years ago

Original comment posted by eaftan@google.com on 2014-08-22 at 05:07 PM


This is a dupe of an internal bug. We ended up changing the docs for Preconditions to discourage this. The intent was never for you to rely on that behavior. We'll send you the internal bug number so you can see the discussion.


Status: WontFix