gcpp
graph_ptr
gcpp | graph_ptr | |
---|---|---|
12 | 1 | |
912 | 1 | |
- | - | |
10.0 | 10.0 | |
about 5 years ago | over 2 years ago | |
C++ | C++ | |
MIT License | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
gcpp
- C++: Deferred_ptr, Deferred_heap, Deferred_allocator
-
What feature would you like to see in C++26?
static reflection and pattern-matching, as everyone is saying, but I'd also like to see a garbage-collecting smart-pointer in the standard library similar in design to Herb Sutter's deferred_ptr
-
Rust went from side project to world’s fastest growing language
There are definitely fringe edge cases where C++ can do things that Rust simply cannot, currently.
I'm thinking of things like Herb Sutter's deferred_heap (https://github.com/hsutter/gcpp) that give you GC-like abstraction. It's pretty cool that this is possible to write in vanilla C++ with decent ergonomics. I tried to make something similar awhile back and hit a wall in terms of making something that would be pleasant to use.
Rust has several on-going experiments with making a nice GC, along with good support for arenas. (If you can use arenas, they're great.)
-
Now the C++ removed garbage collector support, is it still possible the have a global garbage collector in a C++ application?
Check out this library: https://github.com/hsutter/gcpp
-
tracked_ptr - when shared_ptr is not enough
Hm, yeah, that's pretty unclear. My understanding is based off the link to Herb's proposal in the OP, which I understand this to be an evolution of.
-
What do you think will be the future direction for C++ evolution?
Re garbage collection: My understanding was that the standard API was intended for interop with managed languages, not for pure C++ code to use, although I could be mistaken. I don't think garbage collection is entirely a lost cause, for instance Herb Sutter's work, which I think he wants to integrate in Cppfront, would be a great way to do it. Imo, his garbage collection ([1] [2]) could be much better than D or Nim, because it has easily controllable performance characteristics. You don't pay for it if you won't use it, and it's unlikely that libraries you pull in would need it, which is imo what makes programming without the "optional" GC in D and Nim difficult.
- Any guesses as to how C++ will turn out w.r.t. garbage collection?
-
Why do people want a garbage collector in C++?
Herb Sutter
-
New "Java to C++" code converter tool for beginners
Something like gcpp would be quite nice. That and a intelligent scope detector could make use of isolated and local GC when it detects that some objects stays together and have similar lifetime.
graph_ptr
-
Any guesses as to how C++ will turn out w.r.t. garbage collection?
Herb Sutter has an experimental implementation of a smart pointer like this called deferred_ptr. I have another implementation of something similar called graph_ptr, that I made for a toy functional language I was working on (because Herb Sutter's reference implementation of deferred_ptr was too slow for my purposes). I think my smart pointer's general design etc. is better than that specific implementation though, just because I am not an expert at this sort of thing.
What are some alternatives?
sgcl - Smart Garbage Collection Library for C++
convey - Layer 4 load balancer with dynamic configuration loading
pkg-fmt - Metadata to support C++ packaging
ergo - std-alternative prototyping / education library
cargo-script-mvs - Pre-RFC for merging cargo-script into cargo
NeatReflection - KISS C++20 Type Reflection using IFC files
carbon-lang - Carbon Language's main repository: documents, design, implementation, and related tools. (NOTE: Carbon Language is experimental; see README)
wg-allocators - Home of the Allocators working group: Paving a path for a standard set of allocator traits to be used in collections!
rust - Empowering everyone to build reliable and efficient software.