[libc-commits] [PATCH] D130405: Implement TZ Variable Parsing Function.

Jeff Bailey via Phabricator via libc-commits libc-commits at lists.llvm.org
Tue Jul 26 19:27:17 PDT 2022


jeffbailey added inline comments.


================
Comment at: libc/src/time/time_zone_posix.cpp:190
+  PosixTransition posixTransition;
+  if (m_spec.starts_with(',')) {
+    m_spec.remove_prefix(1);
----------------
Should this be if!, and an early return?


================
Comment at: libc/src/time/time_zone_posix.cpp:203
+    }
+    if (optionalPosixTransition.has_value())
+      posixTransition = optionalPosixTransition.value();
----------------
Should this have an else return Nullopt?  I don't think we'd process the /offset below if this part isn't set.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D130405/new/

https://reviews.llvm.org/D130405



More information about the libc-commits mailing list