| 691 | } |
| 692 | |
| 693 | VectorPtr restoreVectorFromFile( |
| 694 | const char* FOLLY_NONNULL filePath, |
| 695 | memory::MemoryPool* FOLLY_NONNULL pool) { |
| 696 | std::ifstream inputFile(filePath, std::ifstream::binary); |
| 697 | BOLT_CHECK(!inputFile.fail(), "Cannot open file: {}", filePath); |
| 698 | |
| 699 | auto result = restoreVector(inputFile, pool); |
| 700 | inputFile.close(); |
| 701 | return result; |
| 702 | } |
| 703 | |
| 704 | std::string restoreStringFromFile(const char* FOLLY_NONNULL filePath) { |
| 705 | std::ifstream inputFile(filePath, std::ifstream::binary); |