HappenLee commented on code in PR #17970:
URL: https://github.com/apache/doris/pull/17970#discussion_r1148774459


##########
be/src/vec/functions/array/function_array_set.h:
##########
@@ -216,6 +267,66 @@ struct ArraySetImpl {
         }
         return true;
     }
+    template <typename ColumnType>
+    static bool _execute_internal_lconst(ColumnArrayMutableData& dst,
+                                         const ColumnArrayExecutionData& 
left_data,
+                                         const ColumnArrayExecutionData& 
right_data) {
+        using Impl = OpenSetImpl<operation, ColumnType>;
+        if (!check_column<ColumnType>(*left_data.nested_col)) {
+            return false;
+        }
+        constexpr auto execute_left_column_first = 
Impl::Action::execute_left_column_first;
+        size_t current = 0;
+        Impl impl;
+        for (size_t row = 0; row < left_data.offsets_ptr->size(); ++row) {
+            size_t count = 0;
+            size_t left_off = (*left_data.offsets_ptr)[-1];
+            size_t left_len = (*left_data.offsets_ptr)[0] - left_off;

Review Comment:
   out of the loop to do
   ```
               size_t left_off = (*left_data.offsets_ptr)[-1];
               size_t left_len = (*left_data.offsets_ptr)[0] - left_off;
   ```



-- 
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: commits-unsubscr...@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org
For additional commands, e-mail: commits-h...@doris.apache.org

Reply via email to