jvictorhuguenin commented on a change in pull request #10112:
URL: https://github.com/apache/arrow/pull/10112#discussion_r632664286
##########
File path: cpp/src/gandiva/precompiled/time.cc
##########
@@ -828,4 +828,44 @@ gdv_int64 castBIGINT_daytimeinterval(gdv_day_time_interval
in) {
extractDay_daytimeinterval(in) * MILLIS_IN_DAY;
}
+#define CAST_INT_YEAR_INTERVAL(NAME, OUT_TYPE) \
+ FORCE_INLINE \
+ gdv_##OUT_TYPE NAME##_year_interval(gdv_year_interval in) { \
+ return static_cast<gdv_##OUT_TYPE>(in / 12.0); \
Review comment:
Because the year interval is represented as a month interval(Arrow only
supports month intervals and daytime intervals). So I changed the type alias to
gdv_month_interval to make it clear.
--
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.
For queries about this service, please contact Infrastructure at:
[email protected]