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

memory: Add constructor for empty device_unique_object #402

Merged
merged 1 commit into from
Sep 13, 2023
Merged

Conversation

stotko
Copy link
Owner

@stotko stotko commented Sep 13, 2023

In #391, a new wrapper class for automatically managing device objects has been introduced. However, empty managed object can not be constructed which prohibits use cases where, e.g., such a managed object is moved. Add a respective constructor that accepts a null_object as well as an overload of operator bool() to enable testing for empty objects.

@stotko stotko added this to the 2.0.0 milestone Sep 13, 2023
@codecov
Copy link

codecov bot commented Sep 13, 2023

Codecov Report

Patch coverage: 100.00% and no project coverage change.

Comparison is base (50530de) 97.40% compared to head (ae6ead0) 97.40%.

❗ Current head ae6ead0 differs from pull request most recent head 99589ee. Consider uploading reports for the commit 99589ee to get more accurate results

Additional details and impacted files
@@           Coverage Diff           @@
##           master     #402   +/-   ##
=======================================
  Coverage   97.40%   97.40%           
=======================================
  Files          31       31           
  Lines        2581     2586    +5     
=======================================
+ Hits         2514     2519    +5     
  Misses         67       67           
Files Changed Coverage Δ
src/stdgpu/impl/memory_detail.h 99.11% <100.00%> (+0.02%) ⬆️

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

@stotko stotko merged commit b70405b into master Sep 13, 2023
53 checks passed
@stotko stotko deleted the null_object branch September 13, 2023 13:54
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.

None yet

1 participant