================
@@ -64,11 +64,19 @@ class Serializer {
/// This struct can be extended as needed to add additional configuration
/// points specific to a vendor's implementation.
struct Config {
- virtual ~Config() = default;
+#ifdef LLVM_ENABLE_TELEMETRY
+ static const bool BuildTimeEnableTelemetry = true;
+#else
+ static const bool BuildTimeEnableTelemetry = false;
+#endif
+ virtual ~Config() : EnableTelemetry(BuildTimeEnableTelemetry) {}
// If true, telemetry will be enabled.
const bool EnableTelemetry;
- Config(bool E) : EnableTelemetry(E) {}
+
+ // Telemetry can only be enabled if both the runtime and buildtime flag
+ // are set.
+ Config(bool E) : EnableTelemetry(E && BuildTimeEnableTelemetry) {}
----------------
labath wrote:
Just a drive-by
```suggestion
explicit Config(bool E) : EnableTelemetry(E && BuildTimeEnableTelemetry) {}
```
https://github.com/llvm/llvm-project/pull/128534
_______________________________________________
lldb-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits