Release of coccinelle 1.0.0-rc9
[bpt/coccinelle.git] / parsing_cocci / iso_compile.ml
index 687c942..8780622 100644 (file)
@@ -1,5 +1,7 @@
 (*
- * Copyright 2005-2010, Ecole des Mines de Nantes, University of Copenhagen
+ * Copyright 2010, INRIA, University of Copenhagen
+ * Julia Lawall, Rene Rydhof Hansen, Gilles Muller, Nicolas Palix
+ * Copyright 2005-2009, Ecole des Mines de Nantes, University of Copenhagen
  * Yoann Padioleau, Julia Lawall, Rene Rydhof Hansen, Henrik Stuart, Gilles Muller, Nicolas Palix
  * This file is part of Coccinelle.
  *
@@ -63,7 +65,7 @@ let get_p _ =
   let c = !pctr in
   pctr := c + 1;
   let name = ("",Printf.sprintf "p%d" c) in
-  Ast0.MetaPos(Ast0.make_mcode name,[],Ast.PER)
+  [Ast0.MetaPos(Ast0.make_mcode name,[],Ast.PER)]
 
 let process_info l =
    let rec loop = function
@@ -78,13 +80,13 @@ let process_info l =
           let rec find_first_available a = function
               [] -> raise Not_found
             | (str,pos)::xs ->
-                if str = a && !pos = Ast0.NoMetaPos
+                if str = a && !pos = []
                 then pos
                 else find_first_available a xs in
           List.iter
             (function (str,pos) ->
               match !pos with
-                Ast0.NoMetaPos ->
+                [] ->
                   (try
                     let entries = List.map (find_first_available str) all in
                     let p = get_p() in