class_t* mgr_t::pimpl_t::attach(const ref_t& ref) { if(!ref.ok) panic(ref << " is not set"); classes_t::iterator i = classes.find(ref.name); if(i == classes.end()) { classes.insert(classes_t::value_type(ref.name,idx_t(ref.type,ref.name))); return NULL; } i->second.refs++; return i->second.cls; }
inline idx_t pi<1>(const rng_t &j, const rng_t &i) { return idx_t({i,j}); };
inline idx_t pi<0>(const rng_t &i, const rng_t &j) { return idx_t({i,j}); };