std::experi...ol_resource(3)

πŸ“¦ version 2024.07.05, in nixpkgs unstable, opensuse-leap 16.0

πŸ’… NAME πŸ’…

Okay so this is the manual page for std::experi...ol_resource(3), and the actual thing it documents is std::experimental::pmr::synchronized_pool_resource::synchronized_pool_resource β€” yes, the constructor with the long name that ate and left no crumbs. The header labels this as C++ Standard Libary (their spelling, not mine 😭), and this is the library fundamentals TS constructor situation. Bestie, it’s a lot of name, but we got this.

🌸 SYNOPSIS 🌸

synchronized_pool_resource();                          (1) (library
fundamentals TS)
explicit synchronized_pool_resource( memory_resource*  (2) (library
fundamentals TS)
upstream );
explicit synchronized_pool_resource( const             (3) (library
fundamentals TS)
pool_options& opts );
synchronized_pool_resource( const pool_options& opts,
                            memory_resource* upstream  (4) (library
fundamentals TS)
);
synchronized_pool_resource( const                      (5) (library
fundamentals TS)
synchronized_pool_resource& ) = delete;

✨ It constructs a synchronized_pool_resource. That’s the main character job, no cap.

Overloads 1-4 construct a synchronized_pool_resource using the specified upstream memory resource and tuned according to the specified options. The resulting object holds a copy of upstream but does not own the resource to which upstream points. Important vibe check: copy, not own.

If an overload doesn’t take opts as a parameter, it uses a default-constructed instance of pool_options as the options. If an overload doesn’t take upstream as a parameter, it uses the return value of std::experimental::pmr::get_default_resource() as the upstream memory resource.

Overload 5 is the copy constructor, and it is deleted: = delete. Copy constructor is deleted β€” no copies, not today. πŸ’€

πŸ“ PARAMETERS πŸ“

  • opts β€” a pool_options struct containing the constructor options
  • upstream β€” the upstream memory resource to use

πŸ’€ EXCEPTIONS πŸ’€

Overloads 1-4 throw only if a call to the allocate() function of the upstream resource throws. It is unspecified if or under what conditions such a call takes place. So yeah, that’s the whole exception tea β€” unspecified is doing a lot of work there.

πŸŽ€ CATEGORY πŸŽ€

  • * Noindexed pages

Signed with love by http://cppreference.com, stamped 2024.06.10, and filed under std::experi...ol_resource(3) β€” periodt. πŸ’–πŸ«Άβœ¨

πŸ“¦ where this page comes from