The OpenD Programming Language

AttributeSet.opBinaryRight

Provides support for testing presence of an attribute with the in operator.

struct AttributeSet
const
opBinaryRight
(
string op : "in"
)
(
string name
)

Examples

auto doc = new XmlDocument(`<test attr="test"/>`);
assert("attr" in doc.root.attrs);
assert("test" !in doc.root.attrs);

Meta

History

Added December 16, 2020 (dub v10.10)