Skip to content

Instantly share code, notes, and snippets.

@erszcz
Created February 18, 2022 08:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save erszcz/4323e97860e67da290f52e2b0998a863 to your computer and use it in GitHub Desktop.
Save erszcz/4323e97860e67da290f52e2b0998a863 to your computer and use it in GitHub Desktop.
Gradualizer v0.1.3-150-gef2dbb7
_build/default/lib/aoc_erlang/ebin//aoc2019_day03.beam: Nonexhaustive patterns on line 35 at column 1
Example values which are not covered:
[]
_build/default/lib/aoc_erlang/ebin//aoc2019_day03.beam: The function call on line 62 at column 9 is expected to have type [T, ...] but it has type [B]
map_smallest(Fun, List) ->
lists:min(lists:map(Fun, List)).
^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2018_day10.beam: The pattern "position" on line 42 at column 19 doesn't have the type [0..1114111, ...]
_build/default/lib/aoc_erlang/ebin//aoc2019_day15.beam: Call to undefined function intcode:parse/1 on line 29 at column 12
_build/default/lib/aoc_erlang/ebin//aoc2019_day15.beam: The variable on line 57 at column 23 is expected to have type [T, ...] but it has type [Elem | Value]
end,
maps:to_list(Grid1)),
{Dist0, lists:max(OxygenDists)}.
^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2019_day15.beam: Call to undefined function intcode:execute/4 on line 62 at column 21
_build/default/lib/aoc_erlang/ebin//aoc2016_day13.beam: Call to undefined function astar2:astar/5 on line 36 at column 15
_build/default/lib/aoc_erlang/ebin//aoc2020_day16.beam: The variable on line 116 at column 44 is expected to have type [T, ...] but it has type [integer()]
lists:foldl(fun erlang:'*'/2,
1,
lists:map(fun (Pos) -> lists:nth(Pos, MyTicket) end,
^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day16.beam: The pattern #{fields := Fields, myticket := MyTicket, nearbytickets := Tickets} on line 129 at column 19 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2016_day05.beam: The function call on line 72 at column 25 is expected to have type maybe_improper_list(0..255 |
<<_:_*8>> |
maybe_improper_list(byte() |
binary() |
iolist(),
[] | binary()),
<<_:_*8>> | []) but it has type string()
hash(Input, Index) ->
erlang:md5(Input ++ integer_to_list(Index)).
^^^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2015_day06.beam: The pattern "toggle" on line 31 at column 27 doesn't have the type [0..1114111, ...]
_build/default/lib/aoc_erlang/ebin//aoc2015_day06.beam: Nonexhaustive patterns on line 87 at column 22
Example values which are not covered:
-1
_build/default/lib/aoc_erlang/ebin//aoc2019_day19.beam: Undefined remote type intcode:intcode_program/0 on line 23 at column 12
_build/default/lib/aoc_erlang/ebin//aoc2019_day19.beam: Undefined remote type intcode:intcode_program/0 on line 27 at column 13
_build/default/lib/aoc_erlang/ebin//aoc2019_day19.beam: Undefined remote type intcode:intcode_program/0 on line 34 at column 13
_build/default/lib/aoc_erlang/ebin//aoc2019_day19.beam: Call to undefined function intcode:execute/2 on line 44 at column 23
_build/default/lib/aoc_erlang/ebin//aoc2020_day20.beam: The variable on line 308 at column 32 is expected to have type [A, ...] but it has type [[<<_:_*8>> |
[0..1114111] |
{error, string(), binary()} |
{incomplete, string(), binary()} |
{integer(), integer()}]] |
[<<_:_*8>> |
[0..1114111] |
{error, string(), binary()} |
{incomplete, string(), binary()} |
{integer(), integer()}]
"(\\d+):",
[{capture, all_but_first, list}]),
TileNum = list_to_integer(hd(Matches)),
^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2019_day23.beam: Undefined remote type intcode:intcode_program/0 on line 26 at column 12
_build/default/lib/aoc_erlang/ebin//aoc2019_day23.beam: Undefined remote type intcode:intcode_program/0 on line 30 at column 12
_build/default/lib/aoc_erlang/ebin//aoc2019_day23.beam: Call to undefined function intcode:execute/4 on line 80 at column 12
_build/default/lib/aoc_erlang/ebin//aoc2016_day08.beam: The function call on line 40 at column 28 is expected to have type pos_integer() but it has type non_neg_integer()
rotate(X, N) ->
{L1, L2} = lists:split(length(X) - N rem length(X), X),
^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2016_day08.beam: The function call on line 80 at column 47 is expected to have type pos_integer() but it has type non_neg_integer()
lists:sublist(Display,
Height + 1,
length(Display) - Height),
^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2016_day08.beam: The variable on line 122 at column 23 is expected to have type [0..1114111] but it has type <<_:_*8>> |
maybe_improper_list(char() | unicode_binary() | charlist(),
unicode_binary() | [])
decode_instr(Instr) ->
[Op | Rest] = string:lexemes(Instr, " "),
case list_to_atom(Op) of
^^
_build/default/lib/aoc_erlang/ebin//aoc2019_day22.beam: The pattern "cut" on line 29 at column 23 doesn't have the type [0..1114111, ...]
_build/default/lib/aoc_erlang/ebin//aoc2019_day18.beam: Call to undefined function dijkstra:dijkstra/3 on line 40 at column 36
_build/default/lib/aoc_erlang/ebin//aoc2019_day18.beam: The operator '+' on line 85 at column 89 is expected to have type 0..255 which is too precise to be statically checked
_build/default/lib/aoc_erlang/ebin//aoc2019_day18.beam: The operator '+' on line 121 at column 59 is expected to have type 0..255 which is too precise to be statically checked
_build/default/lib/aoc_erlang/ebin//aoc2015_day07.beam: The pattern {WireA, '->', WireB} on line 64 at column 11 doesn't have the type {atom_or_int()}
_build/default/lib/aoc_erlang/ebin//aoc2016_day24.beam: The operator '++' on line 50 at column 47 is expected to have type _TyVar-576460752303423227 which is too precise to be statically checked
_build/default/lib/aoc_erlang/ebin//aoc2016_day24.beam: Call to undefined function astar2:astar/5 on line 85 at column 11
_build/default/lib/aoc_erlang/ebin//aoc2016_day04.beam: The function call on line 46 at column 32 is expected to have type pos_integer() but it has type non_neg_integer()
end,
Str),
lists:sublist(EncrName, 1, length(EncrName) - 1).
^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2017_day01.beam: The pattern [X, X | Xs] on line 73 at column 9 does not have type:
[]
_build/default/lib/aoc_erlang/ebin//aoc2017_day01.beam: Nonexhaustive patterns on line 79 at column 1
Example values which are not covered:
[]
_build/default/lib/aoc_erlang/ebin//aoc2020_day01.beam: The variable on line 43 at column 19 is expected to have type [T, ...] but it has type [integer()]
-spec solve2(Input :: input_type()) -> result2_type().
solve2(Input) ->
Min = lists:min(Input),
^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2016_day12.beam: The pattern [A, B] on line 28 at column 26 does not have type:
[]
_build/default/lib/aoc_erlang/ebin//aoc2016_day12.beam: The pattern #{a := A} on line 40 at column 5 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2016_day12.beam: The pattern #{a := A} on line 45 at column 5 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2020_day18_part1_parser.beam: The variable on line 234 at column 22 is expected to have type [A, ...] but it has type any() | []
[_, _ | Nss] = Ss,
NewStack = yeccpars2_5_(Stack),
yeccgoto_expr(hd(Nss), Cat, Nss, NewStack, T, Ts, Tzr).
^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day18_part1_parser.beam: The variable on line 239 at column 22 is expected to have type [A, ...] but it has type any() | []
[_, _ | Nss] = Ss,
NewStack = yeccpars2_8_(Stack),
yeccgoto_expr(hd(Nss), Cat, Nss, NewStack, T, Ts, Tzr).
^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day18_part1_parser.beam: The variable on line 244 at column 22 is expected to have type [A, ...] but it has type any() | []
[_, _ | Nss] = Ss,
NewStack = yeccpars2_9_(Stack),
yeccgoto_expr(hd(Nss), Cat, Nss, NewStack, T, Ts, Tzr).
^^^
_build/default/lib/aoc_erlang/ebin//aoc2018_day07.beam: The pattern "Step" on line 27 at column 17 doesn't have the type [0..1114111, ...]
_build/default/lib/aoc_erlang/ebin//aoc2019_day02.beam: Undefined remote type intcode:intcode_program/0 on line 21 at column 12
_build/default/lib/aoc_erlang/ebin//aoc2019_day02.beam: Undefined remote type intcode:intcode_program/0 on line 25 at column 13
_build/default/lib/aoc_erlang/ebin//aoc2019_day02.beam: Undefined remote type intcode:intcode_program/0 on line 29 at column 13
_build/default/lib/aoc_erlang/ebin//aoc2019_day02.beam: Call to undefined function intcode:execute/1 on line 38 at column 16
_build/default/lib/aoc_erlang/ebin//aoc2019_day09.beam: Undefined remote type intcode:intcode_program/0 on line 20 at column 12
_build/default/lib/aoc_erlang/ebin//aoc2019_day09.beam: Undefined remote type intcode:intcode_program/0 on line 24 at column 13
_build/default/lib/aoc_erlang/ebin//aoc2019_day09.beam: Undefined remote type intcode:intcode_program/0 on line 29 at column 13
_build/default/lib/aoc_erlang/ebin//aoc2016_day23.beam: The pattern #{a := A} on line 32 at column 5 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2016_day23.beam: The pattern 0 on line 57 at column 11 doesn't have the type pos_integer()
_build/default/lib/aoc_erlang/ebin//aoc2020_day18_part2_parser.beam: The variable on line 234 at column 22 is expected to have type [A, ...] but it has type any() | []
[_, _ | Nss] = Ss,
NewStack = yeccpars2_5_(Stack),
yeccgoto_expr(hd(Nss), Cat, Nss, NewStack, T, Ts, Tzr).
^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day18_part2_parser.beam: The variable on line 239 at column 22 is expected to have type [A, ...] but it has type any() | []
[_, _ | Nss] = Ss,
NewStack = yeccpars2_8_(Stack),
yeccgoto_expr(hd(Nss), Cat, Nss, NewStack, T, Ts, Tzr).
^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day18_part2_parser.beam: The variable on line 246 at column 22 is expected to have type [A, ...] but it has type any() | []
[_, _ | Nss] = Ss,
NewStack = yeccpars2_9_(Stack),
yeccgoto_expr(hd(Nss), Cat, Nss, NewStack, T, Ts, Tzr).
^^^
_build/default/lib/aoc_erlang/ebin//aoc2019_day25.beam: Undefined remote type intcode:intcode_program/0 on line 26 at column 12
_build/default/lib/aoc_erlang/ebin//aoc2019_day25.beam: Undefined remote type intcode:intcode_program/0 on line 30 at column 12
_build/default/lib/aoc_erlang/ebin//aoc2019_day25.beam: The operator '++' on line 96 at column 24 is expected to have type _TyVar-576460752303423484 which is too precise to be statically checked
_build/default/lib/aoc_erlang/ebin//aoc2019_day05.beam: Undefined remote type intcode:intcode_program/0 on line 21 at column 12
_build/default/lib/aoc_erlang/ebin//aoc2019_day05.beam: Undefined remote type intcode:intcode_program/0 on line 25 at column 13
_build/default/lib/aoc_erlang/ebin//aoc2019_day05.beam: Undefined remote type intcode:intcode_program/0 on line 29 at column 13
_build/default/lib/aoc_erlang/ebin//aoc2019_day05.beam: Call to undefined function intcode:execute/2 on line 34 at column 32
_build/default/lib/aoc_erlang/ebin//aoc_nifs.beam: The function call on line 12 at column 13 is expected to have type [0..1114111] but it has type file:filename_all()
filename:join("/Users/erszcz/work/jesperes/aoc_erlang/c_src",
"aoc_nifs.so"),
ok = erlang:load_nif(filename:rootname(File), 0).
^^^^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2019_day13.beam: Undefined remote type intcode:intcode_program/0 on line 22 at column 12
_build/default/lib/aoc_erlang/ebin//aoc2019_day13.beam: Undefined remote type intcode:intcode_program/0 on line 26 at column 13
_build/default/lib/aoc_erlang/ebin//aoc2019_day13.beam: Undefined remote type intcode:intcode_program/0 on line 30 at column 13
_build/default/lib/aoc_erlang/ebin//aoc2019_day13.beam: Call to undefined function intcode:execute/1 on line 42 at column 26
_build/default/lib/aoc_erlang/ebin//aoc2019_day13.beam: Call to undefined function intcode:execute/4 on line 65 at column 16
_build/default/lib/aoc_erlang/ebin//aoc2016_day15.beam: The pattern "Disc" on line 77 at column 6 doesn't have the type [0..1114111, ...]
_build/default/lib/aoc_erlang/ebin//aoc2020_day06.beam: The function call on line 31 at column 3 is expected to have type input_type() but it has type [unicode:chardata()]
-spec parse(Input :: binary()) -> input_type().
parse(Input) ->
string:split(string:trim(binary_to_list(Input)),
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
"\n\n",
^^^^^^^
all).
^^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day06.beam: The function call on line 35 at column 3 is expected to have type result1_type() but it has type number()
-spec solve1(Input :: input_type()) -> result1_type().
solve1(Input) ->
lists:sum(lists:map(fun num_yes_answers/1, Input)).
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day06.beam: The function call on line 39 at column 3 is expected to have type result2_type() but it has type number()
-spec solve2(Input :: input_type()) -> result2_type().
solve2(Input) ->
lists:sum(lists:map(fun all_yes_answers/1, Input)).
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day06.beam: The variable on line 56 at column 37 is expected to have type [Element] but it has type <<_:_*8>> |
maybe_improper_list(char() | unicode_binary() | charlist(),
unicode_binary() | [])
sets:intersection(Acc, sets:from_list(Group))
end,
sets:from_list(First),
^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2017_day10.beam: The variable on line 62 at column 28 is expected to have type pos_integer() but it has type non_neg_integer()
{A0, B0} = lists:split(Length, L0),
L1 = lists:reverse(A0) ++ B0,
{A1, B1} = lists:split(ListLen - Pos, L1),
^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day10.beam: The pattern #{3 := D3, 1 := D1} on line 56 at column 3 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2020_day10.beam: The variable on line 67 at column 22 is expected to have type [T, ...] but it has type [T]
solve2(List) ->
Adapters = lists:sort(List),
Device = lists:max(Adapters) + 3,
^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2015_day21.beam: The record patterns for record #combatant on line 61 at column 27 is expected to have type _TyVar-576460752303423420.
_build/default/lib/aoc_erlang/ebin//aoc2015_day21.beam: The record patterns for record #combatant on line 94 at column 27 is expected to have type _TyVar-576460752303423292.
_build/default/lib/aoc_erlang/ebin//aoc2017_day07.beam: The function call on line 75 at column 30 is expected to have type integer() but it has type number()
{Children, Weights} = lists:unzip(SubTreeWeights),
case deviant(Weights) of
undef -> Weight + lists:sum(Weights);
^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day07.beam: The variable on line 76 at column 40 is expected to have type [0..1114111] but it has type <<_:_*8>> |
maybe_improper_list(char() | unicode_binary() | charlist(),
unicode_binary() | [])
C2,
_] ->
{list_to_integer(N),
^
_build/default/lib/aoc_erlang/ebin//aoc2016_day14.beam: The variable on line 56 at column 27 is expected to have type [T, ...] but it has type any() | [T]
end,
case length(Keys0) of
L when L >= 64 -> lists:nth(64, Keys0);
^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2016_day14.beam: Call to undefined function aoc_nifs:digest_to_hexstring/1 on line 91 at column 13
_build/default/lib/aoc_erlang/ebin//aoc2015_day17.beam: The variable on line 35 at column 34 is expected to have type [T, ...] but it has type [T]
end,
BucketCombos),
MinLen = length(lists:nth(1, SortedOnLength)),
^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2016_day22.beam: The variable on line 161 at column 22 is expected to have type pos_integer() but it has type non_neg_integer()
size_to_num(Str) ->
L = length(Str),
case lists:split(L - 1, Str) of
^
_build/default/lib/aoc_erlang/ebin//aoc2016_day22.beam: The pattern "dev" on line 169 at column 6 doesn't have the type [0..1114111, ...]
_build/default/lib/aoc_erlang/ebin//aoc2019_day08.beam: The function call on line 49 at column 13 is expected to have type [T, ...] but it has type [B]
solve1(Binary) ->
{_, Ones, Twos} = lists:min(lists:map(fun (Layer) ->
^^^^^^^^^^^^^^^^^^^^^^^^
Fun = fun (N,
^^^^^^^^^^^^^
{N0, N1, N2} =
^^^^^^^^^^^^^^
Acc) ->
^^^^^^^
case
^^^^
binary:at(Binary,
^^^^^^^^^^^^^^^^^
N)
^^
of
^^
$0 ->
^^^^^
{N0 + 1,
^^^^^^^^
N1,
^^^
N2};
^^^^
$1 ->
^^^^^
{N0,
^^^^
N1 + 1,
^^^^^^^
N2};
^^^^
$2 ->
^^^^^
{N0,
^^^^
N1,
^^^
N2 +
^^^^
1};
^^^
_ -> Acc
^^^^^^^^
end
^^^
end,
^^^^
lists:foldl(Fun,
^^^^^^^^^^^^^^^^
{0, 0, 0},
^^^^^^^^^^
lists:seq(Layer *
^^^^^^^^^^^^^^^^^
150,
^^^^
(Layer +
^^^^^^^^
1)
^^
*
^
150
^^^
-
^
1))
^^^
end,
^^^^
layers())),
^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2019_day08.beam: The operator '++' on line 68 at column 76 is expected to have type _TyVar-576460752303423388 |
[A | [A | [A | [A | [A | [A | [A | deep_list(A)]]]]]]] which is too precise to be statically checked
_build/default/lib/aoc_erlang/ebin//aoc2020_day08.beam: The variable on line 45 at column 55 is expected to have type [0..1114111] but it has type <<_:_*8>> |
maybe_improper_list(char() | unicode_binary() | charlist(),
unicode_binary() | [])
{N + 1,
maps:put(N,
{list_to_atom(Instr),
^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2017_day08.beam: The pattern [Op1, Val1, "if", Reg2, Op2, Val2] on line 33 at column 38 doesn't have the type [[0..1114111, ...]] | []
_build/default/lib/aoc_erlang/ebin//aoc2018_day22.beam: Call to undefined function astar2:astar/5 on line 65 at column 27
_build/default/lib/aoc_erlang/ebin//aoc2018_day22.beam: The pattern #{max_x := MaxX} on line 91 at column 22 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2015_day14.beam: The pattern ["can",
"fly",
Speed,
"km/s",
"for",
Second,
"seconds",
"but",
"then",
"must",
"rest",
"for",
Rest,
"seconds"] on line 26 at column 19 doesn't have the type [[0..1114111, ...]] | []
_build/default/lib/aoc_erlang/ebin//aoc2015_day14.beam: The pattern #{current_state := rest,
speed := Speed,
fly_time := FlyTime,
distance := Dist,
remaining_time := 0} on line 99 at column 23 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2016_day21.beam: The operator '-' on line 93 at column 32 is expected to have type pos_integer() which is too precise to be statically checked
_build/default/lib/aoc_erlang/ebin//bfs.beam: The record patterns for record #state on line 53 at column 24 is expected to have type Acc.
_build/default/lib/aoc_erlang/ebin//aoc2015_day22.beam: The pattern #{mana_spent := ManaSpent} on line 73 at column 11 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2015_day22.beam: The pattern #{effects := Effects, mana := Mana} on line 122 at column 5 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2020_day12.beam: The pattern "N" on line 62 at column 17 doesn't have the type [none()]
_build/default/lib/aoc_erlang/ebin//aoc2020_day04.beam: The variable on line 39 at column 45 is expected to have type [0..1114111] but it has type <<_:_*8>> |
maybe_improper_list(char() | unicode_binary() | charlist(),
unicode_binary() | [])
":",
all),
KA = list_to_atom(K),
^
_build/default/lib/aoc_erlang/ebin//aoc2020_day04.beam: The pattern #{byr := Byr,
iyr := Iyr,
eyr := Eyr,
ecl := Ecl,
hgt := Hgt,
hcl := Hcl,
pid := Pid} on line 84 at column 17 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2016_day17.beam: Call to undefined function astar2:astar/5 on line 39 at column 11
_build/default/lib/aoc_erlang/ebin//aoc2019_day11.beam: Undefined remote type intcode:intcode_program/0 on line 41 at column 12
_build/default/lib/aoc_erlang/ebin//aoc2019_day11.beam: Undefined remote type intcode:intcode_program/0 on line 45 at column 13
_build/default/lib/aoc_erlang/ebin//aoc2019_day11.beam: Undefined remote type intcode:intcode_program/0 on line 63 at column 13
_build/default/lib/aoc_erlang/ebin//aoc2019_day11.beam: The variable on line 98 at column 30 is expected to have type [T, ...] but it has type [B]
|| X <- lists:seq(lists:min(Xs), lists:max(Xs))]
++ "\n"
|| Y <- lists:seq(lists:min(Ys), lists:max(Ys))].
^^
_build/default/lib/aoc_erlang/ebin//aoc2019_day07.beam: Undefined remote type intcode:intcode_program/0 on line 24 at column 12
_build/default/lib/aoc_erlang/ebin//aoc2019_day07.beam: Undefined remote type intcode:intcode_program/0 on line 28 at column 13
_build/default/lib/aoc_erlang/ebin//aoc2019_day07.beam: Undefined remote type intcode:intcode_program/0 on line 32 at column 13
_build/default/lib/aoc_erlang/ebin//aoc2019_day07.beam: Call to undefined function intcode:execute/2 on line 41 at column 28
_build/default/lib/aoc_erlang/ebin//aoc2019_day07.beam: Call to undefined function intcode:execute/4 on line 88 at column 16
_build/default/lib/aoc_erlang/ebin//aoc2019_day07.beam: The variable on line 127 at column 29 is expected to have type [T, ...] but it has type [B]
lists:foreach(fun (Pid) -> Pid ! start end, Pids),
A ! 0,
LastAmpPid = lists:last(Pids),
^^^^
_build/default/lib/aoc_erlang/ebin//aoc2019_day06.beam: The function call on line 28 at column 9 is expected to have type [0..1114111] but it has type unicode:chardata()
parse(Binary) ->
string:tokens(string:trim(binary_to_list(Binary)),
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2019_day06.beam: The function call on line 33 at column 5 is expected to have type result_type() but it has type number()
solve1(Input) ->
Graph = make_digraph(Input, [acyclic]),
sum_of_orbits(Graph).
^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2019_day06.beam: The function call on line 60 at column 34 is expected to have type [any()] but it has type [vertex(), ...] | false
sum_of_orbits(Graph) ->
lists:sum(lists:map(fun ('COM') -> 0;
(V) -> length(digraph:get_path(Graph, V, 'COM')) - 1
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2019_day06.beam: The function call on line 66 at column 12 is expected to have type [any()] but it has type [vertex(), ...] | false
-spec orbital_dist(digraph:graph()) -> integer().
orbital_dist(Graph) ->
length(digraph:get_path(Graph, 'YOU', 'SAN')) - 3.
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2018_day15.beam: The function call on line 126 at column 21 is expected to have type [T, ...] but it has type [B]
[] -> Grid;
_ ->
MinHP = lists:min(lists:map(fun ({_, {_, HP, _, _}}) ->
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
HP
^^
end,
^^^^
EnemiesInRange)),
^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2018_day15.beam: The record update on line 293 at column 58 is expected to have type Acc but it has type #search{}
Adj},
Acc#search.open),
Acc#search{open
^^^^^^^^^^^^^^^
=
^
Open1}
^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2019_day10.beam: The variable on line 125 at column 41 is expected to have type non_neg_integer() but it has type integer()
fun () ->
X__X = $\n,
case binary:at(Binary, Width) of
^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day05.beam: The variable on line 42 at column 6 is expected to have type [A, ...] but it has type [integer()]
solve1(Input) -> hd(Input).
^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2015_day23.beam: The pattern #{pc := PC} on line 43 at column 23 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2015_day23.beam: The pattern #{pc := PC} on line 79 at column 18 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2018_day19.beam: The function call on line 36 at column 5 is expected to have type result_type() but it has type number()
solve2(_Input) ->
Factors = start2(1, magic_number(), []),
lists:sum(Factors).
^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2018_day19.beam: The pattern "#ip" on line 53 at column 6 doesn't have the type [0..1114111, ...]
_build/default/lib/aoc_erlang/ebin//aoc_puzzle.beam: Call to undefined function aoc_puzzle:solve/2 on line 79 at column 27
_build/default/lib/aoc_erlang/ebin//aoc_puzzle.beam: Call to undefined function aoc_puzzle:run_puzzle/1 on line 98 at column 58
_build/default/lib/aoc_erlang/ebin//aoc2015_day03.beam: Nonexhaustive patterns on line 56 at column 1
Example values which are not covered:
0
{0, 0}
_build/default/lib/aoc_erlang/ebin//aoc2015_day15.beam: The pattern ["capacity",
Cap,
"durability",
Dur,
"flavor",
Flavor,
"texture",
Texture,
"calories",
Calories] on line 26 at column 21 doesn't have the type [[0..1114111, ...]] | []
_build/default/lib/aoc_erlang/ebin//aoc2015_day15.beam: The function call on line 58 at column 9 is expected to have type [T, ...] but it has type [B]
X3 <- lists:seq(1, 100), X4 <- lists:seq(1, 100),
X1 + X2 + X3 + X4 == 100],
lists:max(lists:map(fun (Amounts) ->
^^^^^^^^^^^^^^^^^^^^^^^^^^
score(Amounts, Ingredients)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
end,
^^^^
Combinations)).
^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2015_day15.beam: The function call on line 71 at column 9 is expected to have type [T, ...] but it has type [Elem | Value]
X3 <- lists:seq(1, 100), X4 <- lists:seq(1, 100),
X1 + X2 + X3 + X4 == 100],
lists:max(lists:filtermap(fun ({Score, Cal})
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
when Cal == 500 ->
^^^^^^^^^^^^^^^^^^
{true, Score};
^^^^^^^^^^^^^^
(_) -> false
^^^^^^^^^^^^
end,
^^^^
lists:map(fun (Amounts) ->
^^^^^^^^^^^^^^^^^^^^^^^^^^
score2(Amounts, Ingredients)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
end,
^^^^
Combinations))).
^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2018_day23.beam: The pattern "pos" on line 26 at column 19 doesn't have the type [0..1114111, ...]
_build/default/lib/aoc_erlang/ebin//aoc2018_day23.beam: The variable on line 33 at column 27 is expected to have type [T, ...] but it has type [{integer(), integer(), integer(), integer()}]
-spec solve1(Input :: input_type()) -> result_type().
solve1(NanoBots) ->
Strongest = lists:max(NanoBots),
^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day09.beam: The variable on line 102 at column 17 is expected to have type [T, ...] but it has type [T]
{Range, _} = lists:split(Len, List),
Sum = lists:sum(Range),
if Sum == Num -> lists:min(Range) + lists:max(Range);
^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2017_day09.beam: The function call on line 24 at column 5 is expected to have type input_type() but it has type unicode:chardata()
-spec parse(Binary :: binary()) -> input_type().
parse(Binary) -> string:trim(binary_to_list(Binary)).
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2015_day24.beam: The operator '++' on line 68 at column 23 is expected to have type _TyVar-576460752303423391 which is too precise to be statically checked
_build/default/lib/aoc_erlang/ebin//aoc2020_day14.beam: The variable on line 57 at column 44 is expected to have type [binary()] but it has type [[any()] |
[<<_:_*8>> |
[any()] |
maybe_improper_list(byte() | binary() | iolist(),
[] | binary())] |
[<<_:_*8>> |
[any()] |
maybe_improper_list(char() | unicode_binary() | charlist(),
unicode_binary() | [])]] |
[]
lists:filtermap(fun (Bin) ->
[First | Rest] = re:split(Bin, "\n", [multiline]),
Writes = parse_writes(filter_empty(Rest), []),
^^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day14.beam: The variable on line 95 at column 26 is expected to have type <<_:_*8>> but it has type <<_:_*8>> |
maybe_improper_list(char() | unicode_binary() | charlist(),
unicode_binary() | [])
"[] = "),
P = {write,
binary_to_integer(Addr),
^^^^
_build/default/lib/aoc_erlang/ebin//aoc2019_day17.beam: Undefined remote type intcode:intcode_program/0 on line 24 at column 12
_build/default/lib/aoc_erlang/ebin//aoc2019_day17.beam: Undefined remote type intcode:intcode_program/0 on line 28 at column 13
_build/default/lib/aoc_erlang/ebin//aoc2019_day17.beam: Undefined remote type intcode:intcode_program/0 on line 37 at column 13
_build/default/lib/aoc_erlang/ebin//grid.beam: The '++' expression on line 25 at column 23 is expected to have type 0..1114111 but it has type [any()]
MaxY = lists:max(YCoords),
header(MinX, MaxX) ++
[left_margin(Y) ++
^^^^^^^^^^^^^^^^^
[maps:get({X, Y}, Grid, 32)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
|| X <- lists:seq(MinX, MaxX)]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
++ "\n"
^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2018_day12.beam: The pattern "initial" on line 63 at column 4 doesn't have the type [0..1114111, ...]
_build/default/lib/aoc_erlang/ebin//inputs.beam: The function call on line 51 at column 17 is expected to have type atom() |
<<_:_*8>> |
[0..1114111] |
[0..1114111 | atom() | [0..1114111 | atom() | deep_list()]] but it has type file:filename() | {error, bad_name}
-spec get_input_dir() -> file:filename().
get_input_dir() ->
filename:join(code:priv_dir(aoc_erlang), "inputs").
^^^^^^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//inputs.beam: Timeout checking function get_input_filename/2 on line 55 at column 1
This is most likely a bug in Gradualizer.
Please report it at https://github.com/josefs/Gradualizer/issues
_build/default/lib/aoc_erlang/ebin//aoc2015_day08.beam: The operator '++' on line 36 at column 29 is expected to have type _TyVar-576460752303422878 which is too precise to be statically checked
_build/default/lib/aoc_erlang/ebin//aoc2019_day21.beam: Undefined remote type intcode:intcode_program/0 on line 22 at column 12
_build/default/lib/aoc_erlang/ebin//aoc2019_day21.beam: Undefined remote type intcode:intcode_program/0 on line 29 at column 13
_build/default/lib/aoc_erlang/ebin//aoc2019_day21.beam: Undefined remote type intcode:intcode_program/0 on line 35 at column 13
_build/default/lib/aoc_erlang/ebin//aoc2020_day18.beam: Call to undefined function aoc2020_day18_lexer:string/1 on line 72 at column 46
_build/default/lib/aoc_erlang/ebin//aoc2018_day24.beam: The pattern #{units := Units, damage := Damage} on line 111 at column 17 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2018_day24.beam: The pattern #{units := Units, hp := HP} on line 192 at column 13 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2015_day12.beam: Undefined remote type jsone:json_object/0 on line 22 at column 12
_build/default/lib/aoc_erlang/ebin//aoc2015_day12.beam: Undefined remote type jsone:json_object/0 on line 26 at column 13
_build/default/lib/aoc_erlang/ebin//aoc2015_day12.beam: Undefined remote type jsone:json_object/0 on line 30 at column 13
_build/default/lib/aoc_erlang/ebin//aoc2018_day08.beam: The function call on line 26 at column 15 is expected to have type [0..1114111] but it has type unicode:chardata()
parse(Input) ->
lists:map(fun list_to_integer/1,
string:tokens(string:trim(binary_to_list(Input)), " ")).
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2018_day08.beam: The operator '+' on line 42 at column 22 is expected to have type 0..1114111 which is too precise to be statically checked
_build/default/lib/aoc_erlang/ebin//aoc2015_day04.beam: The function call on line 31 at column 30 is expected to have type maybe_improper_list(0..255 |
<<_:_*8>> |
maybe_improper_list(byte() |
binary() |
iolist(),
[] | binary()),
<<_:_*8>> | []) but it has type string()
solve(Input, N, P1) ->
case erlang:md5(Input ++ integer_to_list(N)) of
^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2018_day09.beam: The function call on line 37 at column 13 is expected to have type [T, ...] but it has type [Value]
#{},
Last),
lists:max(maps:values(Scores)).
^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//intcode.beam: Call to undefined function intcode:parse/1 on line 39 at column 19
_build/default/lib/aoc_erlang/ebin//intcode.beam: The pattern {Inputs, Outputs} on line 84 at column 29 doesn't have the type integer()
_build/default/lib/aoc_erlang/ebin//aoc2015_day13.beam: The pattern ["would",
GainOrLose, Amount,
"happiness",
"units",
"by",
"sitting",
"next",
"to",
B] on line 26 at column 19 doesn't have the type [[0..1114111, ...]] | []
_build/default/lib/aoc_erlang/ebin//aoc2020_day23.beam: The operator '+' on line 83 at column 39 is requires numeric arguments, but has arguments of type Val | undefined and any()
_build/default/lib/aoc_erlang/ebin//aoc2018_day25.beam: The operator '++' on line 59 at column 65 is expected to have type _TyVar-576460752303423001 which is too precise to be statically checked
_build/default/lib/aoc_erlang/ebin//aoc2019_day20.beam: Call to undefined function dijkstra:dijkstra/3 on line 39 at column 36
_build/default/lib/aoc_erlang/ebin//aoc2019_day20.beam: Call to undefined function dijkstra:dijkstra/3 on line 47 at column 36
_build/default/lib/aoc_erlang/ebin//aoc2019_day20.beam: The variable on line 212 at column 22 is expected to have type [T, ...] but it has type [A]
end,
Map))),
MaxX = lists:max(XCoords),
^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2015_day09.beam: The pattern ["to", To, "=", Dist] on line 25 at column 25 doesn't have the type [[0..1114111, ...]] | []
_build/default/lib/aoc_erlang/ebin//aoc2018_day13.beam: The variable on line 113 at column 20 is expected to have type [any()] but it has type <<_:_*8>> |
maybe_improper_list(char() | unicode_binary() | charlist(),
unicode_binary() | [])
Str = binary_to_list(Binary),
[First | _] = string:split(Str, "\n"),
Width = length(First),
^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2018_day05.beam: The function call on line 24 at column 5 is expected to have type input_type() but it has type unicode:chardata()
-spec parse(Input :: binary()) -> input_type().
parse(Input) -> string:trim(binary_to_list(Input)).
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2018_day05.beam: The variable on line 36 at column 11 is expected to have type string() but it has type [integer()]
-spec react([integer()]) -> [integer()].
react(L) -> react(L, []).
^
_build/default/lib/aoc_erlang/ebin//aoc2019_day16.beam: The function call on line 24 at column 5 is expected to have type input_type() but it has type unicode:chardata()
-spec parse(Binary :: binary()) -> input_type().
parse(Binary) -> string:trim(binary_to_list(Binary)).
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2019_day16.beam: The variable on line 79 at column 31 is expected to have type non_neg_integer() but it has type integer()
{S, _} = lists:split(7, String),
Offset = list_to_integer(S),
{_, Digits} = lists:split(Offset,
^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2016_day10.beam: The variable on line 88 at column 39 is expected to have type [0..1114111] but it has type <<_:_*8>> |
maybe_improper_list(char() | unicode_binary() | charlist(),
unicode_binary() | [])
"value" ->
[Value, "goes", "to", "bot", Bot] = Rest,
{goes_to, list_to_integer(Value), list_to_integer(Bot)};
^^^^^
_build/default/lib/aoc_erlang/ebin//aoc_erlang.beam: Call to undefined function aoc_puzzle:info/1 on line 8 at column 37
_build/default/lib/aoc_erlang/ebin//aoc2020_day03.beam: The operator 'rem' on line 55 at column 23 is expected to have type pos_integer() which is too precise to be statically checked
_build/default/lib/aoc_erlang/ebin//aoc2017_day03.beam: The function call on line 164 at column 28 is expected to have type [T, ...] but it has type [Key]
spiralmemory2_get_latest_value(SM = {_, Map, _}) ->
LargestIndex = lists:max(maps:keys(Map)),
^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2016_day06.beam: The variable on line 44 at column 37 is expected to have type [T, ...] but it has type [Value]
Words),
Freqs = maps:values(FM),
[MinChar] = find_keys(lists:min(Freqs), FM),
^^^^^
# Steps to reproduce
git clone git@github.com:erszcz/aoc_erlang.git
cd aoc_erlang
git checkout gradualizer
(~/work/erszcz/gradualizer/bin/gradualizer.erszcz-master --version; for beam in $(find _build/default/lib/aoc_erlang/ebin/ -name \*.beam); do ~/work/erszcz/gradualizer/bin/gradualizer.erszcz-master -I include -- $beam; done) | tee erszcz-master.log
(~/work/erszcz/gradualizer/bin/gradualizer.upstream-master --version; for beam in $(find _build/default/lib/aoc_erlang/ebin/ -name \*.beam); do ~/work/erszcz/gradualizer/bin/gradualizer.upstream-master -I include -- $beam; done) | tee upstream-master.log
Gradualizer v0.1.3-108-g5be0f94
_build/default/lib/aoc_erlang/ebin//aoc2019_day03.beam: Nonexhaustive patterns on line 35 at column 1
Example values which are not covered:
[]
_build/default/lib/aoc_erlang/ebin//aoc2019_day03.beam: The function call on line 62 at column 9 is expected to have type [T, ...] but it has type [B]
map_smallest(Fun, List) ->
lists:min(lists:map(Fun, List)).
^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2018_day10.beam: The pattern "position" on line 42 at column 19 doesn't have the type [char(), ...]
_build/default/lib/aoc_erlang/ebin//aoc2018_day06.beam: The clause on line 78 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2018_day06.beam: The clause on line 88 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2019_day15.beam: Call to undefined function intcode:parse/1 on line 29 at column 12
_build/default/lib/aoc_erlang/ebin//aoc2019_day15.beam: The variable on line 57 at column 23 is expected to have type [T, ...] but it has type [Elem | Value]
end,
maps:to_list(Grid1)),
{Dist0, lists:max(OxygenDists)}.
^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2019_day15.beam: Call to undefined function intcode:execute/4 on line 62 at column 21
_build/default/lib/aoc_erlang/ebin//aoc2016_day13.beam: Call to undefined function astar2:astar/5 on line 36 at column 15
_build/default/lib/aoc_erlang/ebin//aoc2020_day16.beam: The variable on line 116 at column 44 is expected to have type [T, ...] but it has type [integer()]
lists:foldl(fun erlang:'*'/2,
1,
lists:map(fun (Pos) -> lists:nth(Pos, MyTicket) end,
^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day16.beam: The pattern #{fields := Fields, myticket := MyTicket, nearbytickets := Tickets} on line 129 at column 19 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2016_day05.beam: The function call on line 72 at column 25 is expected to have type maybe_improper_list(0..255 |
<<_:_*8>> |
maybe_improper_list(byte() |
binary() |
iolist(),
[] | binary()),
<<_:_*8>> | []) but it has type string()
hash(Input, Index) ->
erlang:md5(Input ++ integer_to_list(Index)).
^^^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2016_day25.beam: The clause on line 88 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2015_day06.beam: The pattern "toggle" on line 31 at column 27 doesn't have the type [char(), ...]
_build/default/lib/aoc_erlang/ebin//aoc2015_day06.beam: The clause on line 53 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2015_day06.beam: Nonexhaustive patterns on line 87 at column 22
Example values which are not covered:
-1
_build/default/lib/aoc_erlang/ebin//aoc2019_day19.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day19.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day19.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day19.beam: Call to undefined function intcode:execute/2 on line 44 at column 23
_build/default/lib/aoc_erlang/ebin//aoc2020_day20.beam: The variable on line 308 at column 32 is expected to have type [A, ...] but it has type [[<<_:_*8>> |
[char()] |
{error, string(), binary()} |
{incomplete, string(), binary()} |
{integer(), integer()}]] |
[<<_:_*8>> |
[char()] |
{error, string(), binary()} |
{incomplete, string(), binary()} |
{integer(), integer()}]
"(\\d+):",
[{capture, all_but_first, list}]),
TileNum = list_to_integer(hd(Matches)),
^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2019_day23.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day23.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day23.beam: Call to undefined function intcode:execute/4 on line 80 at column 12
_build/default/lib/aoc_erlang/ebin//aoc2016_day09.beam: The clause on line 37 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2016_day09.beam: The clause on line 55 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2016_day08.beam: The function call on line 40 at column 28 is expected to have type pos_integer() but it has type non_neg_integer()
rotate(X, N) ->
{L1, L2} = lists:split(length(X) - N rem length(X), X),
^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2016_day08.beam: The function call on line 80 at column 47 is expected to have type pos_integer() but it has type non_neg_integer()
lists:sublist(Display,
Height + 1,
length(Display) - Height),
^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2016_day08.beam: The variable on line 122 at column 23 is expected to have type [char()] but it has type <<_:_*8>> |
maybe_improper_list(char() | unicode_binary() | charlist(),
unicode_binary() | [])
decode_instr(Instr) ->
[Op | Rest] = string:lexemes(Instr, " "),
case list_to_atom(Op) of
^^
_build/default/lib/aoc_erlang/ebin//aoc2019_day22.beam: The pattern "cut" on line 29 at column 23 doesn't have the type [char(), ...]
_build/default/lib/aoc_erlang/ebin//aoc2019_day18.beam: Call to undefined function dijkstra:dijkstra/3 on line 40 at column 36
_build/default/lib/aoc_erlang/ebin//aoc2019_day18.beam: The operator '+' on line 85 at column 89 is expected to have type 0..255 which is too precise to be statically checked
_build/default/lib/aoc_erlang/ebin//aoc2019_day18.beam: The operator '+' on line 121 at column 59 is expected to have type 0..255 which is too precise to be statically checked
_build/default/lib/aoc_erlang/ebin//aoc2015_day11.beam: The clause on line 45 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2015_day07.beam: The pattern {WireA, '->', WireB} on line 64 at column 11 doesn't have the type {atom_or_int()}
_build/default/lib/aoc_erlang/ebin//aoc2016_day24.beam: The operator '++' on line 50 at column 47 is expected to have type _TyVar-576460752303423228 which is too precise to be statically checked
_build/default/lib/aoc_erlang/ebin//aoc2016_day24.beam: Call to undefined function astar2:astar/5 on line 85 at column 11
_build/default/lib/aoc_erlang/ebin//aoc2016_day04.beam: The function call on line 46 at column 32 is expected to have type pos_integer() but it has type non_neg_integer()
end,
Str),
lists:sublist(EncrName, 1, length(EncrName) - 1).
^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2016_day04.beam: The clause on line 70 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2016_day04.beam: The clause on line 81 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2017_day01.beam: The pattern [X, X | Xs] on line 73 at column 9 does not have type:
[]
_build/default/lib/aoc_erlang/ebin//aoc2017_day01.beam: Nonexhaustive patterns on line 79 at column 1
Example values which are not covered:
[]
_build/default/lib/aoc_erlang/ebin//aoc2017_day01.beam: The clause on line 86 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2020_day01.beam: The variable on line 43 at column 19 is expected to have type [T, ...] but it has type [integer()]
-spec solve2(Input :: input_type()) -> result2_type().
solve2(Input) ->
Min = lists:min(Input),
^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2016_day12.beam: The pattern [A, B] on line 28 at column 26 does not have type:
[]
_build/default/lib/aoc_erlang/ebin//aoc2016_day12.beam: The pattern #{a := A} on line 40 at column 5 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2016_day12.beam: The pattern #{a := A} on line 45 at column 5 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2020_day18_part1_parser.beam: The clause on line 90 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2020_day18_part1_parser.beam: The clause on line 119 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2020_day18_part1_parser.beam: The variable on line 234 at column 22 is expected to have type [A, ...] but it has type any() | []
[_, _ | Nss] = Ss,
NewStack = yeccpars2_5_(Stack),
yeccgoto_expr(hd(Nss), Cat, Nss, NewStack, T, Ts, Tzr).
^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day18_part1_parser.beam: The variable on line 239 at column 22 is expected to have type [A, ...] but it has type any() | []
[_, _ | Nss] = Ss,
NewStack = yeccpars2_8_(Stack),
yeccgoto_expr(hd(Nss), Cat, Nss, NewStack, T, Ts, Tzr).
^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day18_part1_parser.beam: The variable on line 244 at column 22 is expected to have type [A, ...] but it has type any() | []
[_, _ | Nss] = Ss,
NewStack = yeccpars2_9_(Stack),
yeccgoto_expr(hd(Nss), Cat, Nss, NewStack, T, Ts, Tzr).
^^^
_build/default/lib/aoc_erlang/ebin//aoc2018_day07.beam: The pattern "Step" on line 27 at column 17 doesn't have the type [char(), ...]
_build/default/lib/aoc_erlang/ebin//aoc2019_day02.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day02.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day02.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day02.beam: Call to undefined function intcode:execute/1 on line 38 at column 16
_build/default/lib/aoc_erlang/ebin//aoc2019_day09.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day09.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day09.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2016_day23.beam: The pattern #{a := A} on line 32 at column 5 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2016_day23.beam: The pattern 0 on line 57 at column 11 doesn't have the type pos_integer()
_build/default/lib/aoc_erlang/ebin//aoc2016_day23.beam: The clause on line 76 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2020_day18_part2_parser.beam: The clause on line 90 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2020_day18_part2_parser.beam: The clause on line 119 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2020_day18_part2_parser.beam: The variable on line 234 at column 22 is expected to have type [A, ...] but it has type any() | []
[_, _ | Nss] = Ss,
NewStack = yeccpars2_5_(Stack),
yeccgoto_expr(hd(Nss), Cat, Nss, NewStack, T, Ts, Tzr).
^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day18_part2_parser.beam: The variable on line 239 at column 22 is expected to have type [A, ...] but it has type any() | []
[_, _ | Nss] = Ss,
NewStack = yeccpars2_8_(Stack),
yeccgoto_expr(hd(Nss), Cat, Nss, NewStack, T, Ts, Tzr).
^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day18_part2_parser.beam: The variable on line 246 at column 22 is expected to have type [A, ...] but it has type any() | []
[_, _ | Nss] = Ss,
NewStack = yeccpars2_9_(Stack),
yeccgoto_expr(hd(Nss), Cat, Nss, NewStack, T, Ts, Tzr).
^^^
_build/default/lib/aoc_erlang/ebin//aoc2018_day20.beam: The clause on line 54 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2018_day20.beam: The clause on line 63 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2019_day25.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day25.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day25.beam: The operator '++' on line 96 at column 24 is expected to have type _TyVar-576460752303423484 which is too precise to be statically checked
_build/default/lib/aoc_erlang/ebin//aoc2019_day05.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day05.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day05.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day05.beam: Call to undefined function intcode:execute/2 on line 34 at column 32
_build/default/lib/aoc_erlang/ebin//aoc2018_day16.beam: The clause on line 202 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2018_day16.beam: The clause on line 209 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc_nifs.beam: The function call on line 12 at column 13 is expected to have type [char()] but it has type file:filename_all()
filename:join("/Users/erszcz/work/jesperes/aoc_erlang/c_src",
"aoc_nifs.so"),
ok = erlang:load_nif(filename:rootname(File), 0).
^^^^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2019_day13.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day13.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day13.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day13.beam: Call to undefined function intcode:execute/1 on line 42 at column 26
_build/default/lib/aoc_erlang/ebin//aoc2019_day13.beam: The clause on line 49 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2019_day13.beam: Call to undefined function intcode:execute/4 on line 65 at column 16
_build/default/lib/aoc_erlang/ebin//aoc2016_day15.beam: The pattern "Disc" on line 77 at column 6 doesn't have the type [char(), ...]
_build/default/lib/aoc_erlang/ebin//aoc2020_day06.beam: The function call on line 31 at column 3 is expected to have type input_type() but it has type [unicode:chardata()]
-spec parse(Input :: binary()) -> input_type().
parse(Input) ->
string:split(string:trim(binary_to_list(Input)),
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
"\n\n",
^^^^^^^
all).
^^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day06.beam: The function call on line 35 at column 3 is expected to have type result1_type() but it has type number()
-spec solve1(Input :: input_type()) -> result1_type().
solve1(Input) ->
lists:sum(lists:map(fun num_yes_answers/1, Input)).
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day06.beam: The function call on line 39 at column 3 is expected to have type result2_type() but it has type number()
-spec solve2(Input :: input_type()) -> result2_type().
solve2(Input) ->
lists:sum(lists:map(fun all_yes_answers/1, Input)).
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day06.beam: The variable on line 56 at column 37 is expected to have type [Element] but it has type <<_:_*8>> |
maybe_improper_list(char() | unicode_binary() | charlist(),
unicode_binary() | [])
sets:intersection(Acc, sets:from_list(Group))
end,
sets:from_list(First),
^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2017_day10.beam: The clause on line 51 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2017_day10.beam: The variable on line 62 at column 28 is expected to have type pos_integer() but it has type non_neg_integer()
{A0, B0} = lists:split(Length, L0),
L1 = lists:reverse(A0) ++ B0,
{A1, B1} = lists:split(ListLen - Pos, L1),
^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day10.beam: The pattern #{3 := D3, 1 := D1} on line 56 at column 3 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2020_day10.beam: The variable on line 67 at column 22 is expected to have type [T, ...] but it has type [T]
solve2(List) ->
Adapters = lists:sort(List),
Device = lists:max(Adapters) + 3,
^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day18_lexer.beam: The clause on line 292 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2015_day21.beam: The record patterns for record #combatant on line 61 at column 27 is expected to have type _TyVar-576460752303423420.
_build/default/lib/aoc_erlang/ebin//aoc2015_day21.beam: The record patterns for record #combatant on line 94 at column 27 is expected to have type _TyVar-576460752303423292.
_build/default/lib/aoc_erlang/ebin//aoc2017_day07.beam: The function call on line 75 at column 30 is expected to have type integer() but it has type number()
{Children, Weights} = lists:unzip(SubTreeWeights),
case deviant(Weights) of
undef -> Weight + lists:sum(Weights);
^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day07.beam: The variable on line 76 at column 40 is expected to have type [char()] but it has type <<_:_*8>> |
maybe_improper_list(char() | unicode_binary() | charlist(),
unicode_binary() | [])
C2,
_] ->
{list_to_integer(N),
^
_build/default/lib/aoc_erlang/ebin//aoc2016_day14.beam: The variable on line 56 at column 27 is expected to have type [T, ...] but it has type any() | [T]
end,
case length(Keys0) of
L when L >= 64 -> lists:nth(64, Keys0);
^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2016_day14.beam: Call to undefined function aoc_nifs:digest_to_hexstring/1 on line 91 at column 13
_build/default/lib/aoc_erlang/ebin//aoc2018_day17.beam: The clause on line 77 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2015_day17.beam: The variable on line 35 at column 34 is expected to have type [T, ...] but it has type [T]
end,
BucketCombos),
MinLen = length(lists:nth(1, SortedOnLength)),
^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2016_day22.beam: The variable on line 161 at column 22 is expected to have type pos_integer() but it has type non_neg_integer()
size_to_num(Str) ->
L = length(Str),
case lists:split(L - 1, Str) of
^
_build/default/lib/aoc_erlang/ebin//aoc2016_day22.beam: The pattern "dev" on line 169 at column 6 doesn't have the type [char(), ...]
_build/default/lib/aoc_erlang/ebin//aoc2019_day08.beam: The function call on line 49 at column 13 is expected to have type [T, ...] but it has type [B]
solve1(Binary) ->
{_, Ones, Twos} = lists:min(lists:map(fun (Layer) ->
^^^^^^^^^^^^^^^^^^^^^^^^
Fun = fun (N,
^^^^^^^^^^^^^
{N0, N1, N2} =
^^^^^^^^^^^^^^
Acc) ->
^^^^^^^
case
^^^^
binary:at(Binary,
^^^^^^^^^^^^^^^^^
N)
^^
of
^^
$0 ->
^^^^^
{N0 + 1,
^^^^^^^^
N1,
^^^
N2};
^^^^
$1 ->
^^^^^
{N0,
^^^^
N1 + 1,
^^^^^^^
N2};
^^^^
$2 ->
^^^^^
{N0,
^^^^
N1,
^^^
N2 +
^^^^
1};
^^^
_ -> Acc
^^^^^^^^
end
^^^
end,
^^^^
lists:foldl(Fun,
^^^^^^^^^^^^^^^^
{0, 0, 0},
^^^^^^^^^^
lists:seq(Layer *
^^^^^^^^^^^^^^^^^
150,
^^^^
(Layer +
^^^^^^^^
1)
^^
*
^
150
^^^
-
^
1))
^^^
end,
^^^^
layers())),
^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2019_day08.beam: The operator '++' on line 68 at column 76 is expected to have type _TyVar-576460752303423386 | [A | [A | deep_list(A)]] which is too precise to be statically checked
_build/default/lib/aoc_erlang/ebin//aoc2019_day08.beam: The clause on line 80 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2020_day08.beam: The variable on line 45 at column 55 is expected to have type [char()] but it has type <<_:_*8>> |
maybe_improper_list(char() | unicode_binary() | charlist(),
unicode_binary() | [])
{N + 1,
maps:put(N,
{list_to_atom(Instr),
^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2017_day08.beam: The pattern [Op1, Val1, "if", Reg2, Op2, Val2] on line 33 at column 38 doesn't have the type [nonempty_string()] | []
_build/default/lib/aoc_erlang/ebin//aoc2018_day22.beam: Call to undefined function astar2:astar/5 on line 65 at column 27
_build/default/lib/aoc_erlang/ebin//aoc2018_day22.beam: The pattern #{max_x := MaxX} on line 91 at column 22 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2015_day14.beam: The pattern ["can",
"fly",
Speed,
"km/s",
"for",
Second,
"seconds",
"but",
"then",
"must",
"rest",
"for",
Rest,
"seconds"] on line 26 at column 19 doesn't have the type [nonempty_string()] | []
_build/default/lib/aoc_erlang/ebin//aoc2015_day14.beam: The pattern #{current_state := rest,
speed := Speed,
fly_time := FlyTime,
distance := Dist,
remaining_time := 0} on line 99 at column 23 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2018_day18.beam: The clause on line 83 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2016_day21.beam: The operator '-' on line 93 at column 32 is expected to have type pos_integer() which is too precise to be statically checked
_build/default/lib/aoc_erlang/ebin//bfs.beam: _build/default/lib/aoc_erlang/ebin//aoc2015_day22.beam: The pattern #{mana_spent := ManaSpent} on line 73 at column 11 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2015_day22.beam: The pattern #{effects := Effects, mana := Mana} on line 122 at column 5 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2020_day12.beam: The pattern "N" on line 62 at column 17 doesn't have the type [none()]
_build/default/lib/aoc_erlang/ebin//aoc2020_day04.beam: The variable on line 39 at column 45 is expected to have type [char()] but it has type <<_:_*8>> |
maybe_improper_list(char() | unicode_binary() | charlist(),
unicode_binary() | [])
":",
all),
KA = list_to_atom(K),
^
_build/default/lib/aoc_erlang/ebin//aoc2020_day04.beam: The pattern #{byr := Byr,
iyr := Iyr,
eyr := Eyr,
ecl := Ecl,
hgt := Hgt,
hcl := Hcl,
pid := Pid} on line 84 at column 17 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2016_day17.beam: Call to undefined function astar2:astar/5 on line 39 at column 11
_build/default/lib/aoc_erlang/ebin//aoc2019_day11.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day11.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day11.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day11.beam: The variable on line 98 at column 30 is expected to have type [T, ...] but it has type [B]
|| X <- lists:seq(lists:min(Xs), lists:max(Xs))]
++ "\n"
|| Y <- lists:seq(lists:min(Ys), lists:max(Ys))].
^^
_build/default/lib/aoc_erlang/ebin//aoc2018_day02.beam: The clause on line 72 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2018_day02.beam: The clause on line 79 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2019_day07.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day07.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day07.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day07.beam: Call to undefined function intcode:execute/2 on line 41 at column 28
_build/default/lib/aoc_erlang/ebin//aoc2019_day07.beam: Call to undefined function intcode:execute/4 on line 88 at column 16
_build/default/lib/aoc_erlang/ebin//aoc2019_day07.beam: The variable on line 127 at column 29 is expected to have type [T, ...] but it has type [B]
lists:foreach(fun (Pid) -> Pid ! start end, Pids),
A ! 0,
LastAmpPid = lists:last(Pids),
^^^^
_build/default/lib/aoc_erlang/ebin//aoc2019_day06.beam: The function call on line 28 at column 9 is expected to have type [char()] but it has type unicode:chardata()
parse(Binary) ->
string:tokens(string:trim(binary_to_list(Binary)),
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2019_day06.beam: The function call on line 33 at column 5 is expected to have type result_type() but it has type number()
solve1(Input) ->
Graph = make_digraph(Input, [acyclic]),
sum_of_orbits(Graph).
^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2019_day06.beam: The function call on line 60 at column 34 is expected to have type [term()] but it has type [vertex(), ...] | false
sum_of_orbits(Graph) ->
lists:sum(lists:map(fun ('COM') -> 0;
(V) -> length(digraph:get_path(Graph, V, 'COM')) - 1
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2019_day06.beam: The function call on line 66 at column 12 is expected to have type [term()] but it has type [vertex(), ...] | false
-spec orbital_dist(digraph:graph()) -> integer().
orbital_dist(Graph) ->
length(digraph:get_path(Graph, 'YOU', 'SAN')) - 3.
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2018_day15.beam: The function call on line 126 at column 21 is expected to have type [T, ...] but it has type [B]
[] -> Grid;
_ ->
MinHP = lists:min(lists:map(fun ({_, {_, HP, _, _}}) ->
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
HP
^^
end,
^^^^
EnemiesInRange)),
^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2018_day15.beam: The clause on line 224 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2018_day15.beam: _build/default/lib/aoc_erlang/ebin//aoc2015_day19.beam: The clause on line 89 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2019_day10.beam: The variable on line 125 at column 41 is expected to have type non_neg_integer() but it has type integer()
fun () ->
X__X = $\n,
case binary:at(Binary, Width) of
^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2016_day16.beam: The clause on line 39 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2016_day16.beam: The clause on line 65 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2020_day05.beam: The variable on line 42 at column 6 is expected to have type [A, ...] but it has type [integer()]
solve1(Input) -> hd(Input).
^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2015_day23.beam: The pattern #{pc := PC} on line 43 at column 23 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2015_day23.beam: The pattern #{pc := PC} on line 79 at column 18 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2015_day23.beam: The clause on line 84 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2018_day19.beam: The function call on line 36 at column 5 is expected to have type result_type() but it has type number()
solve2(_Input) ->
Factors = start2(1, magic_number(), []),
lists:sum(Factors).
^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2018_day19.beam: The pattern "#ip" on line 53 at column 6 doesn't have the type [char(), ...]
_build/default/lib/aoc_erlang/ebin//aoc_puzzle.beam: Call to undefined function aoc_puzzle:solve/2 on line 79 at column 27
_build/default/lib/aoc_erlang/ebin//aoc_puzzle.beam: Call to undefined function aoc_puzzle:run_puzzle/1 on line 98 at column 58
_build/default/lib/aoc_erlang/ebin//aoc2015_day03.beam: Nonexhaustive patterns on line 56 at column 1
Example values which are not covered:
0
{0, 0}
_build/default/lib/aoc_erlang/ebin//aoc2015_day15.beam: The pattern ["capacity",
Cap,
"durability",
Dur,
"flavor",
Flavor,
"texture",
Texture,
"calories",
Calories] on line 26 at column 21 doesn't have the type [nonempty_string()] | []
_build/default/lib/aoc_erlang/ebin//aoc2015_day15.beam: The function call on line 58 at column 9 is expected to have type [T, ...] but it has type [B]
X3 <- lists:seq(1, 100), X4 <- lists:seq(1, 100),
X1 + X2 + X3 + X4 == 100],
lists:max(lists:map(fun (Amounts) ->
^^^^^^^^^^^^^^^^^^^^^^^^^^
score(Amounts, Ingredients)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
end,
^^^^
Combinations)).
^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2015_day15.beam: The function call on line 71 at column 9 is expected to have type [T, ...] but it has type [Elem | Value]
X3 <- lists:seq(1, 100), X4 <- lists:seq(1, 100),
X1 + X2 + X3 + X4 == 100],
lists:max(lists:filtermap(fun ({Score, Cal})
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
when Cal == 500 ->
^^^^^^^^^^^^^^^^^^
{true, Score};
^^^^^^^^^^^^^^
(_) -> false
^^^^^^^^^^^^
end,
^^^^
lists:map(fun (Amounts) ->
^^^^^^^^^^^^^^^^^^^^^^^^^^
score2(Amounts, Ingredients)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
end,
^^^^
Combinations))).
^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2018_day23.beam: The pattern "pos" on line 26 at column 19 doesn't have the type [char(), ...]
_build/default/lib/aoc_erlang/ebin//aoc2018_day23.beam: The variable on line 33 at column 27 is expected to have type [T, ...] but it has type [{integer(), integer(), integer(), integer()}]
-spec solve1(Input :: input_type()) -> result_type().
solve1(NanoBots) ->
Strongest = lists:max(NanoBots),
^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day09.beam: The variable on line 102 at column 17 is expected to have type [T, ...] but it has type [T]
{Range, _} = lists:split(Len, List),
Sum = lists:sum(Range),
if Sum == Num -> lists:min(Range) + lists:max(Range);
^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2017_day09.beam: The function call on line 24 at column 5 is expected to have type input_type() but it has type unicode:chardata()
-spec parse(Binary :: binary()) -> input_type().
parse(Binary) -> string:trim(binary_to_list(Binary)).
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2017_day09.beam: The clause on line 40 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2017_day09.beam: The clause on line 50 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2016_day07.beam: The clause on line 42 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2016_day07.beam: The clause on line 54 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2015_day24.beam: The operator '++' on line 68 at column 23 is expected to have type _TyVar-576460752303423389 which is too precise to be statically checked
_build/default/lib/aoc_erlang/ebin//aoc2020_day14.beam: The variable on line 57 at column 44 is expected to have type [binary()] but it has type [[any()] |
[<<_:_*8>> |
[any()] |
maybe_improper_list(byte() | binary() | iolist(),
[] | binary())] |
[<<_:_*8>> |
[any()] |
maybe_improper_list(char() | unicode_binary() | charlist(),
unicode_binary() | [])]] |
[]
lists:filtermap(fun (Bin) ->
[First | Rest] = re:split(Bin, "\n", [multiline]),
Writes = parse_writes(filter_empty(Rest), []),
^^^^
_build/default/lib/aoc_erlang/ebin//aoc2020_day14.beam: The variable on line 95 at column 26 is expected to have type <<_:_*8>> but it has type <<_:_*8>> |
maybe_improper_list(char() | unicode_binary() | charlist(),
unicode_binary() | [])
"[] = "),
P = {write,
binary_to_integer(Addr),
^^^^
_build/default/lib/aoc_erlang/ebin//aoc2019_day17.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day17.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day17.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//grid.beam: The '++' expression on line 25 at column 23 is expected to have type 0..1114111 but it has type [any()]
MaxY = lists:max(YCoords),
header(MinX, MaxX) ++
[left_margin(Y) ++
^^^^^^^^^^^^^^^^^
[maps:get({X, Y}, Grid, 32)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
|| X <- lists:seq(MinX, MaxX)]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
++ "\n"
^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2018_day04.beam: The clause on line 94 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2018_day12.beam: The pattern "initial" on line 63 at column 4 doesn't have the type [char(), ...]
_build/default/lib/aoc_erlang/ebin//inputs.beam: The function call on line 51 at column 17 is expected to have type atom() |
<<_:_*8>> |
[char()] |
[char() | atom() | deep_list()] but it has type file:filename() | {error, bad_name}
-spec get_input_dir() -> file:filename().
get_input_dir() ->
filename:join(code:priv_dir(aoc_erlang), "inputs").
^^^^^^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//inputs.beam: The variable on line 61 at column 3 is expected to have type file:filename() but it has type <<_:_*8>> | [char()]
io_lib:format("input~2..0B.txt", [Day])]),
true = filelib:is_file(Filename),
Filename.
^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2015_day08.beam: The operator '++' on line 36 at column 29 is expected to have type _TyVar-576460752303422874 which is too precise to be statically checked
_build/default/lib/aoc_erlang/ebin//aoc2015_day08.beam: The clause on line 70 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2019_day21.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day21.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2019_day21.beam: Undefined remote type intcode:intcode_program/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2020_day18.beam: Call to undefined function aoc2020_day18_lexer:string/1 on line 72 at column 46
_build/default/lib/aoc_erlang/ebin//aoc2018_day24.beam: The pattern #{units := Units, damage := Damage} on line 111 at column 17 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2018_day24.beam: The pattern #{units := Units, hp := HP} on line 192 at column 13 doesn't have the type any()
_build/default/lib/aoc_erlang/ebin//aoc2015_day12.beam: Undefined remote type jsone:json_object/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2015_day12.beam: Undefined remote type jsone:json_object/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2015_day12.beam: Undefined remote type jsone:json_object/0 on line 0
_build/default/lib/aoc_erlang/ebin//aoc2018_day08.beam: The function call on line 26 at column 15 is expected to have type [char()] but it has type unicode:chardata()
parse(Input) ->
lists:map(fun list_to_integer/1,
string:tokens(string:trim(binary_to_list(Input)), " ")).
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2018_day08.beam: The operator '+' on line 42 at column 22 is expected to have type char() which is too precise to be statically checked
_build/default/lib/aoc_erlang/ebin//aoc2015_day04.beam: The function call on line 31 at column 30 is expected to have type maybe_improper_list(0..255 |
<<_:_*8>> |
maybe_improper_list(byte() |
binary() |
iolist(),
[] | binary()),
<<_:_*8>> | []) but it has type string()
solve(Input, N, P1) ->
case erlang:md5(Input ++ integer_to_list(N)) of
^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2015_day05.beam: The clause on line 44 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2015_day05.beam: The clause on line 64 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2015_day05.beam: The clause on line 72 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2018_day09.beam: The function call on line 37 at column 13 is expected to have type [T, ...] but it has type [Value]
#{},
Last),
lists:max(maps:values(Scores)).
^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//intcode.beam: Call to undefined function intcode:parse/1 on line 39 at column 19
_build/default/lib/aoc_erlang/ebin//intcode.beam: The pattern {Inputs, Outputs} on line 84 at column 29 doesn't have the type integer()
_build/default/lib/aoc_erlang/ebin//aoc2015_day13.beam: The pattern ["would",
GainOrLose, Amount,
"happiness",
"units",
"by",
"sitting",
"next",
"to",
B] on line 26 at column 19 doesn't have the type [nonempty_string()] | []
_build/default/lib/aoc_erlang/ebin//aoc2015_day13.beam: The clause on line 110 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2020_day23.beam: The operator '+' on line 83 at column 39 is requires numeric arguments, but has arguments of type Val | undefined and any()
_build/default/lib/aoc_erlang/ebin//aoc2020_day23.beam: The clause on line 106 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2018_day25.beam: The operator '++' on line 59 at column 65 is expected to have type _TyVar-576460752303423002 which is too precise to be statically checked
_build/default/lib/aoc_erlang/ebin//aoc2019_day20.beam: Call to undefined function dijkstra:dijkstra/3 on line 39 at column 36
_build/default/lib/aoc_erlang/ebin//aoc2019_day20.beam: Call to undefined function dijkstra:dijkstra/3 on line 47 at column 36
_build/default/lib/aoc_erlang/ebin//aoc2019_day20.beam: The variable on line 212 at column 22 is expected to have type [T, ...] but it has type [A]
end,
Map))),
MaxX = lists:max(XCoords),
^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2015_day09.beam: The pattern ["to", To, "=", Dist] on line 25 at column 25 doesn't have the type [nonempty_string()] | []
_build/default/lib/aoc_erlang/ebin//aoc2015_day09.beam: The clause on line 62 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2018_day13.beam: The variable on line 113 at column 20 is expected to have type [term()] but it has type <<_:_*8>> |
maybe_improper_list(char() | unicode_binary() | charlist(),
unicode_binary() | [])
Str = binary_to_list(Binary),
[First | _] = string:split(Str, "\n"),
Width = length(First),
^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2018_day05.beam: The function call on line 24 at column 5 is expected to have type input_type() but it has type unicode:chardata()
-spec parse(Input :: binary()) -> input_type().
parse(Input) -> string:trim(binary_to_list(Input)).
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2018_day05.beam: The variable on line 36 at column 11 is expected to have type string() but it has type [integer()]
-spec react([integer()]) -> [integer()].
react(L) -> react(L, []).
^
_build/default/lib/aoc_erlang/ebin//aoc2019_day16.beam: The function call on line 24 at column 5 is expected to have type input_type() but it has type unicode:chardata()
-spec parse(Binary :: binary()) -> input_type().
parse(Binary) -> string:trim(binary_to_list(Binary)).
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2019_day16.beam: The variable on line 79 at column 31 is expected to have type non_neg_integer() but it has type integer()
{S, _} = lists:split(7, String),
Offset = list_to_integer(S),
{_, Digits} = lists:split(Offset,
^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2016_day10.beam: The clause on line 53 at column 1 cannot be reached
_build/default/lib/aoc_erlang/ebin//aoc2016_day10.beam: The variable on line 88 at column 39 is expected to have type [char()] but it has type <<_:_*8>> |
maybe_improper_list(char() | unicode_binary() | charlist(),
unicode_binary() | [])
"value" ->
[Value, "goes", "to", "bot", Bot] = Rest,
{goes_to, list_to_integer(Value), list_to_integer(Bot)};
^^^^^
_build/default/lib/aoc_erlang/ebin//aoc_erlang.beam: Call to undefined function aoc_puzzle:info/1 on line 8 at column 37
_build/default/lib/aoc_erlang/ebin//aoc2020_day03.beam: The operator 'rem' on line 55 at column 23 is expected to have type pos_integer() which is too precise to be statically checked
_build/default/lib/aoc_erlang/ebin//aoc2017_day03.beam: The function call on line 164 at column 28 is expected to have type [T, ...] but it has type [Key]
spiralmemory2_get_latest_value(SM = {_, Map, _}) ->
LargestIndex = lists:max(maps:keys(Map)),
^^^^^^^^^^^^^^
_build/default/lib/aoc_erlang/ebin//aoc2016_day06.beam: The variable on line 44 at column 37 is expected to have type [T, ...] but it has type [Value]
Words),
Freqs = maps:values(FM),
[MinChar] = find_keys(lists:min(Freqs), FM),
^^^^^
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment