.\"remove a (key, value) pair from a mapping based on the key
.TH map_delete 3 "5 Sep 1994" MudOS "LPC Library Functions"
.SH NAME
map_delete() - remove a (key, value) pair from a mapping based on the key
.SH SYNOPSIS
void map_delete( mapping m, mixed element );
.SH DESCRIPTION
map_delete removes the (key, value) from the mapping m that has key equal
to element.
.PP
For example, given:
.IP
.nf
mapping names;
names = ([]);
names["truilkan"] = "john";
names["wayfarer"] = "erik";
names["jacques"] = "dwayne";
.fi
.PP
Then:
.IP
.nf
map_delete(names,"truilkan");
.fi
.PP
causes the mapping 'names' to be equal to:
.IP
.nf
(["wayfarer" : "erik", "jacques" : "dwayne"])
.fi
.PP
keys(names) will not contain "truilkan" after map_delete(names,"truilkan")
is called [unless ("truilkan", *) is subsequently added back to the mapping].
.SH SEE ALSO
allocate_mapping(3)