anchor.diff:  from_body([], Vt, St) -> {[],Vt,St}.
   
   from_expr_list(Es, Vt, St) -> mapfoldl2(fun from_expr/3, Vt, St, Es).
  +
  +%% from_block(Body, VarTable, State) -> {Block,State}.
  +
  +from_block(Es, Vt0, St0) ->
  +    case from_body(Es, Vt0, St0) of
  +        {[Le],Vt1,St1} -> {Le,Vt1,St1};
  +        {Les,Vt1,St1} -> {[progn|Les],Vt1,St1}
  +    end.
  +
  +%% from_add_guard(GuardTests, Body) -> Body.
  +%%  Only prefix with a guard when there are tests.
  +
  +from_add_guard([], Body) -> Body;               %No guard tests
  +from_add_guard(Gts, Body) ->
  +    [['when'|Gts]|Body].
  +
  +%% from_match(Match, VarTable, State) -> {LetForm,State}.
  +%%  Match returns the value of the expression. Use a let to do
  +%%  matching with an alias which we return for value.
  +
  +from_match({match,L,P,E}, Vt0, St0) ->
  +    {Alias,St1} = new_from_var(St0),            %Alias variable value
  +    MP = {match,L,{var,L,Alias},P},
  +    {Lp,Eqt,Vt1,St2} = from_pat(MP, Vt0, St1),  %The alias pattern
  +    {Le,Vt2,St3} = from_expr(E, Vt1, St2),      %The expression
  +    Leg = from_eq_tests(Eqt),                   %Implicit guard tests
  +    Lbody = from_add_guard(Leg, [Le]),          %Now build the whole body
  +    {['let',[[Lp|Lbody]],Alias],Vt2,St3}.
   
   %% from_bitsegs(Segs, VarTable, State) -> {Segs,VarTable,State}.
   
  
positive.code:     {Ssize,_,Vt1,St1} = from_pat(Size, Vt0, St0),
      {[[size,Ssize]],Vt1,St1}.
  
  from_lit({nil,_}) -> [];
  from_lit({integer,_,I}) -> I;
  from_lit({float,_,F}) -> F;
  from_lit({atom,_,A}) -> A;                  %Quoted atom
  from_lit({string,_,S}) -> S;
  from_lit({cons,_,H,T}) ->
      [cons,from_lit(H),from_lit(T)];
  from_lit({tuple,_,Es}) ->
      [tuple|from_lit_list(Es)].
  
  from_lit_list(Es) -> [ from_lit(E) || E <- Es ].
  
  -record(to, {vc=0                           %Variable counter
              }).
  
  to_expr(E, L) ->
      {Le,_} = to_expr(E, L, orddict:new(), #to{}),
      Le.
  
  %% to_expr(Expr, LineNumber, VarTable, State) -> {Expr,State}.
  
  to_expr([], L, _, St) -> {{nil,L},St};
  to_expr(I, L, _, St) when is_integer(I) -> {{integer,L,I},St};
  to_expr(F, L, _, St) when is_float(F) -> {{float,L,F},St};
  to_expr(V, L, Vt, St) when is_atom(V) ->    %Unquoted atom
      to_expr_var(V, L, Vt, St);
  to_expr(T, L, Vt, St0) when is_tuple(T) ->
      {Es,St1} = to_expr_list(tuple_to_list(T), L, Vt, St0),
      {{tuple,L,Es},St1};
  to_expr(?Q(V), L, _, St) -> {to_lit(V, L),St};
  to_expr([cons,H,T], L, Vt, St0) ->
      {Eh,St1} = to_expr(H, L, Vt, St0),
      {Et,St2} = to_expr(T, L, Vt, St1),
  
negative.code: from_icrt_cl({clause,_,[],[G],B}, Vt0, St0) ->          %If clause
      {Lg,Vt1,St1} = from_body(G, Vt0, St0),
      {Lb,Vt2,St2} = from_body(B, Vt1, St1),
      Lbody = from_add_guard(Lg, Lb),
      {['_'|Lbody],Vt2,St2};
  from_icrt_cl({clause,_,H,[],B}, Vt0, St0) ->
      {[Lh],Eqt,Vt1,St1} = from_pats(H, Vt0, St0),        %List of one
      {Lb,Vt2,St2} = from_body(B, Vt1, St1),
      Leg = from_eq_tests(Eqt),
      Lbody = from_add_guard(Leg, Lb),
      {[Lh|Lbody],Vt2,St2};
  from_icrt_cl({clause,_,H,[G],B}, Vt0, St0) ->
      {[Lh],Eqt,Vt1,St1} = from_pats(H, Vt0, St0),        %List of one
      {Lg,Vt2,St2} = from_body(G, Vt1, St1),
      {Lb,Vt3,St3} = from_body(B, Vt2, St2),
      Leg = from_eq_tests(Eqt),
      Lbody = from_add_guard(Leg ++ Lg, Lb),
      {[Lh|Lbody],Vt3,St3}.
  
  %% from_fun_cls(Clauses, VarTable, State) -> {Clauses,State}.
  %% from_fun_cl(Clause, VarTable, State) -> {Clause,VarTable,State}.
  