Fixed typo

This commit is contained in:
radrow 2019-07-16 17:10:50 +02:00
parent 8d4e246686
commit a05e6ba800
2 changed files with 13 additions and 14 deletions

View File

@ -21,7 +21,7 @@ string(String) ->
-spec string(string(), compiler:options()) -> parse_result(). -spec string(string(), compiler:options()) -> parse_result().
string(String, Opts) -> io:format("STRING WITH OPTS: ~p\n", [Opts]), string(String, Opts) ->
case lists:keyfind(src_file, 1, Opts) of case lists:keyfind(src_file, 1, Opts) of
{src_file, File} -> string(String, sets:add_element(File, sets:new()), Opts); {src_file, File} -> string(String, sets:add_element(File, sets:new()), Opts);
false -> string(String, sets:new(), Opts) false -> string(String, sets:new(), Opts)

View File

@ -38,7 +38,7 @@ namespace Func =
private function iter_(n : int, f : 'a => 'a, acc : 'a => 'a) : 'a => 'a = private function iter_(n : int, f : 'a => 'a, acc : 'a => 'a) : 'a => 'a =
if(n == 0) acc if(n == 0) acc
elif(n == 1) comp(f, acc) elif(n == 1) comp(f, acc)
else else iter_(n / 2, comp(f, f), if(n mod 2 == 0) acc else comp(f, acc)) else iter_(n / 2, comp(f, f), if(n mod 2 == 0) acc else comp(f, acc))
function curry2(f : ('a, 'b) => 'c) : 'a => ('b => 'c) = function curry2(f : ('a, 'b) => 'c) : 'a => ('b => 'c) =
(x) => (y) => f(x, y) (x) => (y) => f(x, y)
@ -50,19 +50,18 @@ namespace Func =
function uncurry3(f : 'a => ('b => ('c => 'd))) : ('a, 'b, 'c) => 'd = function uncurry3(f : 'a => ('b => ('c => 'd))) : ('a, 'b, 'c) => 'd =
(x, y, z) => f(x)(y)(z) (x, y, z) => f(x)(y)(z)
/* TODO : parser fails here, probably a bug // TODO : parser fails here, probably a bug. Uncomment when resolved.
function tuplify2(f : ('a, 'b) => 'c) : (('a, 'b)) => 'c = // function tuplify2(f : ('a, 'b) => 'c) : (('a, 'b)) => 'c =
(t) => switch(t) // (t) => switch(t)
(x, y) => f(x, y) // (x, y) => f(x, y)
function tuplify3(f : ('a, 'b, 'c) => 'd) : (('a, 'b, 'c)) => 'd = // function tuplify3(f : ('a, 'b, 'c) => 'd) : (('a, 'b, 'c)) => 'd =
(t) => switch(t) // (t) => switch(t)
(x, y, z) => f(x, y, z) // (x, y, z) => f(x, y, z)
function untuplify2(f : (('a, 'b)) => 'c) : ('a, 'b) => 'c = // function untuplify2(f : (('a, 'b)) => 'c) : ('a, 'b) => 'c =
(x, y) => f((x, y)) // (x, y) => f((x, y))
function untuplify3(f : (('a, 'b, 'c)) => 'd) : ('a, 'b, 'c) => 'd = // function untuplify3(f : (('a, 'b, 'c)) => 'd) : ('a, 'b, 'c) => 'd =
(x, y, z) => f((x, y, z)) // (x, y, z) => f((x, y, z))
*/
". ".
std_list() ->" std_list() ->"