Clean up ScriptGroup2 implementation

b/19944127

- Adjust ref counting
- Fix value size type in closure creation

Change-Id: I1179d34aa67f845578740e71cc2da4f82419f251
6 files changed