You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The following code works when compiled but not when run in int.
-module(a_test).
%% This test works in OTP 22, but it fails in OTP 25 and OTP 26.%%%% Run this in the Erlang shell to reproduce it:%%%% 1> a_test:the_test().%% A TEST OK!!%% ok%% 2> i:ii(a_test).%% {module,a_test}%% 3> a_test:the_test().%% A TEST IS NOT OK!
-export([the_test/0]).
-define(is_foo(X), (((X#foo.the_baz)#baz.something== []))).
-record(baz, {something}).
-record(foo, {the_bar,
the_baz}).
the_test() ->B=#baz{something= []},
F=#foo{the_baz=B},
if?is_foo(F) ->
io:format("A TEST OK!!~n",[]);
true ->
io:format("A TEST IS NOT OK!~n",[])
end.
The text was updated successfully, but these errors were encountered:
The following code works when compiled but not when run in
int
.The text was updated successfully, but these errors were encountered: