Description
http://doc.trolltech.com/4.7/qscriptvalue.html#lessThan
The first problem with this function is that it says it implements the algorithm in section 11.8.5 of the ES spec; however, that comparison can produce either a bool or undefined, whereas QScriptValue::lessThan() returns bool.
The other issue is: What's the use case? For comparing numbers, QScriptValue::toNumber() and the C++ < operator can be used instead.
General-purpose sorting can be done with Array.prototype.sort in JS.
For the record, neither JavaScriptCore nor V8 expose a C/C++ API for this type of comparison; only for equality (equals / strictly equals).