Use a ReturnedValue when converting to String or Object

Also rename Value::toQString() to Value::toQStringNoThrow(),
and add a throwing toQString() method for JS use.

Change-Id: I821b33fc61abb7d08839df965fd337685f61a545
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Use QV4::ReturnedValue in the runtime API

This makes function calls from the JIT/Moth into the
runtime significantly nicer.

Change-Id: Ie7d7123984d65c0bee0525d3d28c643a76b394c4
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Use ReturnedValue for some more runtime methods

Change-Id: I68c7d321f8d17b32110ee050aa48fae5735e63ad
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Remove unused code to generate post increment and decrement expressions

We generate lower level code in codegen and don't use these
runtime methods anymore.

Change-Id: If1023ce5295431305f4528839bcf2a3031fa7ad2
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Use ReturnedValue for more runtime methods

Change-Id: I6e92dccf4c3c1a9e4c23128ced41b6e19da1e490
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Convert unary operations and some other runtime methods

Change-Id: I985876ade37efd24e1d4f8360a6472282cf44f8b
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Change binops to use ReturnedValue

Change-Id: I068b1af5c352fc84793079e5bccbe3482b04cafa
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Fix __qmljs_init_closure to use ReturnedValue

Change-Id: I777a63db32857a6a326839e3fcdb99657dc80e7f
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Convert ReturnedValue into a primitive (typedef to quint64)

ReturnedValue is used to return values from runtime methods
The type has to be a primitive type (no struct or union), so that
the compiler will return it in a register on all platforms.

They will be returned in rax on x64, [eax,edx] on x86 and [r0,r1] on arm.

Change-Id: I38433e6fad252370dda5dc335d9c5be8f22e8c76
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Fix ReturnedValue support on ia32 and arm

The 64-bit value is passed in eax:edx and r0:r1

Change-Id: I9a8a7d8ae41f14780958351ecedea2d117f77d85
Reviewed-by: Lars Knoll <lars.knoll@digia.com>