cplusplus / draft

C++ standards drafts
http://www.open-std.org/jtc1/sc22/wg21/
5.59k stars 739 forks source link

[intro.scope] "free store" is undefined and used only once #7040

Open Eisenwave opened 1 month ago

Eisenwave commented 1 month ago

[intro.scope] p2 mentions "free store management operators", but this is now the only use of this term, and it is never defined.

I think we should replace it with something more formal, like "(class-specific) allocation functions".

This eliminates the only use of "free store", which is arguably outside the scope of the C++ standard anyway; it is an implementation detail.

jwakely commented 1 month ago

[class.free] still has an index entry for "free store".

Eisenwave commented 1 month ago

Ah I see; I didn't look in the index. To be honest, this doesn't change much though.

We can keep the entry in the index for those who look up new and delete by searching for "free store" in the index, although I wouldn't be surprised if not a single soul has ever done that, or will ever do that as long as C++ exists.

Regardless of that, it would be a slight improvement to call the feature "allocation functions" instead of the very unusual term "free store management operators".

frederick-vs-ja commented 1 month ago

As we've already indexed class-specific allocation and deallocation functions, I think it would be fine to remove "free store".

https://github.com/cplusplus/draft/blob/4b3f32ae814c8da3faccc0dc307904bd250371d9/source/classes.tex#L2807-L2812

https://github.com/cplusplus/draft/blob/4b3f32ae814c8da3faccc0dc307904bd250371d9/source/classes.tex#L2837-L2839