Good News Everyone!
Two-parameter syntax for Fold
and FoldList
has been (silently) implemented!
Taliesin Beynon informs me that this was implemented in 2011, so check your older versions as well.
As Naitree notes this is now documented in 10.0.2:
Fold[f, a]
FoldList[f, a]
f[f[f[1, 2], 3], 4]
{1, f[1, 2], f[f[1, 2], 3], f[f[f[1, 2], 3], 4]}
And the held expression example:
Fold[g, b]
g[g[g[1 + 1, 2 + 2], 3 + 3], 4 + 4]
For full integration (versions 9.0 through 10.0.1) we merely need to update SyntaxInformation
to match the implementation:
Unprotect[Fold, FoldList]
SyntaxInformation[Fold] = {"ArgumentsPattern" -> {_, _, _.}};
SyntaxInformation[FoldList] = {"ArgumentsPattern" -> {_, _., {__}}};
Protect[Fold, FoldList]
(We could also update usage Messages if desired, but not doing so serves as a reminder that the function is undocumented in these versions.)
For older versions you may add the functionality itself with:
Unprotect[Fold, FoldList]
Fold[f_, h_[a_, b__]] := Fold[f, Unevaluated @ a, h @ b]
FoldList[f_, h_[a_, b__]] := FoldList[f, Unevaluated @ a, h @ b]
Protect[Fold, FoldList]
Special thanks to those who made this happen!