MCPcopy Create free account
hub / github.com/DFHack/dfhack / find_flagarray_field

Function find_flagarray_field

library/include/DataDefs.h:931–936  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

929 */
930 template<class T>
931 inline bool find_flagarray_field(unsigned *idx, const std::string &name, const BitArray<T>*) {
932 T tmp;
933 if (!find_enum_item(&tmp, name) || tmp < 0) return false;
934 *idx = unsigned(tmp);
935 return true;
936 }
937
938 /**
939 * Find a flag array item by key and set its value. Returns success code.

Callers

nothing calls this directly

Calls 1

find_enum_itemFunction · 0.85

Tested by

no test coverage detected