This reverts commit 2ec6174bef.
New changes:
- Use explicit overloads of write(<int types>)
- Fix link error due to missing dependency (lib/Support)
- Updated tests and docs
27 lines
618 B
C++
27 lines
618 B
C++
#include "llvm/Telemetry/Telemetry.h"
|
|
|
|
namespace llvm {
|
|
namespace telemetry {
|
|
|
|
void TelemetryInfo::serialize(Serializer &serializer) const {
|
|
serializer.write("SessionId", SessionId);
|
|
}
|
|
|
|
Error Manager::dispatch(TelemetryInfo *Entry) {
|
|
if (Error Err = preDispatch(Entry))
|
|
return Err;
|
|
|
|
Error AllErrs = Error::success();
|
|
for (auto &Dest : Destinations) {
|
|
AllErrs = joinErrors(std::move(AllErrs), Dest->receiveEntry(Entry));
|
|
}
|
|
return AllErrs;
|
|
}
|
|
|
|
void Manager::addDestination(std::unique_ptr<Destination> Dest) {
|
|
Destinations.push_back(std::move(Dest));
|
|
}
|
|
|
|
} // namespace telemetry
|
|
} // namespace llvm
|