diff --git a/src/TODO b/src/TODO
index 4f416b8befa6d9e752cd80d63fff8d0418e204c9..f706890a6b4c261ff7e64dd11ea36200ba0fe08f 100644
--- a/src/TODO
+++ b/src/TODO
@@ -88,13 +88,6 @@ est evalu
   devrait être multi-horloge également. Et peut-etre d'autres encore...
 
 
-* Que faire des itérateurs imbriqués ? style :
-
-        fill<< fill<< incremental ; L >> ; H >>( iacc );
-
-lus2lic les accepte, mais pas lic2loc. Faut-il étendre lic2loc,
-ou faire en sorte que lus2lic invente un noeud alias intermédiaire ?
-
 *********************************************************************
 *********************************************************************
 *** questions pour bibi
diff --git a/src/evalClock.ml b/src/evalClock.ml
index 622e59afe5d95e4986013171f2d5a619d5dbb022..3b2688178a4742a5043f999160db9832ad47fea0 100644
--- a/src/evalClock.ml
+++ b/src/evalClock.ml
@@ -1,4 +1,4 @@
-(** Time-stamp: <modified the 28/08/2008 (at 10:26) by Erwan Jahier> *)
+(** Time-stamp: <modified the 28/08/2008 (at 11:17) by Erwan Jahier> *)
  
   
 open Predef
@@ -193,14 +193,14 @@ let tabulate_res vef clock_eff_list =
 (*   flush stdout; *)
   Hashtbl.add val_exp_eff_clk_tab vef clock_eff_list
 
-let (val_exp_eff : val_exp_eff -> clock_eff list) =
+let (get_val_exp_eff : val_exp_eff -> clock_eff list) =
   fun vef -> 
     try 
       let res = Hashtbl.find val_exp_eff_clk_tab vef in
       let var_clock_to_base = function
-        (* Some expressions migth be infered to be a variable clock
-           (e.g., constants). In that case, it is ok to consider that such
-           expression are on the base clock.*)
+          (* Some expressions migth be infered to be a variable clock
+             (e.g., constants). In that case, it is ok to consider that such
+             expressions are on the base clock.*)
         | ClockVar _ 
         | On(_,ClockVar _) -> BaseEff
         | x -> x
@@ -213,8 +213,6 @@ let (val_exp_eff : val_exp_eff -> clock_eff list) =
       flush stdout;
       assert false
 
-
-
 (******************************************************************************)
 (** Now we can go on and define [f].  *)
 
@@ -227,7 +225,7 @@ let rec (f : id_solver -> subst -> val_exp_eff -> clock_eff list * subst) =
     let s = snd res in
       (* during the inner call to f_aux, some intermediary clock variables
          may remain. *)
