Explicitly cast seconds to NSTimeInterval in TimeIntervalFromSecondsAndNanos. This was causing an error in our Github tests (https://github.com/protocolbuffers/protobuf/actions/runs/23308413575/job/67788944664) after Github upgraded its Macos 14 runner images. This likely seems to be due to the upgrade to Clang/LLVM, though the release notes claim the error was actually made *weaker* in 15.0.1 https://reviews.llvm.org/D133800. Seems like https://github.com/actions/runner-images/issues/13827 is likely mistakenly causing this to surface, but this is an error in Clang16 so we should probably fix it anyways. PiperOrigin-RevId: 886846312
diff --git a/objectivec/GPBWellKnownTypes.m b/objectivec/GPBWellKnownTypes.m index d758702..1b3adba 100644 --- a/objectivec/GPBWellKnownTypes.m +++ b/objectivec/GPBWellKnownTypes.m
@@ -19,7 +19,7 @@ static NSString *kTypePrefixGoogleApisCom = @"type.googleapis.com/"; static NSTimeInterval TimeIntervalFromSecondsAndNanos(int64_t seconds, int32_t nanos) { - return seconds + (NSTimeInterval)nanos / 1e9; + return (NSTimeInterval)seconds + (NSTimeInterval)nanos / 1e9; } static int32_t SecondsAndNanosFromTimeInterval(NSTimeInterval time, int64_t *outSeconds,