| 467 | } |
| 468 | |
| 469 | void SynthesizeFlagFields() |
| 470 | { |
| 471 | // synthesize a symbol for each flag from the flag name tables to avoid redundant declaration of them. |
| 472 | for (auto &fl : FlagLists) |
| 473 | { |
| 474 | auto cls = const_cast<PClass*>(*fl.Type); |
| 475 | if (fl.Use & 2) |
| 476 | { |
| 477 | for (int i = 0; i < fl.NumDefs; i++) |
| 478 | { |
| 479 | if (fl.Defs[i].structoffset > 0) // skip the deprecated entries in this list |
| 480 | { |
| 481 | cls->VMType->AddNativeField(FStringf("b%s", fl.Defs[i].name), (fl.Defs[i].fieldsize == 4 ? TypeSInt32 : TypeSInt16), fl.Defs[i].structoffset, fl.Defs[i].varflags, fl.Defs[i].flagbit); |
| 482 | } |
| 483 | } |
| 484 | } |
| 485 | } |
| 486 | } |
no test coverage detected