-      Hashtbl.iter 
+      Hashtbl.iter
         (fun ve cel -> 
            let cel2 = List.map (apply_subst2 s) cel in
              if cel <> cel2 then
@@ -235,7 +233,7 @@ let rec (f : id_solver -> subst -> val_exp_eff -> clock_eff list * subst) =
         val_exp_eff_clk_tab;
       res
 
-      
+
 and f_aux id_solver s ve =
   let cel, s = 
     match ve with
diff --git a/src/evalClock.mli b/src/evalClock.mli
index 484caf6337011c30b211c1409b31d6a4b1132937..c604d44de69a1d1aede1aa00b29c8bb188e11f06 100644
--- a/src/evalClock.mli
+++ b/src/evalClock.mli
@@ -1,4 +1,4 @@
-(** Time-stamp: <modified the 19/08/2008 (at 15:17) by Erwan Jahier> *)
+(** Time-stamp: <modified the 28/08/2008 (at 10:43) by Erwan Jahier> *)
 
 open CompiledData
 open UnifyClock
@@ -35,4 +35,4 @@ val check_res : Lxm.t -> subst -> left_eff list -> clock_eff list -> unit
 (* Returns the clock of an expression. Note that this function uses
    an internal table, and therefore it should not be called before
    the clock checking has been done (by the function f above).*)
-val val_exp_eff : val_exp_eff -> clock_eff list
+val get_val_exp_eff : val_exp_eff -> clock_eff list
diff --git a/src/lazyCompiler.ml b/src/lazyCompiler.ml
index 2fbecf86143a61c7f853542719d0985b4e329978..df7dcd326b3af193350acbe040d503e08f4879cc 100644
--- a/src/lazyCompiler.ml
+++ b/src/lazyCompiler.ml
@@ -1,4 +1,4 @@
-(** Time-stamp: <modified the 28/08/2008 (at 10:28) by Erwan Jahier> *)
+(** Time-stamp: <modified the 28/08/2008 (at 11:12) by Erwan Jahier> *)
 
 
 open Lxm
@@ -538,6 +538,7 @@ and (node_check_do: t -> CompiledData.node_key -> Lxm.t -> SymbolTab.t ->
       bool -> Ident.pack_name -> SyntaxTreeCore.node_info srcflagged -> 
       CompiledData.node_exp_eff) =
   fun this nk lxm symbols provide_flag pack_name node_def ->
+    let lxm = node_def.src in
     let local_env = make_local_env nk in
     let node_id_solver = {
       (* a [node_id_solver] is a [id_solver] where we begin to look
@@ -577,13 +578,19 @@ and (node_check_do: t -> CompiledData.node_key -> Lxm.t -> SymbolTab.t ->
       symbols  = symbols;
     }
     in
+    let find_var_info lxm vars id =
+      try Hashtbl.find vars.vartable id
+      with Not_found -> 
+        raise (Compile_error 
+                 (lxm,"\n*** Unknown ident: " ^ (Ident.to_string id)))
+    in
     let make_node_eff node_def_eff =
       (* building not aliased nodes *)
       match node_def.it.vars with
         | None -> assert false (* a node with a body should have a profile *)
         | Some vars ->
             let type_args id =
-              let vi = Hashtbl.find vars.vartable id in
+              let vi = find_var_info lxm vars id in
               let t_eff = GetEff.typ node_id_solver vi.it.var_type in
               let c_eff = GetEff.clock node_id_solver vi.it in
               let vi_eff = {
@@ -603,14 +610,14 @@ and (node_check_do: t -> CompiledData.node_key -> Lxm.t -> SymbolTab.t ->
                 (* I cannot use List.sort as I only have a partial order on vars
                  -> hence I perform a topological sort *)
                 let rec depends_on v1 v2 =
-                  match (Hashtbl.find vars.vartable v1).it.var_clock with
+                  match (find_var_info lxm vars v1).it.var_clock with
                     | Base -> false
                     | NamedClock {it=v1clk} -> v1clk = v2 || depends_on v1clk v2
                 in
                 let rec aux acc l = match l with
                   | [] -> acc
                   | v::tail -> (
-                      match (Hashtbl.find vars.vartable v).it.var_clock with
+                      match (find_var_info lxm vars v).it.var_clock with
                         | Base -> 
                             if List.mem v acc then 
                               aux acc tail 
@@ -765,8 +772,8 @@ and (node_check_do: t -> CompiledData.node_key -> Lxm.t -> SymbolTab.t ->
               | None -> alias_node
               | Some vars ->
                   let vi_il, vi_ol = 
-                    List.map (fun id -> Hashtbl.find vars.vartable id) vars.inlist,
-                    List.map (fun id -> Hashtbl.find vars.vartable id) vars.outlist
+                    List.map (fun id -> find_var_info lxm vars id) vars.inlist,
+                    List.map (fun id -> find_var_info lxm vars id) vars.outlist
                   in
                   let aux vi = GetEff.typ node_id_solver vi.it.var_type
                   in
diff --git a/src/split.ml b/src/split.ml
index d717ba7f076581c670bcc105ef3b95606ddea3d7..3fa1778522688f0ba35710f916073b25f2ceb1f5 100644
--- a/src/split.ml
+++ b/src/split.ml
@@ -1,4 +1,4 @@
-(** Time-stamp: <modified the 25/08/2008 (at 10:18) by Erwan Jahier> *)
+(** Time-stamp: <modified the 28/08/2008 (at 10:43) by Erwan Jahier> *)
 
 
 open Lxm
@@ -80,7 +80,7 @@ and (split_val_exp : bool -> val_exp_eff -> val_exp_eff * split_acc) =
               CallByPosEff(by_pos_op_eff, OperEff vel), (eql, vl) 
             else
               (* create the var for the current call *)
-              let clk_l = EvalClock.val_exp_eff ve in
+              let clk_l = EvalClock.get_val_exp_eff ve in
               let typ_l = EvalType.val_exp_eff ve in 
               let nv_l = List.map2 new_var typ_l clk_l in
 
diff --git a/src/test/should_fail/clock/bad_id.lus b/src/test/should_fail/clock/bad_id.lus
new file mode 100644
index 0000000000000000000000000000000000000000..e8a54da15012e54ebd85a396bf7fa014241ff616
--- /dev/null
+++ b/src/test/should_fail/clock/bad_id.lus
@@ -0,0 +1,7 @@
+
+
+node toto(c: bool; x: int) returns (y: int when b);
+let
+
+  y = 1+1+(x when c);
+tel
\ No newline at end of file
diff --git a/src/test/test.res.exp b/src/test/test.res.exp
index b08a5d0b6dbb376f287aca0291e1a60f609f5125..86cac852167f8e717bdff169753f42447658a1e6 100644
--- a/src/test/test.res.exp
+++ b/src/test/test.res.exp
@@ -9919,7 +9919,7 @@ returns (
 	clock4_x:bool;
 	clock4_y:bool when clock4_x);
 
-*** oops: an internal error occurred in file evalClock.ml, line 275, column 31
+*** oops: an internal error occurred in file evalClock.ml, line 273, column 31
 *** when compiling lustre program should_work/clock/when_not.lus
 
 ----------------------------------------------------------------------
@@ -18440,6 +18440,14 @@ Opening file should_fail/clock/bad_call02.lus
 
 
 
+----------------------------------------------------------------------
+====> ../lus2lic -vl 2 --compile-all-items should_fail/clock/bad_id.lus
+Opening file should_fail/clock/bad_id.lus
+*** Error in file "should_fail/clock/bad_id.lus", line 3, col 6 to 9, token 'toto':
+*** 
+*** Unknown ident: b
+
+
 ----------------------------------------------------------------------
 ====> ../lus2lic -vl 2 --compile-all-items should_fail/clock/clock.lus
 Opening file should_fail/clock/clock.lus