title: Utilities.formatDate returning wrong week number
body: <p>In Google Script I have the following code:</p>
  
  <pre><code>var myDate = new Date(sheet.getRange(3,1).getValue());
  var year = Utilities.formatDate(myDate, "Europe/Amsterdam", 'dd-MM-yyyy');
  var weekyear = Utilities.formatDate(myDate, "Europe/Amsterdam", 'dd-MM-YYYY');
  var week = Utilities.formatDate(myDate, "Europe/Amsterdam", 'w');
  </code></pre>
  
  <p>When I insert 30-12-2015 as date, the result will be.</p>
  
  <pre><code>// year: 30-12-2015
  // weekyear: 30-12-201**6**
  // week: 1
  </code></pre>
  
  <p>In my local timezone, it should be week number 53. Not 1.
  If I <a href="http://techblog.procurios.nl/k/news/view/33796/14863/calculate-iso-8601-week-and-year-in-javascript.html" rel="nofollow">calculate the week in ISO 8601</a>, the result is 52.</p>
  
  <p>Strange, isn't it?  </p>
  
  <p>Edited:
  New attempt, with this code</p>
  
  <pre><code>var cursus_datum = sheet.getRange(3,1).getValue();
    Logger.log('type of data: ' + typeof cursus_datum);
    Logger.log(cursus_datum);
    Logger.log(Utilities.formatDate(cursus_datum, SpreadsheetApp.getActive().getSpreadsheetTimeZone(), "d-MM-y HH:mm"));
    Logger.log(Utilities.formatDate(cursus_datum, SpreadsheetApp.getActive().getSpreadsheetTimeZone(), "w"));
  </code></pre>
  
  <p>This results in</p>
  
  <pre><code>// type of data: object
  // Wed Dec 30 09:00:00 GMT+01:00 2015
  // 30-12-2015 00:00 which is perfect
  // 1 which is **not** correct.
  </code></pre>
  
  <p>The wrong week <strong>is</strong> the bug.</p>