call_escape.js 586 B

123456789101112131415161718192021
  1. //-------------------------------------------------------------------------------------------------------
  2. // Copyright (C) Microsoft. All rights reserved.
  3. // Licensed under the MIT license. See LICENSE.txt file in the project root for full license information.
  4. //-------------------------------------------------------------------------------------------------------
  5. function func(x, f)
  6. {
  7. WScript.Echo(f());
  8. }
  9. function test(param)
  10. {
  11. var call_escape = function()
  12. {
  13. return param;
  14. }
  15. func(1, call_escape);
  16. }
  17. test("test1");
  18. test("test2");