You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@trafficserver.apache.org by "ywkaras (via GitHub)" <gi...@apache.org> on 2023/06/23 00:24:48 UTC

[GitHub] [trafficserver] ywkaras commented on a diff in pull request #9812: First stab at cleaning up experimental.h deps

ywkaras commented on code in PR #9812:
URL: https://github.com/apache/trafficserver/pull/9812#discussion_r1239147311


##########
include/ts/apidefs.h.in:
##########
@@ -902,8 +902,19 @@ typedef enum {
   TS_THREAD_POOL_UDP
 } TSThreadPool;
 
+/* TSHRTime stuff, this is a candidate for deprecation in v10.0.0 */
 typedef int64_t TSHRTime;
 
+#define TS_HRTIME_SECOND  (1000 * TS_HRTIME_MSECOND)
+#define TS_HRTIME_MSECOND (1000 * TS_HRTIME_USECOND)
+#define TS_HRTIME_USECOND (1000 * TS_HRTIME_NSECOND)
+#define TS_HRTIME_NSECOND (1LL)
+
+#define TS_HRTIME_SECONDS(_x)  ((_x)*TS_HRTIME_SECOND)

Review Comment:
   Why not `constexpr TSHRTime TS_HRTIME_SECONDS(TSHRTIME nsec) { return nsec * TS_HRTIME_SECOND); }` ?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@trafficserver.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org