Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.0
    • Component/s: Engine
    • Labels:
      None

      Description

      would be nice if #foreach would do close the iterator if it implements Closeable. This will allow better resource management when using foreach to do things like run sql queries, etc.

      1. foreach.diff
        0.9 kB
        Robert Fuller

        Activity

        Hide
        claude Claude Brisson added a comment -

        commited, with the additional precaution that if #foreach is given the iterator itself, it shouldn't be closed

        Show
        claude Claude Brisson added a comment - commited, with the additional precaution that if #foreach is given the iterator itself, it shouldn't be closed
        Hide
        fullergalway Robert Fuller added a comment -

        example implementation attached.

        Show
        fullergalway Robert Fuller added a comment - example implementation attached.

          People

          • Assignee:
            Unassigned
            Reporter:
            fullergalway Robert Fuller
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development