| 257 | |
| 258 | |
| 259 | hx::Val Anon_obj::__SetField(const String &inName,const hx::Val &inValue, hx::PropertyAccess inCallProp) |
| 260 | { |
| 261 | int slot = findFixed(inName); |
| 262 | if (slot>=0) |
| 263 | { |
| 264 | #ifdef HXCPP_GC_GENERATIONAL |
| 265 | VariantKey *fixed = getFixed() + slot; |
| 266 | fixed->value=inValue; |
| 267 | if (fixed->value.type <= cpp::Variant::typeString) |
| 268 | HX_OBJ_WB_GET(this, fixed->value.valObject); |
| 269 | #else |
| 270 | getFixed()[slot].value=inValue; |
| 271 | #endif |
| 272 | return inValue; |
| 273 | } |
| 274 | |
| 275 | // TODO - fixed |
| 276 | if (!mFields.mPtr) |
| 277 | { |
| 278 | mFields = hx::FieldMapCreate(); |
| 279 | HX_OBJ_WB_GET(this, mFields.mPtr); |
| 280 | } |
| 281 | |
| 282 | __string_hash_set(HX_MAP_THIS_ mFields,inName,inValue,true); |
| 283 | return inValue; |
| 284 | } |
| 285 | |
| 286 | Anon_obj *Anon_obj::Add(const String &inName,const Dynamic &inValue,bool inSetThisPointer) |
| 287 | { |
nothing calls this directly
no test coverage detected