Skip to content

Commit

Permalink
[enhance] compiler, qmlAstCons: Added restricted_bypass with label
Browse files Browse the repository at this point in the history
  • Loading branch information
BourgerieQuentin committed Aug 6, 2012
1 parent 930f97b commit 2922816
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
4 changes: 3 additions & 1 deletion compiler/libqmlcompil/qmlAstCons.ml
@@ -1,5 +1,5 @@
(* (*
Copyright © 2011 MLstate Copyright © 2011, 2012 MLstate
This file is part of Opa. This file is part of Opa.
Expand Down Expand Up @@ -981,6 +981,8 @@ struct
let dot ?(label=Annot.next_label nopos) e f = Q.Dot (label, e, f) let dot ?(label=Annot.next_label nopos) e f = Q.Dot (label, e, f)
let extendrecord ?(label=Annot.next_label nopos) f e n = Q.ExtendRecord (label, f, e, n) let extendrecord ?(label=Annot.next_label nopos) f e n = Q.ExtendRecord (label, f, e, n)
let bypass ?(label=Annot.next_label nopos) s = Q.Bypass (label, s) let bypass ?(label=Annot.next_label nopos) s = Q.Bypass (label, s)
let restricted_bypass ?label ~pass s =
directive (`restricted_bypass pass) [bypass ?label s] []
let coerce ?(label=Annot.next_label nopos) e t = Q.Coerce (label, e, t) let coerce ?(label=Annot.next_label nopos) e t = Q.Coerce (label, e, t)
end end


Expand Down
3 changes: 2 additions & 1 deletion compiler/libqmlcompil/qmlAstCons.mli
@@ -1,5 +1,5 @@
(* (*
Copyright © 2011 MLstate Copyright © 2011, 2012 MLstate
This file is part of Opa. This file is part of Opa.
Expand Down Expand Up @@ -500,6 +500,7 @@ sig
val dot : ?label:Annot.label -> QmlAst.expr -> string -> QmlAst.expr val dot : ?label:Annot.label -> QmlAst.expr -> string -> QmlAst.expr
val extendrecord : ?label:Annot.label -> string -> QmlAst.expr -> QmlAst.expr -> QmlAst.expr val extendrecord : ?label:Annot.label -> string -> QmlAst.expr -> QmlAst.expr -> QmlAst.expr
val bypass : ?label:Annot.label -> BslKey.t -> QmlAst.expr val bypass : ?label:Annot.label -> BslKey.t -> QmlAst.expr
val restricted_bypass : ?label:Annot.label -> pass:string -> BslKey.t -> QmlAst.expr
val coerce : ?label:Annot.label -> QmlAst.expr -> QmlAst.ty -> QmlAst.expr val coerce : ?label:Annot.label -> QmlAst.expr -> QmlAst.ty -> QmlAst.expr
end end


Expand Down

0 comments on commit 2922816

Please sign in to comment.