1. 26 Jan, 2018 3 commits
  2. 25 Jan, 2018 4 commits
    • Mark Olesen's avatar
      ENH: improved swap/transfer methods for FixedList · d029f4c5
      Mark Olesen authored
      - the transfer method was previously a copy
      - use std::reverse_iterator adaptors in FixedList
        This greatly reduces the amount of code and now avoids the array-bounds
        warning for FixedList::rend()
      - use pointer arithmetic instead of dereferencing the internal array
    • Mark Olesen's avatar
      ENH: make hashedWordList movable · 8fc27e0e
      Mark Olesen authored
    • Mark Olesen's avatar
      ENH: remove Foam::Swap specializations for HashSet, HashTable · 915e8c9f
      Mark Olesen authored
      - without these will use the normal move construct + move assign.
        This is similarly efficient, but avoids the inadvertently having the
        incorrect Swap being used for derived classes.
      STYLE: remove unused xfer methods for HashTable, HashSet
      - unneeded since move construct and move assignment are possible
    • Mark Olesen's avatar
      ENH: allow early completion in PackedBoolList::used() · 7ee93afe
      Mark Olesen authored
      - can stop producing content when the target number of entries has
        been reached.
      - change return type to labelList instead an Xfer container.
        This allows return-value-optimization and avoids a surrounding
        allocation. This potentially breaks existing code.
      - make PackedList and PackedBoolList moveable. Drop xfer wrappers.
  3. 09 Jan, 2018 1 commit
  4. 27 Nov, 2017 1 commit
    • Mark Olesen's avatar
      ENH: several improvements for linked-lists · cc5f30f2
      Mark Olesen authored
      - support move construct/assignment for linked-lists themselves
        and when moving into a 'normal' list
      - better consistency with begin/end signatures and the various
      - for indirect linked-lists, provide iterator access to the underlying
        data element address:   iter.get()  vs  &(iter())
      - add standard '->' indirection for iterators (as per normal STL
  5. 22 Feb, 2018 4 commits
    • Mark Olesen's avatar
      STYLE: remove deprecated and unused ListOps · 3a4b92c4
      Mark Olesen authored
      - deprecated MAR-2017
          subset(const UList<T>& select, const T& value, const ListType&);
          inplaceSubset(const UList<T>& select, const T& value, ListType&);
        The subsetList/inplaceSubsetList variants with a unary predicate
        provide more flexible and robuster solutions.
      - deprecated MAR-2017
          initList(const T[mRows]);
          initListList(const T[mRows][nColumns]);
        Required prior to the addition of constructors with
    • Mark Olesen's avatar
      STYLE: consistent use of wordHashSet instead of HashSet<word> · 37e248c7
      Mark Olesen authored
      - the wordHashSet typedef is always available when HashSet has been
      - use default HashTable key (word) instead of explicitly mentioning it
    • Mark Olesen's avatar
    • Mark Olesen's avatar
      ENH: prevent conversion of string to regExp in stringListOps (closes #739) · ec38e7a4
      Mark Olesen authored
      * For most cases, this conversion would be largely unintentional
        and also less efficient. If the regex is desirable, the caller
        should invoke it explicitly.
        For example,
            findStrings(regExp(str), listOfStrings);
        Or use one of the keyType, wordRe, wordRes variants instead.
        If string is to be used as a plain (non-regex) matcher,
        this can be directly invoked
            findMatchingStrings(str, listOfStrings);
        or using the ListOps instead:
            findIndices(listOfStrings, str);
      * provide function interfaces for keyType.
  6. 21 Feb, 2018 3 commits
  7. 20 Feb, 2018 2 commits
  8. 19 Feb, 2018 2 commits
  9. 09 Feb, 2018 2 commits
    • Mark Olesen's avatar
      STYLE: simplify hashing to use struct instead of class · 3e3c9739
      Mark Olesen authored
      - more consistent with STL practices for function classes.
      - string::hash function class now operates on std::string rather
        than Foam::string since we have now avoided inadvertent use of
        string conversion from int in more places.
    • Mark Olesen's avatar
      BUG: incorrect HashTable / HashSet instances · 09a6e940
      Mark Olesen authored
      - Eg instead of using labelHashSet, used HashSet<label> which uses
        the string::hash for hashing. Other places inadvertently using the
        string::hash instead of Hash<label> for hashing.
      STYLE: use Map<..> instead of HashTable<.., label, Hash<label>>
      - reduces clutter
  10. 08 Feb, 2018 3 commits
  11. 29 Jan, 2018 2 commits
  12. 24 Jan, 2018 1 commit
  13. 23 Jan, 2018 3 commits
  14. 22 Jan, 2018 1 commit
    • Mark Olesen's avatar
      ENH: coding cleanup for memory streams · 23c9dd71
      Mark Olesen authored
      - simplify structure.
      - protect against nullptr when resetting memory streams
      - make UIListStream swappable
      - add uiliststream as an example of using a plain std::istream
  15. 19 Jan, 2018 1 commit
  16. 18 Jan, 2018 1 commit
  17. 17 Jan, 2018 1 commit
  18. 16 Jan, 2018 1 commit
    • Mark Olesen's avatar
      ENH: SubStrings::str(int) method for similarity with std::smatch · 12aa2d3c
      Mark Olesen authored
      - define regExp::results_type using SubStrings container for handling
        groups. This makes a later shift to std::smatch easier, but changes
        the regExp API for matching with groups. Previously had list element
        0 for regex group 1, now list element 0 is the entire match and list
        element 1 is regex group 1.
            List<std::string> mat;
            if (re.match(text, mat))  Info<< "group 1: " << mat[0] << nl;
            regExp::results_type mat;
            if (re.match(text, mat))  Info<< "group 1: " << mat.str(1) << nl;
  19. 15 Jan, 2018 3 commits
  20. 10 Jan, 2018 1 commit