Closed
Bug 463260
Opened 16 years ago
Closed 12 years ago
Want smart pointer template for new features
Categories
(Core :: JavaScript Engine, enhancement)
Core
JavaScript Engine
Tracking
()
RESOLVED
WONTFIX
People
(Reporter: dmandelin, Unassigned)
References
Details
Since we're using C++ for new features in SpiderMonkey, it would be really nice to have a smart pointer template to simplify local resource management. Can we use auto_ptr? Or is there some other existing thing we can use?
Comment 1•16 years ago
|
||
By all means try to use standard C++. Let the porting porblem children emulate or acquire std impls of auto_ptr if lacking. /be
Comment 2•16 years ago
|
||
We should look at the code gcc generates for auto_ptr. I ave very limited faith in gcc's code quality for complex C++ code.
Comment 3•16 years ago
|
||
Definitely should look at machine code -- we do for our own templatized smartptr helpers (nsCOMPtr, etc.) and they work on GCC. /be
Comment 4•16 years ago
|
||
TR1 also contains a nice family of 'em (shared_ptr and weak_ptr, in addition to old auto_ptr), and are msvc / gcc supported.
Reporter | ||
Comment 5•16 years ago
|
||
TR1 seems to have a lot of nice stuff. Can we really start using it?
Updated•16 years ago
|
Severity: normal → enhancement
Comment 6•12 years ago
|
||
A family of home-grown SM smartpointers have sprung up in meantime. shared_ptr/weak_ptr throw on alloc failure and, even if they didn't, we probably don't need to be using non-intrusive thread-safe smartpointers in SM anyhow.
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → WONTFIX
You need to log in
before you can comment on or make changes to this bug.
Description
•