Fixed a bug that caused an out of range error when a key in a
mapping could not be found.
This commit is contained in:
parent
04af9bf240
commit
d46a3ac5c2
|
@ -1323,7 +1323,7 @@ struct Node
|
||||||
}
|
}
|
||||||
|
|
||||||
//Get index of pair with key (or value, if value is true) matching index.
|
//Get index of pair with key (or value, if value is true) matching index.
|
||||||
size_t findPair(T, bool value = false)(const ref T index) const
|
sizediff_t findPair(T, bool value = false)(const ref T index) const
|
||||||
{
|
{
|
||||||
const pairs = value_.get!(const Pair[])();
|
const pairs = value_.get!(const Pair[])();
|
||||||
const(Node)* node;
|
const(Node)* node;
|
||||||
|
|
Loading…
Reference in a new issue