chore: List every UUID backend in the types module #459
All Vouch review confidence checks passed
Residual risk 0.15 = Change Risk (0.37) × (1 − Review Confidence (0.60)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.37 · 228 lines diff across 2 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.325
Shallow Review Depth
shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #459"
general
weight: 0.35
fuzzybinary
refs: RUM-20300
## Context
We want the code in
typesto be portable to other platforms and build toolchains, even those wheredd-sdk-cppis not supported in full. This is one in a series of PRs addressing minor portability issues.## Problem
We currently have three separate UUID implementations:
uuid_linux.cppuuid_macos.cppuuid_windows.cppOur CMake configuration branches on CMake platform variables (
WIN32|APPLE|UNIX) to select one of these files to compile.We want to be able to compile
typesin other build systems, without having to specially configure a platform-dependent set of source files: we should be able to throw a pile of source files at a build system, such that it will compile _all_ of them, and we'll get a working build.## Solution
As of this PR, we no longer rely on the build system to conditionally include the appropriate source file in the set of input files for the compiler.
Instead, we now just compile all three files. Each implementation file is guarded with preprocessor checks to ensure that only one of them will produce any code:
#if defined(__linux__)_(covers Desktop Linux, Android)_#if defined(__APPLE__)_(covers macOS, iOS)_#if defined(_WIN32)_(covers Windows)_If compilation is attempted on any other platform, UUID functions will be missing symbols, resulting in linker errors.
On macOS, static builds without sanitizers now print a harmless
ranlibwarning that the unused implementations' object files have no symbols. This warning only appears when building the SDK, not when linking it into an application.### BYO UUID
When building the SDK from source in CMake, we also support a bring-your-own-random-UUID-generator option, via
DD_UUID_USE_DEFAULTandDD_UUID_SRC. These options continue to work as before.