File: drop-__proto__-calls.patch

package info (click to toggle)
coffeescript 2.7.0%2Bdfsg1-4
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 9,368 kB
  • sloc: makefile: 20; xml: 9; javascript: 5; sh: 1
file content (18 lines) | stat: -rw-r--r-- 459 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
Description: drop __proto__ calls in test
Author: Yadd <yadd@debian.org>
Forwarded: no
Last-Update: 2022-12-02

--- a/test/compilation.coffee
+++ b/test/compilation.coffee
@@ -105,8 +105,8 @@
 
 test "#1106: __proto__ compilation", ->
   object = eq
-  @["__proto__"] = true
-  ok __proto__
+  Object.setPrototypeOf @, {a: true}
+  ok Object.getPrototypeOf(@).a
 
 test "reference named hasOwnProperty", ->
   CoffeeScript.compile 'hasOwnProperty = 0; a = 1'