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

GH-36820: [C++] Remove a needless return in Acero ScanNode::AddScanTasks #36821

Closed

Conversation

mapleFU
Copy link
Member

@mapleFU mapleFU commented Jul 22, 2023

Rationale for this change

ScanNode::AddScanTasks has multiple return value. This patch remove the latter one.

What changes are included in this PR?

Just remove some code.

Are these changes tested?

no

Are there any user-facing changes?

no

@mapleFU mapleFU requested a review from westonpace as a code owner July 22, 2023 07:16
@github-actions
Copy link

⚠️ GitHub issue #36820 has been automatically assigned in GitHub to PR creator.

@kou kou changed the title GH-36820: [C++] Minor: trying to fix style in Acero ScanNode::AddScanTasks GH-36820: [C++] Remove a needless return in Acero ScanNode::AddScanTasks Jul 24, 2023
@kou
Copy link
Member

kou commented Jul 24, 2023

(I'm not sure the details of this code too.)

If we don't need to return list_and_scan_done, it seems that we can remove all list_and_scan_done related codes too.

@mapleFU
Copy link
Member Author

mapleFU commented Jul 24, 2023

Let me wait for weston's idea...Actually I'm not sure whether we need to return OK() or list_and_scan_done

@mapleFU
Copy link
Member Author

mapleFU commented Jul 24, 2023

@westonpace would you mind take a look? Just two line fix

Copy link
Member

@westonpace westonpace left a comment

Choose a reason for hiding this comment

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

Thanks. I changed the need for this future in #32768 but it was very clumsy of me to leave this return statement here. Sorry.

You could probably change this method to return void but the method will also hopefully be going away entirely as part of #35889 so I'm fine if you want to stick with this minimal change.

@github-actions github-actions bot added awaiting merge Awaiting merge and removed awaiting review Awaiting review labels Jul 24, 2023
@westonpace
Copy link
Member

And yes, we should be able to remove list_and_scan_done entirely but it is not too important since this method is going away.

@mapleFU
Copy link
Member Author

mapleFU commented Jul 24, 2023

Just want to remove it because I seen this while reading the code. If you think it's not neccessary, feel free to close this patch :-)
I'll try to remove list_and_scan_done later

@mapleFU
Copy link
Member Author

mapleFU commented Jul 24, 2023

Close this issue and wait for #35889 to be merged :-)

@mapleFU mapleFU closed this Jul 24, 2023
@mapleFU mapleFU deleted the tiny-fix-for-scan-multiple-return branch July 24, 2023 15:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[C++] Acero: ScanNode::AddScanTasks has unreached return value
3 participants