anchor.diff:  -export([fread/2,fread/3]).
   
   -import(lists, [reverse/1,reverse/2]).
  +
  +-define(is_whitespace(C),
  +	((C) =:= $\s orelse (C) =:= $\t
  +	 orelse (C) =:= $\r orelse (C) =:= $\n)).
   
   %%-----------------------------------------------------------------------
   
  
positive.code: %% fread_digits(Line, N, Base, Characters)
  %%  Read segments of things, return "thing" characters in reverse order.
  
  fread_skip_white([$\s|Line]) -> fread_skip_white(Line);
  fread_skip_white([$\t|Line]) -> fread_skip_white(Line);
  fread_skip_white([$\r|Line]) -> fread_skip_white(Line);
  fread_skip_white([$\n|Line]) -> fread_skip_white(Line);
  fread_skip_white(Line) -> Line.
  
  fread_skip_white([$\s|Line], N) ->
      fread_skip_white(Line, N+1);
  fread_skip_white([$\t|Line], N) ->
      fread_skip_white(Line, N+1);
  fread_skip_white([$\r|Line], N) ->
      fread_skip_white(Line, N+1);
  fread_skip_white([$\n|Line], N) ->
      fread_skip_white(Line, N+1);
  fread_skip_white(Line, N) -> {Line,N}.
  
  fread_skip_latin1_nonwhite([$\s|Line], N, Cs) -> {[$\s|Line],N,Cs};
  fread_skip_latin1_nonwhite([$\t|Line], N, Cs) -> {[$\t|Line],N,Cs};
  fread_skip_latin1_nonwhite([$\r|Line], N, Cs) -> {[$\r|Line],N,Cs};
  fread_skip_latin1_nonwhite([$\n|Line], N, Cs) -> {[$\n|Line],N,Cs};
  fread_skip_latin1_nonwhite([C|Line], N, []) when C > 255 ->
      {[C|Line],N,error};
  fread_skip_latin1_nonwhite([C|Line], N, Cs) when C > 255 ->
  
negative.code: fread(Format, Line) ->
      fread(Format, Line, 0, []).
  
  fread([$~|Format0]=AllFormat, Line, N, Results) ->
      {Format,F,Sup,Unicode} = fread_field(Format0),
      fread1(Format, F, Sup, Unicode, Line, N, Results, AllFormat);
  fread([C|Format], Line, N, Results) when ?is_whitespace(C) ->
      fread_skip_white(Format, Line, N, Results);
  fread([C|Format], [C|Line], N, Results) ->
      fread(Format, Line, N+1, Results);
  