Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:Ledest:erlang:24
erlang
0829-stdlib-Fix-some-warnings-in-ets_SUITE.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File 0829-stdlib-Fix-some-warnings-in-ets_SUITE.patch of Package erlang
From 17286219606ca0a290eab9037709d95aacfb7fb7 Mon Sep 17 00:00:00 2001 From: Sverker Eriksson <sverker@erlang.org> Date: Fri, 30 Jun 2023 16:43:11 +0200 Subject: [PATCH] stdlib: Fix some warnings in ets_SUITE --- lib/stdlib/test/ets_SUITE.erl | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/lib/stdlib/test/ets_SUITE.erl b/lib/stdlib/test/ets_SUITE.erl index 4f9272eaac..aabbf1505e 100644 --- a/lib/stdlib/test/ets_SUITE.erl +++ b/lib/stdlib/test/ets_SUITE.erl @@ -1112,8 +1112,8 @@ delete_all_objects_trap(Opts, Mode) -> false; "delete_all_objects done" -> ct:fail("No trap detected"); - M -> - %%io:format("Ignored msg: ~p\n", [M]), + _M -> + %%io:format("Ignored msg: ~p\n", [_M]), true end end), @@ -5484,30 +5484,30 @@ insert_trap_delete_run3(Traps, {Opts, InsertFunc, Mode}, NKeys) -> %% Rename table during trapping ets:insert insert_trap_rename(Config) when is_list(Config) -> repeat_for_opts(fun(Opts) -> - [insert_trap_rename_run1(InsertFunc) + [insert_trap_rename_run1(Opts, InsertFunc) || InsertFunc <- [insert, insert_new]] end, [all_non_stim_types, write_concurrency, compressed]), ok. -insert_trap_rename_run1(InsertFunc) -> +insert_trap_rename_run1(Opts, InsertFunc) -> NKeys = 50_000 + rand:uniform(50_000), %% First measure how many traps the insert op will do - Traps0 = insert_trap_rename_run3(unlimited, InsertFunc, NKeys), + Traps0 = insert_trap_rename_run3(Opts, unlimited, InsertFunc, NKeys), %% Then do again and rename table at different moments Decr = (Traps0 div 5) + 1, - insert_trap_rename_run2(Traps0-1, Decr, InsertFunc, NKeys), + insert_trap_rename_run2(Opts, Traps0-1, Decr, InsertFunc, NKeys), ok. -insert_trap_rename_run2(Traps, _Decr, InsertFunc, NKeys) when Traps =< 1 -> - insert_trap_rename_run3(1, InsertFunc, NKeys), +insert_trap_rename_run2(Opts, Traps, _Decr, InsertFunc, NKeys) when Traps =< 1 -> + insert_trap_rename_run3(Opts, 1, InsertFunc, NKeys), ok; -insert_trap_rename_run2(Traps, Decr, InsertFunc, NKeys) -> - insert_trap_rename_run3(Traps, InsertFunc, NKeys), - insert_trap_rename_run2(Traps - Decr, Decr, InsertFunc, NKeys). +insert_trap_rename_run2(Opts, Traps, Decr, InsertFunc, NKeys) -> + insert_trap_rename_run3(Opts, Traps, InsertFunc, NKeys), + insert_trap_rename_run2(Opts, Traps - Decr, Decr, InsertFunc, NKeys). -insert_trap_rename_run3(Traps, InsertFunc, NKeys) -> +insert_trap_rename_run3(Opts, Traps, InsertFunc, NKeys) -> io:format("insert_trap_rename_run(~p, ~p)\n", [Traps, InsertFunc]), TabName = insert_trap_rename, TabRenamed = insert_trap_rename_X, @@ -5517,7 +5517,7 @@ insert_trap_rename_run3(Traps, InsertFunc, NKeys) -> OwnerFun = fun() -> erlang:trace(Tester, true, [running]), - ets:new(TabName, [named_table, public]), + ets_new(TabName, [named_table, public | Opts]), Tester ! {ets_new, ets:whereis(TabName)}, io:format("Wait for ets:~p/2 to yield...\n", [InsertFunc]), GotTraps = repeat_while( -- 2.35.3
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor