in reply to Re^7: How to completely destroy class attributes with Test::Most?
in thread How to completely destroy class attributes with Test::Most?
Does anything else call get_next_file? Do any subclasses override get_next_file? If both of those are "no", get_next_file could be merged into AUTOLOAD, improving performance by avoiding a extra method call for each file.
Independent iterators should not be much of a problem, although the semantics of ->selected_file get "interesting": it would only return the file most recently produced from the most-recently-used iterator, which could lead to confusion. The get_TYPE_files methods avoid this for programs that need to do their own iteration, but I suggest adding a reset_file_iterator method to allow iteration to be aborted rather than requiring 1 while $collector->get_next_file to be used.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^9: How to completely destroy class attributes with Test::Most?
by nysus (Parson) on Aug 27, 2019 at 23:56 UTC | |
by jcb (Parson) on Aug 28, 2019 at 01:33 UTC | |
by nysus (Parson) on Aug 28, 2019 at 13:31 UTC | |
by nysus (Parson) on Aug 28, 2019 at 19:21 UTC | |
by nysus (Parson) on Aug 28, 2019 at 19:46 UTC | |
by jcb (Parson) on Aug 28, 2019 at 23:25 UTC | |
|