Skip to content

Bug: Vector from no-default constructible class produces CE #20

@bivafra

Description

@bivafra

Problem

When Vector is instantiated from class that has not default c-tor, every method that uses pushingRealloc(...) with PushDecide::kNoPush will produce CE. It happens at the 543 line - there are no args to pass to allocator's construct(...), thus, it is instantiated without args and it calls default c-tor. However, with PushDecide::kNoPush there aren't calls to default c-tor, so it shouldn't be instantiated.

Possible solution

Refactor code to instantiate construct(...) only when needed.

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingcontainerContainer related taskp2higher priority

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions