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

Don't have implicit system allocator constructors for types #58

Open
graphitemaster opened this issue Mar 26, 2021 · 0 comments
Open

Don't have implicit system allocator constructors for types #58

graphitemaster opened this issue Mar 26, 2021 · 0 comments
Assignees
Labels

Comments

@graphitemaster
Copy link
Member

Allocators are a dependency of anything that allocates, this involves functions and types (via their constructor, which is a type of function.) We used to make the default constructor of types delegate to another constructor taking an allocator and passing in the system allocator, with the same behavior for functions too, where an allocator-less function would just tail call the one taking an allocator and pass in the system allocator. This was very convenient in general, but turned out to be a bad idea because it's too easy to forget to pass the right allocator to things when you expected it, letting some things use the system allocator when they shouldn't of. Starting in commit a3177f9 these convenience constructors and functions are being removed. Eventually we'd like no implicit allocators for anything.

@graphitemaster graphitemaster self-assigned this May 8, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant