aboutsummaryrefslogtreecommitdiffstats
path: root/lib/dialyzer/test/small_SUITE_data
diff options
context:
space:
mode:
authorBjörn-Egil Dahlberg <[email protected]>2014-04-29 14:43:48 +0200
committerBjörn-Egil Dahlberg <[email protected]>2014-04-29 15:44:48 +0200
commit839f8fea41003883681188dfb09eebbfbd351094 (patch)
tree3085e6ff31d0e92efffe49ff87bc39d5cdd2a353 /lib/dialyzer/test/small_SUITE_data
parenta53bcf79429c73bce86d57a47ecfcc4acf0fbd70 (diff)
downloadotp-839f8fea41003883681188dfb09eebbfbd351094.tar.gz
otp-839f8fea41003883681188dfb09eebbfbd351094.tar.bz2
otp-839f8fea41003883681188dfb09eebbfbd351094.zip
dialyzer: Add Maps type mismatch test
Diffstat (limited to 'lib/dialyzer/test/small_SUITE_data')
-rw-r--r--lib/dialyzer/test/small_SUITE_data/results/maps_difftype3
-rw-r--r--lib/dialyzer/test/small_SUITE_data/src/maps_difftype.erl11
2 files changed, 14 insertions, 0 deletions
diff --git a/lib/dialyzer/test/small_SUITE_data/results/maps_difftype b/lib/dialyzer/test/small_SUITE_data/results/maps_difftype
new file mode 100644
index 0000000000..8980321135
--- /dev/null
+++ b/lib/dialyzer/test/small_SUITE_data/results/maps_difftype
@@ -0,0 +1,3 @@
+
+maps_difftype.erl:10: Function empty_mismatch/1 has no local return
+maps_difftype.erl:11: The pattern ~{}~ can never match the type tuple()
diff --git a/lib/dialyzer/test/small_SUITE_data/src/maps_difftype.erl b/lib/dialyzer/test/small_SUITE_data/src/maps_difftype.erl
new file mode 100644
index 0000000000..19e61a7944
--- /dev/null
+++ b/lib/dialyzer/test/small_SUITE_data/src/maps_difftype.erl
@@ -0,0 +1,11 @@
+%%
+%% File: maps_difftype.erl
+%% Author: Björn-Egil Dahlberg
+%% Created: 2014-04-29
+%%
+-module(maps_difftype).
+
+-export([empty_mismatch/1]).
+
+empty_mismatch(Tuple) when is_tuple(Tuple) ->
+ case Tuple of #{} -> ok end.