| 451 | } |
| 452 | |
| 453 | void BeConstant::GetData(BeConstData& data) |
| 454 | { |
| 455 | auto type = GetType(); |
| 456 | while ((((int)data.mData.size()) % type->mAlign) != 0) |
| 457 | data.mData.push_back(0); |
| 458 | |
| 459 | if (type->IsComposite()) |
| 460 | { |
| 461 | for (int i = 0; i < type->mSize; i++) |
| 462 | data.mData.push_back(0); // Aggregate |
| 463 | } |
| 464 | else if (type->mTypeCode == BeTypeCode_Float) |
| 465 | { |
| 466 | float f = mDouble; |
| 467 | data.mData.Insert(data.mData.mSize, (uint8*)&f, sizeof(float)); |
| 468 | } |
| 469 | else |
| 470 | { |
| 471 | data.mData.Insert(data.mData.mSize, &mUInt8, type->mSize); |
| 472 | } |
| 473 | } |
| 474 | |
| 475 | void BeConstant::HashContent(BeHashContext& hashCtx) |
| 476 | { |
no test coverage detected