Commit Graph

61 Commits (ca5d80189acb5e90cac9b599c4bb327ff9895dc3)

Author SHA1 Message Date
Daniel Kolesa ca5d80189a RangeOf template to get a range for the given type 2015-06-01 00:33:59 +01:00
Daniel Kolesa 51b210e1d6 cleanups 2015-05-30 01:46:50 +01:00
Daniel Kolesa 9f37057e51 cleanups 2015-05-30 01:09:13 +01:00
Daniel Kolesa cb1bf48aaa allow range traits to work on halves 2015-05-29 23:48:05 +01:00
Daniel Kolesa 3c6ef6e593 initial support for "range halves" ("range iterator") 2015-05-29 23:32:25 +01:00
Daniel Kolesa 15507e0143 remove useless equality/inequality operators on ranges 2015-05-29 21:49:07 +01:00
Daniel Kolesa a54db37a9c get const right on ranges 2015-05-29 20:21:35 +01:00
Daniel Kolesa 26f83b9efb pop_first() and pop_last() now return bool instead of void (true if popped, false if not) 2015-05-29 20:02:40 +01:00
Daniel Kolesa 38fc61481a initial support for "range extension" - i.e. push_first and push_last methods (+ push_first_n, push_last_n) 2015-05-29 19:52:20 +01:00
Daniel Kolesa 2f035f44ce simplify PointerRange more 2015-05-29 00:30:27 +01:00
Daniel Kolesa f96764fad0 simplify PointerRange 2015-05-29 00:01:24 +01:00
Daniel Kolesa a49716034e begin to_string infra 2015-05-28 02:38:52 +01:00
Daniel Kolesa 1371a32db7 use size() instead of length() 2015-05-27 23:19:16 +01:00
Daniel Kolesa 07881f2a4f octa::chunks 2015-05-27 20:56:44 +01:00
Daniel Kolesa d2f48ea0a5 octa::take 2015-05-27 20:45:34 +01:00
Daniel Kolesa 029575d4a6 add octa::each 2015-05-26 19:25:20 +01:00
Daniel Kolesa fe6325d5e3 check for input range before checking for put() - avoid potential false positives 2015-05-23 22:27:57 +01:00
Daniel Kolesa 329aefdecd IsOutputRange will now test for presence of the right 'put' method, enabling IsOutputRange tests on hybrid ranges (i.e. input ranges that satisfy output requirements) 2015-05-23 22:24:12 +01:00
Daniel Kolesa 7589a93539 add some traits to check range for range types including proper type inheritance 2015-05-23 20:33:08 +01:00
Daniel Kolesa 8908ac0506 new range category: FiniteRandomAccessRange 2015-05-23 20:00:03 +01:00
Daniel Kolesa b90fce8d84 Revert "add range difference type"
This reverts commit 4adbeb4e1b.
2015-05-23 17:56:08 +01:00
Daniel Kolesa 4adbeb4e1b add range difference type 2015-05-23 17:40:36 +01:00
Daniel Kolesa 9c3486903d add optional pop_first_n and pop_last_n methods on ranges 2015-05-23 17:36:26 +01:00
Daniel Kolesa 64810e4006 remove the noexcept stuff; nothing in octastd ever throws 2015-05-20 22:05:41 +01:00
Daniel Kolesa 6a8dec424a range fixes 2015-05-08 02:03:48 +01:00
Daniel Kolesa ff9c78c1d4 fix 2015-05-07 21:07:06 +01:00
Daniel Kolesa 98e7566ad9 coding style 2015-05-03 23:44:48 +01:00
Daniel Kolesa 2d10cd9280 ditch RangeTraits for alias definitions 2015-05-03 21:54:26 +01:00
Daniel Kolesa b1192b248c noexcept formatting 2015-04-29 01:38:16 +01:00
Daniel Kolesa 1a2d606ae7 noexcept the library 2015-04-28 18:48:58 +01:00
Daniel Kolesa de7ceba269 minor renames 2015-04-27 19:56:06 +01:00
Daniel Kolesa e98b8946ae define size_type for ranges 2015-04-27 19:53:48 +01:00
Daniel Kolesa d7778cf259 ditch the separate "type" struct 2015-04-27 19:38:34 +01:00
Daniel Kolesa f106c5ae24 get rid of namespace internal 2015-04-24 18:16:35 +01:00
Daniel Kolesa ff5fc7368d add EnumeratedRange + octa::enumerate 2015-04-21 17:58:36 +01:00
Daniel Kolesa 6807d22df5 satisfy OutputRange on MoveRange and PointerRange (might be mutable), add more algorithms 2015-04-21 17:56:36 +01:00
Daniel Kolesa ed0b28f2e0 add PointerRange constructor for pointer + length 2015-04-19 20:53:02 +01:00
Daniel Kolesa 58063fe392 add min, max, min_element, max_element in algorithm.h; rename VectorRange to PointerRange and move to range.h (useful as generic, e.g. with InitializerList) 2015-04-19 00:04:17 +01:00
Daniel Kolesa dc2dacaf5d add slicing for finite random access ranges 2015-04-18 22:05:24 +01:00
Daniel Kolesa 35424dd248 assignment op overloads for reverserange/moverange (c++ deletes them because of move ctor) 2015-04-18 20:31:07 +01:00
Daniel Kolesa 296b7cdeb9 move move/forward to utility.h 2015-04-18 00:11:16 +01:00
Daniel Kolesa 32d925d298 define support for OutputRange 2015-04-17 21:33:01 +01:00
Daniel Kolesa c9b7afc035 add NumberRange specialization for 1 argument (creates a "[0, v)" range) 2015-04-17 20:33:36 +01:00
Daniel Kolesa 1557c227d0 remove range traits pointer specializations, as a pointer is not a range... also remove the pointer member type 2015-04-17 20:29:38 +01:00
Daniel Kolesa 0116d3cf4c equality checking for NumberRange 2015-04-17 20:20:38 +01:00
Daniel Kolesa 37aa387734 use inheritance to guarantee iterable behavior (also shortens code) 2015-04-17 20:15:03 +01:00
Daniel Kolesa 83abf1d44b make RangeIterator more internal; strip down its unnecessary functionality; remove the iterator macro for standard containers; fixes 2015-04-17 18:33:41 +01:00
Daniel Kolesa e73a8344ab RangeIterator doesn't need a type {} structure 2015-04-17 02:19:40 +01:00
Daniel Kolesa 21ba9d025d add NumberRange 2015-04-17 00:55:50 +01:00
Daniel Kolesa bc35dad776 fix RangeIterator to use empty() 2015-04-17 00:15:20 +01:00