// Compiles CoffeeScript source to JavaScript.
//
// input - string containing contents of the file
// filename - name of file, used to report errors
//
// Returns { output: <compiled JavaScript> } or { exception: <exception message> }
function compileCoffeeScriptSource(input, filename) {
  try {
    return { output: CoffeeScript.compile(input, {header: true}) };
  }
  catch (err) {
    return { exception: CoffeeScript.helpers.prettyErrorMessage(err, filename, input, false) };
  }
}

@@ -287,16 +287,18 @@
 ) %7B%0A
+  
   try %7B%0A
     
@@ -293,16 +293,20 @@
   try %7B%0A
+    
     retu
@@ -363,16 +363,36 @@
 true
+, filename: filename
 %7D) %7D;%0A  
 %7D%0A  
@@ -387,18 +387,22 @@
 %7D) %7D;%0A  
-%7D%0A
+  %7D%0A  
   catch 
@@ -409,24 +409,28 @@
 (err) %7B%0A    
+ 
+   
 return %7B exc
@@ -441,80 +441,28 @@
 on: 
-CoffeeScript.helpers.prettyErrorMessage(err, filename, input, false
+err.toString(
 ) %7D;%0A
+  
   %7D%0A

Update shim for invoking CoffeeScript compiler to work with 1.7.1