Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8024174

Setting __proto__ property in Object literal should be supported

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P2
    • 8
    • 8
    • core-libs
    • None
    • b108
    • generic
    • generic
    • Verified

    Description

      __proto__ used in an object literal is not supported. The following example
      var obj = {__proto__: aProto, prop:999};
      needs to be rewritten using Object.setPrototypeOf:
      var obj = Object.setPrototypeOf({prop:999}, aProto);

      This does impact some major node modules such as express.

      Attachments

        Activity

          People

            sundar Sundararajan Athijegannathan
            jfdenise Jean-Francois Denise (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: