I ended up going that way because around new wasn't welcome by the team. However, from my point of view caching a read-only object should be transparent to the user of the class as long as it's documented and there's a way to really instantiate a new object if one wants to.
In reply to Re^2: Caching a default instance to avoid initializing it every time (with Moo)
by Dallaylaen
in thread Caching a default instance to avoid initializing it every time (with Moo)
by Dallaylaen
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |