[Plugin] unordered_map
#5

Quote:
Originally Posted by Yashas
View Post
You should allow all of the following (<key, value>):
<string, int>
<string, string>
<int, string>
<int, int>

This would be very useful if you could make it more complete:
1. allow the scripter to set load factor, bucket count, etc.
2. set function which works like try_emplace
3. set function which sets iff the key exists
Why you cannot use it like:
PHP Code:
 // Get int value
new map:map map_new();
map_emplace(map,"12","14");
new 
value[2];
map_find(map,"12",value,sizeof(value));
new 
intvalue strval(value);
// Emplace int value
new value[2];
format(value,sizeof(value),"%d",10); // With the key you can do the same
map_emplace(map,"test",value); 
1. I'll add to the next updates
2. I'll add to the next updates
3. What? Explain pls
Reply


Messages In This Thread
unordered_map - by ShapeGaz - 31.12.2017, 10:34
Re: unordered_map - by AnGeL_KRAMER - 31.12.2017, 10:40
Re: unordered_map - by ShapeGaz - 31.12.2017, 11:21
Re: unordered_map - by Yashas - 31.12.2017, 13:57
Re: unordered_map - by ShapeGaz - 31.12.2017, 14:59
Re: unordered_map - by chneubeul - 31.12.2017, 18:14
Re: unordered_map - by NaS - 31.12.2017, 18:48
Re: unordered_map - by ShapeGaz - 31.12.2017, 19:02
Re: unordered_map - by chneubeul - 31.12.2017, 19:17
Re: unordered_map - by ShapeGaz - 31.12.2017, 19:39

Forum Jump:


Users browsing this thread: 1 Guest(s)