Changeset [7be6352531a94c7ac4f9a70ce94b597a27bfc19a] by Brian Donovan
Revision 7be6352531a94c7ac4f9a70ce94b597a27bfc19a,
committed by Brian Donovan
· October 21st, 2010 @ 06:54 AM
Add format parameter index support to sprintf.
This is primarily useful in cases when the format string can vary, but the argument order will not, as is often the case with format strings in Localized.strings files.
From http://perldoc.perl.org/functions/sprintf.html:
An explicit format parameter index, such as 2$. By default sprintf will format the next unused argument in the list, but this allows you to take the arguments out of order.
See also this Cocoa example:
http://stackoverflow.com/questions/1063843/is-there-a-way-to-specif...
https://github.com/280north/cappuccino/commit/7be6352531a94c7ac4f9a...
2 changed files
-
M
Objective-J/sprintf.js -
M
Tests/Objective-J/sprintfTest.j