Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

range() function #2058

Merged
merged 1 commit into from
Sep 21, 2023
Merged

range() function #2058

merged 1 commit into from
Sep 21, 2023

Conversation

AEsir777
Copy link
Contributor

  • range(start, end, step) produces [start, start + step, ..., end]

@codecov
Copy link

codecov bot commented Sep 19, 2023

Codecov Report

Patch coverage: 91.89% and project coverage change: -0.03% ⚠️

Comparison is base (6943574) 90.23% compared to head (cda29ea) 90.21%.
Report is 8 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #2058      +/-   ##
==========================================
- Coverage   90.23%   90.21%   -0.03%     
==========================================
  Files         950      953       +3     
  Lines       33779    34582     +803     
==========================================
+ Hits        30480    31197     +717     
- Misses       3299     3385      +86     
Files Changed Coverage Δ
src/include/common/types/types.h 100.00% <ø> (ø)
src/include/function/list/vector_list_functions.h 93.10% <86.48%> (-2.02%) ⬇️
src/function/vector_list_functions.cpp 90.18% <94.73%> (-0.42%) ⬇️
src/common/types/types.cpp 91.93% <100.00%> (-0.47%) ⬇️
src/function/built_in_vector_functions.cpp 99.45% <100.00%> (+0.05%) ⬆️
src/function/vector_map_functions.cpp 90.56% <100.00%> (ø)
.../function/arithmetic/vector_arithmetic_functions.h 95.06% <100.00%> (+2.07%) ⬆️
...lude/function/list/functions/list_range_function.h 100.00% <100.00%> (ø)

... and 105 files with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

test/test_files/tinysnb/function/range.test Outdated Show resolved Hide resolved
test/test_files/tinysnb/function/range.test Outdated Show resolved Hide resolved
src/include/function/list/functions/list_range_function.h Outdated Show resolved Hide resolved
src/function/vector_list_functions.cpp Outdated Show resolved Hide resolved
@@ -35,6 +35,7 @@ const std::string CAST_TO_BLOB_FUNC_NAME = "BLOB";

// list
const std::string LIST_CREATION_FUNC_NAME = "LIST_CREATION";
const std::string LIST_RANGE_FUNC_NAME = "RANGE";
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not related to this PR but I guess we can start sorting these function names in alphabetical order. Also sort code when you register.

src/include/function/list/functions/list_range_function.h Outdated Show resolved Hide resolved
src/include/function/list/functions/list_range_function.h Outdated Show resolved Hide resolved
src/include/function/list/functions/list_range_function.h Outdated Show resolved Hide resolved
test/test_files/tinysnb/function/range.test Outdated Show resolved Hide resolved
src/include/common/types/types.h Outdated Show resolved Hide resolved
src/include/function/list/functions/list_range_function.h Outdated Show resolved Hide resolved
src/include/function/list/vector_list_functions.h Outdated Show resolved Hide resolved
@AEsir777
Copy link
Contributor Author

Test covered #102-103 and #77-78
image
image
However, default case is not covered and it will not be triggered since we did not pass any parameter to the function other than integer types.

@AEsir777 AEsir777 merged commit e2a0c29 into master Sep 21, 2023
11 checks passed
@AEsir777 AEsir777 deleted the range branch September 21, 2023 17:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants