diff options
author | Henrik Nord <[email protected]> | 2014-02-10 16:29:55 +0100 |
---|---|---|
committer | Henrik Nord <[email protected]> | 2014-02-10 16:29:57 +0100 |
commit | 7b0af710d493909799de6e6123f81b5e7b8d2ef2 (patch) | |
tree | f8bc0615fd92706284f875d838b64e39821c4907 /lib/stdlib/test | |
parent | c7174e89688d449a79b2180e61f8003ba0e731fd (diff) | |
parent | d2b412df6c8751c10de025399cb04a8194169d0d (diff) | |
download | otp-7b0af710d493909799de6e6123f81b5e7b8d2ef2.tar.gz otp-7b0af710d493909799de6e6123f81b5e7b8d2ef2.tar.bz2 otp-7b0af710d493909799de6e6123f81b5e7b8d2ef2.zip |
Merge branch 'josevalim/suppress-all-auto-imports'
* josevalim/suppress-all-auto-imports:
Allow all auto imports to be suppressed at once
OTP-11682
Diffstat (limited to 'lib/stdlib/test')
-rw-r--r-- | lib/stdlib/test/erl_lint_SUITE.erl | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/lib/stdlib/test/erl_lint_SUITE.erl b/lib/stdlib/test/erl_lint_SUITE.erl index 6e9a9dd7bf..48f50d5f43 100644 --- a/lib/stdlib/test/erl_lint_SUITE.erl +++ b/lib/stdlib/test/erl_lint_SUITE.erl @@ -2827,7 +2827,24 @@ bif_clash(Config) when is_list(Config) -> {6,erl_lint,{illegal_guard_local_call,{is_tuple,1}}}, {7,erl_lint,{illegal_guard_local_call,{is_list,1}}}, {8,erl_lint,{illegal_guard_local_call,{is_record,3}}}, - {9,erl_lint,{illegal_guard_local_call,{is_record,3}}}],[]}} + {9,erl_lint,{illegal_guard_local_call,{is_record,3}}}],[]}}, + %% We can also suppress all auto imports at once + {clash22, + <<"-export([size/1, binary_part/2]). + -compile(no_auto_import). + size([]) -> + 0; + size({N,_}) -> + N; + size([_|T]) -> + 1+size(T). + binary_part({B,_},{X,Y}) -> + binary_part(B,{X,Y}); + binary_part(B,{X,Y}) -> + binary:part(B,X,Y). + ">>, + [], + []} ], ?line [] = run(Config, Ts), |