diff options
author | Hans Bolinder <[email protected]> | 2016-06-08 08:35:10 +0200 |
---|---|---|
committer | Hans Bolinder <[email protected]> | 2016-06-08 08:36:41 +0200 |
commit | 6a0d7e9abef8474ae1de739868ecb2245e8aa6a8 (patch) | |
tree | 228b8024decd1622fffb41d7aad99b9d06119ed6 /lib/dialyzer/test/small_SUITE_data/src/loopy.erl | |
parent | a39395d4f99aff99ac57ab40a3191fa13a7371fd (diff) | |
download | otp-6a0d7e9abef8474ae1de739868ecb2245e8aa6a8.tar.gz otp-6a0d7e9abef8474ae1de739868ecb2245e8aa6a8.tar.bz2 otp-6a0d7e9abef8474ae1de739868ecb2245e8aa6a8.zip |
Dialyzer: Fix a bug that caused Dialyzer to go into an infinite loop.
Dialyzer failed to remove all loops among constraints.
Diffstat (limited to 'lib/dialyzer/test/small_SUITE_data/src/loopy.erl')
-rw-r--r-- | lib/dialyzer/test/small_SUITE_data/src/loopy.erl | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/lib/dialyzer/test/small_SUITE_data/src/loopy.erl b/lib/dialyzer/test/small_SUITE_data/src/loopy.erl new file mode 100644 index 0000000000..28125ec3d9 --- /dev/null +++ b/lib/dialyzer/test/small_SUITE_data/src/loopy.erl @@ -0,0 +1,17 @@ +%% ERL-157, OTP-13653. +%% Would cause Dialyzer to go into an infinite loop. + +-module(loopy). + +-export([loop/1]). + + +-spec loop(Args) -> ok when + Args :: [{Module, Args}], + Module :: module(), + Args :: any(). +loop([{Module, Args} | Rest]) -> + Module:init(Args), + loop(Rest); +loop([]) -> + ok. |