According to my tests it is always left-to-right
>> console.log( console.log(1), console.log(2) );
1
2
undefined undefined
but I can\
It's defined here:
The production
ArgumentList : ArgumentList , AssignmentExpression
is evaluated as follows:
- Let
precedingArgs
be the result of evaluatingArgumentList
.- Let
ref
be the result of evaluatingAssignmentExpression
.- Let
arg
beGetValue(ref)
.- Return a List whose length is one greater than the length of
precedingArgs
and whose items are the items ofprecedingArgs
, in order, followed at the end byarg
which is the last item of the new list.
Read here: http://es5.github.com/#x11.2.4
When a function is invoked, the passed-in arguments are evaluated from left to right.