Bug 1028866 part 1 - Move string allocation functions into js namespace, remove js_* prefix. r=luke

--HG--
extra : rebase_source : 1f4c940dce07a7ced533c641c60cf76592fd61ac
Bug 1028866 part 2 - Cleanup NewStringCopyZ. r=luke

--HG--
extra : rebase_source : 321aae85dd6a3e2fa90474ceed9bd03347f528a8