Skip to content
Browse files

[enhance] runtime, compiler, cpsjs: Added a debug name to uncps funct…

…ion and bypass projection
  • Loading branch information...
1 parent f8bee4d commit d5679c0b373b2b2a4653279e336e9252969f57fb @BourgerieQuentin BourgerieQuentin committed May 29, 2012
Showing with 5 additions and 3 deletions.
  1. +2 −2 qmlcps/qmlCpsClientLib.js
  2. +3 −1 qmljsimp/imp_Bsl.ml
View
4 qmlcps/qmlCpsClientLib.js
@@ -464,9 +464,9 @@ function spawn(f) {
* Transform a cps function [f] (function (..., k)) to a non-cps function
* [function(...)].
*/
-function uncps(pk, f) {
+function uncps(pk, f, name) {
return function (){
- var b = new Barrier("uncps : " + f);
+ var b = new Barrier(name != undefined ? name : ("uncps : " + f));
var k = pk.ccont(function(x){b.release(x)});
var a = Array.prototype.slice.call(arguments);
a.push(k);
View
4 qmljsimp/imp_Bsl.ml
@@ -150,7 +150,9 @@ struct
JsCons.Expr.call ~pure:true
(JsCons.Expr.ident (JsAst.Native (`global, "uncps")))
[(JsCons.Expr.ident (JsAst.Native (`local, "k")));
- function_]
+ function_;
+ JsCons.Expr.string (BslKey.to_string key)
+ ]
in
let function_ =
if check then

0 comments on commit d5679c0

Please sign in to comment.
Something went wrong with that request. Please try again.