Skip to content

Fixed box construction error by excluding array_impl type#316

Closed
aimoonchen wants to merge 1 commit into
arximboldi:masterfrom
aimoonchen:master
Closed

Fixed box construction error by excluding array_impl type#316
aimoonchen wants to merge 1 commit into
arximboldi:masterfrom
aimoonchen:master

Conversation

@aimoonchen
Copy link
Copy Markdown

No description provided.

@aimoonchen
Copy link
Copy Markdown
Author

test code:

#include <immer/array.hpp>
#include <immer/box.hpp>
#include <immer/array_transient.hpp>
struct Value {
    using Array = immer::array<immer::box<Value>>;
    Value() = default;
    Value(immer::box<int>) {}
    Value(immer::box<double>) {}
    Value(Array) {}
};
void test()
{
    Value::Array{}.transient().persistent();
}

@alex-sparus
Copy link
Copy Markdown
Collaborator

Thank you for your contribution!

Unfortunately, this check breaks the forward declared types. Have a look: 6d22844

Would be nice to have both though! Let us know if you come up with a solution

@aimoonchen aimoonchen changed the title fix T construction error Fixed box construction error by excluding array_impl type Jan 8, 2026
@aimoonchen
Copy link
Copy Markdown
Author

aimoonchen commented Jan 8, 2026

@alex-sparus Thank you for your quick response, how about the new solution?

@arximboldi
Copy link
Copy Markdown
Owner

Superseded by: #318

@arximboldi arximboldi closed this Jan 13, 2026
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.

3 participants