engine: mozjs60 changes for GC sweeping tracking
With the switch to mozjs60, the sweeping happens in three phases insted of two: JSFINALIZE_GROUP_PREPARE, JSFINALIZE_GROUP_START, and JSFINALIZE_GROUP_END. Update the code to keep track of whether the runtime is currently doing GC sweeping, and prevent calling JS code at that time.
Fixes: #212 (moved)
Edited by Andrea Azzarone