Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-13779] Android: remove access to V8's gc from JavaScript

GitHub Issuen/a
TypeBug
PriorityHigh
StatusClosed
ResolutionFixed
Resolution Date2013-05-17T17:31:44.000+0000
Affected Version/sRelease 3.1.0
Fix Version/s2013 Sprint 10 Core, 2013 Sprint 10, Release 3.2.0
ComponentsAndroid, Core
Labelsn/a
ReporterMatt Langston
AssigneeAllen Yeung
Created2013-05-07T17:15:48.000+0000
Updated2013-11-15T20:01:38.000+0000

Description

Access to V8's gc from JavaScript was inadvertently introduced into the public API as a part of integrating the V8 profiler. This should be corrected and access to V8's gc from JavaScript should be removed.

Comments

  1. Matt Langston 2013-05-07

    My reasons for wanting gc removed from the public API are documented in TIMOB-13760.
  2. Allen Yeung 2013-05-15

    We still want to expose this for profile builds, since studio uses it. Test Instructions: Verify that it fails on a normal build: 1. Create a new project 2. Call the gc() method inside app.js 3. Run the app and there should be a runtime error saying that gc is undefined. Verify that it still works for the profiler: 1. Create a new project in appcelerator studio 2. Run the app with profiling enabled 3. Inside the profiler perspective, hit the gc button and verify that you get a message like 'RECEIVED COMMAND 1' in the console, and NOT an error.
  3. Allen Yeung 2013-05-15

    https://github.com/appcelerator/titanium_mobile/pull/4265
  4. Lokesh Choudhary 2013-11-15

    Verified the fix. Putting method in the app.js gives runtime error, while in profiler fives 'RECEIVED COMMAND 1'. Closing. Environment: Appcel Studio : 3.2.0.201311150806 Ti SDK : 3.2.0.v20131114184328 Mac OSX : 10.8.5 Alloy : 1.3.0 CLI - 3.2.0

JSON Source