qq_40413584
qq_40413584
2018-12-20 16:32

Js中,怎么删除局部变量啊

  • javascript

我用delete,在严格模式中不能用

function JSONRpcClient_poolReturnHTTPRequest(http)
{
    if(JSONRpcClient.http_spare.length >= JSONRpcClient.http_max_spare)
    delete http;--删除局部变量http
    else
    JSONRpcClient.http_spare.push(http);
};
  • 点赞
  • 回答
  • 收藏
  • 复制链接分享

2条回答