(
Context cx, JSFunction f, Object nt, VarScope s, Object thisObj, Object[] args)
| 651 | } |
| 652 | |
| 653 | private static Object trunc( |
| 654 | Context cx, JSFunction f, Object nt, VarScope s, Object thisObj, Object[] args) { |
| 655 | double x = ScriptRuntime.toNumber(args, 0); |
| 656 | x = ((x < 0.0) ? Math.ceil(x) : Math.floor(x)); |
| 657 | return ScriptRuntime.wrapNumber(x); |
| 658 | } |
| 659 | } |
no test coverage detected