aboutsummaryrefslogtreecommitdiffstats
path: root/lib/stdlib/src/erl_lint.erl
diff options
context:
space:
mode:
authorHans Bolinder <[email protected]>2014-04-17 08:14:52 +0200
committerHans Bolinder <[email protected]>2014-04-17 08:14:52 +0200
commitcd0104e66c782137058d478f6d202df269f55f64 (patch)
tree7895893b3d5d1621a448c40a5a2ca30ef088118d /lib/stdlib/src/erl_lint.erl
parentb8494d9b7362f1edfb87f2dbd9f12e316ac71c1e (diff)
parent8fefeb8a1738a3be87bd7c324a07ae866d958112 (diff)
downloadotp-cd0104e66c782137058d478f6d202df269f55f64.tar.gz
otp-cd0104e66c782137058d478f6d202df269f55f64.tar.bz2
otp-cd0104e66c782137058d478f6d202df269f55f64.zip
Merge branch 'hb/stdlib/map_type_fix/OTP-11872' into maint
* hb/stdlib/map_type_fix/OTP-11872: stdlib: Fix error message when exporting (redefined) map() type
Diffstat (limited to 'lib/stdlib/src/erl_lint.erl')
-rw-r--r--lib/stdlib/src/erl_lint.erl5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/stdlib/src/erl_lint.erl b/lib/stdlib/src/erl_lint.erl
index 7c064ce902..39cc03cf7a 100644
--- a/lib/stdlib/src/erl_lint.erl
+++ b/lib/stdlib/src/erl_lint.erl
@@ -1046,9 +1046,10 @@ check_undefined_types(#lint{usage=Usage,types=Def}=St0) ->
Used = Usage#usage.used_types,
UTAs = dict:fetch_keys(Used),
Undef = [{TA,dict:fetch(TA, Used)} ||
- TA <- UTAs,
+ {T,_}=TA <- UTAs,
not dict:is_key(TA, Def),
- not is_default_type(TA)],
+ not is_default_type(TA),
+ not is_newly_introduced_var_arity_type(T)],
foldl(fun ({TA,L}, St) ->
add_error(L, {undefined_type,TA}, St)
end, St0, Undef).