Giter Site home page Giter Site logo

lively.vm's Introduction

lively.vm's People

Contributors

rksm avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

lively.vm's Issues

new.target not supported

The following code cannot be executed:

class Foo {
  constructor() {
    if (new.target === Foo) {
      throw new TypeError('Cannot construct Foo directly');
    }
  }
}

And produces the following error

lively.vm evalCodeTransform not working: SyntaxError: workspace://1: Unexpected token (8:28)
   6 |             key: Symbol.for('lively-instance-initialize'),
   7 |             value: function Foo_initialize_() {
>  8 |                 if ([object Object].[object Object] === __lvVarRecorder.Foo) {
     |                             ^
   9 |                     throw new TypeError('Cannot construct Foo directly');
  10 |                 }
  11 |             }
    at Parser.pp.raise (https://livelykernel.github.io/lively4-core/src/external/babel-browser.js:65149:13)
    at Parser.pp.unexpected (https://livelykernel.github.io/lively4-core/src/external/babel-browser.js:66379:8)
    at Parser.pp.expect (https://livelykernel.github.io/lively4-core/src/external/babel-browser.js:66373:33)
    at Parser.pp.parseExprList (https://livelykernel.github.io/lively4-core/src/external/babel-browser.js:64962:12)
    at Parser.pp.parseExprAtom (https://livelykernel.github.io/lively4-core/src/external/babel-browser.js:64564:28)
    at Parser.eval [as parseExprAtom] (https://livelykernel.github.io/lively4-core/src/external/babel-browser.js:67755:22)
    at Parser.pp.parseExprSubscripts (https://livelykernel.github.io/lively4-core/src/external/babel-browser.js:64413:19)
    at Parser.pp.parseMaybeUnary (https://livelykernel.github.io/lively4-core/src/external/babel-browser.js:64394:19)
    at Parser.pp.parseExprOps (https://livelykernel.github.io/lively4-core/src/external/babel-browser.js:64340:19)
    at Parser.pp.parseMaybeConditional (https://livelykernel.github.io/lively4-core/src/external/babel-browser.js:64322:19)

original error report: LivelyKernel/lively4-core#66

extract class system

Our class implementation now lives to equal parts in lively.ast and here and fits in neither. Extract into a lively.classes package.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.