You are reading a single comment by @Gordon and its replies. Click here to read the full conversation.
  • I've just fixed a few big issues with the online compiler, the main ones being:

    • Shift/compare operators
    • pre/postincrement behaviour
    • this in function calls
    • Error reporting (hacky, but now usually reports issues in the console window)
    • some array access types that weren't working
    • Fixed incorrect calculation of local variables (local var list not cleared between compiles!)

    You still can't do stuff like:

    • defining functions in functions
    • creating fields in objects, or global variables

    So you're a bit limited, but what you can now do is stuff like:

    function setPixel(x,y,c){
        "compiled";
        ce.reset();
        spi.write(0x2A,dc);
        spi.write(x>>8,x,(x+1)>>8,x+1);
        spi.write(0x2B,dc);
        spi.write(y>>8,y,(y+1)>>8,y+1);
        spi.write(0x2C,dc);
        spi.write(c>>8,c);
        ce.set();
      }
    

    So hopefully it can provide some nice speed improvements where IO is concerned.

    I'll update the documentation on it later on.

About

Avatar for Gordon @Gordon started