You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2020/07/14 17:04:29 UTC

[GitHub] [arrow] nealrichardson commented on a change in pull request #7755: ARROW-9390: [C++][Doc] Review compute function names

nealrichardson commented on a change in pull request #7755:
URL: https://github.com/apache/arrow/pull/7755#discussion_r454506911



##########
File path: cpp/src/arrow/compute/kernels/scalar_string_benchmark.cc
##########
@@ -61,9 +61,9 @@ static void IsAlphaNumericAscii(benchmark::State& state) {
   UnaryStringBenchmark(state, "ascii_isalnum");
 }
 
-static void BinaryContainsExact(benchmark::State& state) {
-  BinaryContainsExactOptions options("abac");
-  UnaryStringBenchmark(state, "binary_contains_exact", &options);
+static void MatchSubstring(benchmark::State& state) {
+  MatchSubstringOptions options("abac");
+  UnaryStringBenchmark(state, "match_substring", &options);

Review comment:
       Are there clear criteria for when the function gets a `binary_` or `string_` prefix and when it doesn't?
   
   Related, if we haven't documented the naming conventions (haven't seen it yet but I'll keep reading), we should so that future developers/selves know what to call new functions.

##########
File path: cpp/src/arrow/compute/kernels/scalar_string.cc
##########
@@ -944,7 +944,7 @@ void RegisterScalarStringAscii(FunctionRegistry* registry) {
   MakeUnaryStringBatchKernel<AsciiUpper>("ascii_upper", registry);
   MakeUnaryStringBatchKernel<AsciiLower>("ascii_lower", registry);
 
-  AddUnaryStringPredicate<IsAscii>("binary_isascii", registry);
+  AddUnaryStringPredicate<IsAscii>("string_isascii", registry);

Review comment:
       Why isn't this `string_is_ascii`? It seems we prefer `is_x` to `isx` (cf. `isin` -> `is_in` in this PR).




----------------------------------------------------------------
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:
users@infra.apache.org