weimingtom / processingas

Automatically exported from code.google.com/p/processingas
0 stars 0 forks source link

class inheritance broken - 'extends' keyword breaks scripts #7

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. go to test suite page, note that BounceBubbles demo works in Java and
Flash mode
2. edit BouncyBubbles.processing and add an inheritance test at the bottom
of file:

class BlueBall extends Ball {
  BlueBall(float xin, float yin, float din, int idin, Ball[] oin) {
    x = xin;
    y = yin;
    diameter = din;
    id = idin;
    others = oin;
  }
}

3. note that the example still works in Java mode, but now fails in Flash mode

What is the expected output? What do you see instead?

Processing script should run similarly in all platforms, but Flash mode
stops working when inheritance is added.

What version of the product are you using? On what operating system?

Windows XP, Firefox 3.04, processing.swf.m1

Please provide any additional information below.

Note that I'm not trying to use the derived class in any way, it seems that
the presence of the "extends" keyword is enough to break the script.

Original issue reported on code.google.com by geoffmat...@gmail.com on 27 Jan 2009 at 4:09

GoogleCodeExporter commented 9 years ago
NOTE: I meant that the script still work in JavaScript mode after adding 
ineritance
test.  Of course compiled JAVA wouldn't change.

Original comment by geoffmat...@gmail.com on 27 Jan 2009 at 5:30