title: Uncaught SyntaxError: Unexpected identifier on openprocessing with processing.js
body: <p>The code in question is this:</p>
  
  <pre><code>void update() {
    int nearbyYou = 0;
    int nearbyWork = 0;
    int nearbyCap = 0;
    int nearbyDead = 0;
    for (int iter = 0; iter &lt; 8; iter = iter + 1) {
      switch nearby[iter] {
        case 0:
          nearbyDead++;
        case 1:
          nearbyYou++;
        case 2:
          nearbyWork++;
        case 3:
          nearbyCap++;
      }
      switch type {
        case 0:
          if (nearbyWork &gt;= 1) {
            type = 1;
          } else {
            type = 0;
          }
        case 1:
          if (nearbyWork &gt;= 1) {
            type = 2;
          } else if (nearbyWork &gt;= 7 || nearbyCap &gt;= 2) {
            type = 3;
          } else {
            type = 0;
          }
        case 2:
          type = 0;
      }
    }
  }
  }
  </code></pre>
  
  <p>And I get an <code>Uncaught SyntaxError: Unexpected identifier</code> in the processing file</p>
  
  <pre><code>Uncaught SyntaxError: Unexpected identifier
  https://preview.openprocessing.org/assets/js/vendor/processingjsReleases/processing-1.6.6.js?version=7.42, line 885
  https://preview.openprocessing.org/assets/js/vendor/processingjsReleases/processing-1.6.6.js?version=7.42, line 21586
  https://preview.openprocessing.org/assets/js/vendor/processingjsReleases/processing-1.6.6.js?version=7.42, line 21623
  https://preview.openprocessing.org/sketch/preview/?random=0.24172648490425175, line 49
  https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js, line 2
  https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js, line 2
  </code></pre>
  
  <p>I've tried a couple things here and there but I really don't know how to adress this error.</p>