Commit Graph

202 Commits

Author SHA1 Message Date
Louis Dionne
3d1b89a699 [Doc] Partially document external adapters 2015-06-08 18:38:03 -04:00
Louis Dionne
7a4919e69d [MonadPlus] Swap the arguments of prepend and prefix 2015-06-08 18:13:04 -04:00
Louis Dionne
bcdc8cf2cc [Doc] Add insert and insert_range to the Cheatsheet 2015-06-08 17:47:30 -04:00
Louis Dionne
92a2d425d3 [Doc] Minor documentation improvements and tweaks
- Move Functional to Details, to get more time to think about it
- Move Either to Details, to get more time to think about it
- Prettify some examples
- Better introduction of the "Data types" documentation module
2015-06-08 15:11:28 -04:00
Louis Dionne
9c2d3b396a Rename Maybe to Optional 2015-06-08 14:49:26 -04:00
Louis Dionne
406cb49cc2 [Doc] Daily documentation improvements
- Improve the brief description of make<XXX>
- Rewrite the rationale for unspecified container types
- Update comments on some runtime benchmarks
- Rename std::decay_t(...) to std::decay_t<...> in Tuple reference
- Document data types as being Tags, not types themselves
2015-06-07 14:35:08 -04:00
Louis Dionne
160a713f0a [Doc] Document the boost::hana::literals namespace 2015-06-06 11:07:17 -04:00
Louis Dionne
898e9aa07f [Doc] Improve the documentation as suggested by @tzlaine (Part 2)
- Extend the Quick Start with more small examples, and then the large
  switchAny example.
- Add clarifying remarks right in front of the CheatSheet for skimmers.
  Damn skimmers.
- Benchmark the compile-time of creating std::array
2015-06-05 18:47:41 -04:00
Louis Dionne
07f15e171f Normalize the parameter order of take, suffix, remove_at, cycle and repeat
Closes #83
2015-06-04 22:29:13 -04:00
Louis Dionne
077dc7b6c9 [Iterable] Normalize parameter order for at and drop
Partially addresses #83
2015-06-04 21:13:51 -04:00
Louis Dionne
35f25cbc35 [Doc] Implement improvements suggested by @tzlaine (part 1)
- Remove the preface entirely
- Move the current introduction to a "Description" section
- Move the "Quadrants of computation" to the "Introduction"
- Move the current "Motivation" section to the start of the "Introduction"
- Move the section on "Introspection" higher up in the docs
- Remove the "Concept" column in the Cheatsheet, and add links to each
  individual algorithm instead.
- Add a rationale for unpack's name and parameter order
- Add `fold` and `reverse_fold` to the cheatsheet
- Mention the list of all headers in the tutorial
- Add an alphabetical index with everything in the library
- Precise that smaller is better in chart subtitles
- Add benchmarks for std::make_tuple and std::get
2015-06-04 21:13:45 -04:00
Louis Dionne
c832df8b1e [Sequence] Add the unique{.by} algorithm
Partially addresses #52
2015-06-03 14:06:56 -04:00
Louis Dionne
8fd8129258 [Doc] Daily tutorial improvements
- Finish the section on "Introspection"
- Use a Boost "proposed" logo instead of the proper Boost logo
2015-06-02 23:52:57 -04:00
Louis Dionne
2d7ffed101 [Doc] Daily documentation improvements
- Add an "Acknowledgements" section
- Rename Boost.Hana to Hana for now (not officially a Boost library)
- Partially write the section on "Introspection"

Fixes #46
I feel like the documentation now provides enough real world examples:
- switchAny
- Euclidean distance
- JSON generation (to be written)
- MPL reimplementation
2015-06-01 18:06:28 -04:00
Louis Dionne
ac04435b60 [Doc] Daily improvement of the tutorial
- Merge section on Amphibian Algorithms with section on Algorithms
- Replace the `decayed` pseudo-code by `std::decay_t`.
- Rewrite and move section on type computations
- Add Appendix on the MPL implementation
2015-05-31 18:57:05 -04:00
Louis Dionne
cf3908622b [Doc] Write a section on compile-time numbers
Also
- move tricky content about constexpr to an appendix
- reorganize tutorial sections
2015-05-30 19:55:10 -04:00
Louis Dionne
cd38e0238a [Doc] Italicize words from the pseudo-code glossary.
Fixes #74, thanks @alexk7 for the initial suggestion at C++Now.
2015-05-28 19:26:00 -04:00
Louis Dionne
32d4c973e9 [Doc] Write new tutorial sections and reorder other sections
- Write sections on containers, algorithms, and runtime performance
- Make sure examples consistently use 2 space tabs
- Disable -Wunused-parameter for examples
- Resolves #70
  The requirement of pure functions is now documented.
- Resolves #14
  It turns out that the benefits of specifying the type of containers
  seems to be essentially limited to pattern matching. This is not
  enough to justify all the bad things it brings, especially
  considering the fact that recursion (currently the only use
  case for pattern matching) forces the creation of a new tuple
  at each step, which is disastrous. The unspecified-ness of the
  container's type is now documented.
2015-05-28 17:03:46 -04:00
Louis Dionne
68dfc99b11 [Doc] Improve the section on tag-dispatching 2015-05-26 11:51:53 -04:00
Louis Dionne
7f98ff0edd [Doc] Write a section about the different kinds of C++ computations 2015-05-25 16:27:16 -04:00
Louis Dionne
6718adbf5e [Doc] Rewrite the 'quick start' section of the tutorial 2015-05-25 10:16:48 -04:00
Louis Dionne
98a3c6658c [Benchmarks] Improve support for MPL11 and remove most homogeneous benchmarks 2015-05-05 18:46:00 -04:00
Louis Dionne
6ca6501278 [Searchable] Refactor the interface
- Rename elem to contains
- Rename subset to is_subset, and make is_subset applicable in infix notation
- Add the at_key method
- operator[] is now bound to at_key instead of find
2015-05-04 12:33:51 -04:00
Louis Dionne
6f9441fa7a [Tutorial] Fix formatting of header in the FAQ and a precision about charts 2015-04-26 14:19:43 -04:00
Louis Dionne
ca37fdfa4c [Doc] Add a section on performance in the tutorial
Also:
- Introduce the .js charts we have in the reference
- Remove the ugly "Generated by Doxygen" footer
- Refactor the benchmarks
2015-04-25 16:31:56 -04:00
Louis Dionne
f87919b94b [Record] Rename to Struct and refactor
- Define the notion of move-independence, thus relaxing the requirements on accessors.
- Rename `members` to `accessors` and use `members` to get the members only
- Document the different ways of providing a model
- Make the model of Foldable more consistent

Fixes #53
2015-04-21 16:32:33 -04:00
Louis Dionne
bdfeb46d88 Remove outdated TODOS 2015-04-07 21:41:54 -04:00
Louis Dionne
546d0dea7b [Tutorial] Remove redundant explanation of BOOST_HANA_CONSTANT_CHECK 2015-04-07 20:20:17 -04:00
Louis Dionne
0246c59c6c [Sandbox] Remove the hana/sandbox folder and put everything in test/sandbox 2015-04-07 16:52:20 -04:00
Louis Dionne
40216cde23 [MonadPlus] Add the remove and remove_if functions to MonadPlus 2015-04-07 16:27:39 -04:00
Louis Dionne
eb4f07a61c [Sequence] Use overloads for sort/sort_by and group/group_by 2015-04-01 19:28:42 -04:00
Louis Dionne
2c86ba2390 [Foldable] Rename the different fold variants
- Rename fold{l,r,l1,r1} to fold.{right,left} with overloads.
- Rename foldlM/foldrM to monadic_fold.{left,right}
- Add no-state variants of the monadic folds
- Improve the fold's documentation
- Deprecate the previous folds; they'll be removed soon

Fixes #18.
2015-03-30 17:29:37 -04:00
Louis Dionne
85e96017f2 [Tutorial] Add a pseudo-code glossary with proper formatting 2015-03-22 17:37:46 -04:00
Louis Dionne
740da060f4 Transfer some issues to GitHub so everyone can chime in 2015-03-22 13:51:49 -04:00
Louis Dionne
466bb3c1ad Add the Comonad concept and refactor Lazy 2015-03-20 11:55:32 -04:00
Louis Dionne
bc0212c712 [Example] Move the mini-MPL to example/misc 2015-03-15 00:18:31 -04:00
Louis Dionne
cde54c9ec0 [Foldable] Rename count to count_if and add count 2015-03-15 00:18:30 -04:00
Louis Dionne
ee329961b2 [Tutorial] Add a section on assertions 2015-03-13 12:14:35 -04:00
Louis Dionne
bd4daea264 Use models<Concept, T> instead of models<Concept(T)>, and check data types at the top level 2015-03-07 21:27:46 -05:00
Louis Dionne
471a9e3239 [Documentation] Minor fixes 2015-03-05 19:44:52 -05:00
Louis Dionne
00d1cac8d2 [Tutorial] Fix typo in cheatsheet 2015-03-05 14:04:06 -05:00
Louis Dionne
c93a250d87 [Constant] Make value a nullary method depending only on the type 2015-03-04 16:36:40 -05:00
Louis Dionne
8e9db82e28 [Tutorial] Move the cheatsheet after the quickstart, again 2015-03-04 14:38:48 -05:00
Louis Dionne
fb7cbdf13a [Sequence] Add missing examples 2015-03-04 14:30:41 -05:00
Louis Dionne
559c74e2dd [Tutorial] Wording tweaks 2015-03-04 13:10:17 -05:00
Louis Dionne
065b910128 Update copyright year. 2015-03-03 14:16:50 -05:00
Louis Dionne
fc12cee6e5 [Tutorial] Add sections on amphibian algorithms and semantics 2015-03-03 13:19:06 -05:00
Louis Dionne
37ab3ff31e [Tutorial] Rewrite the introduction 2015-02-27 14:04:36 -05:00
Louis Dionne
7e2bcdfee0 [ext/mpl] MPL vectors are not Sequences anymore 2015-02-27 11:34:21 -05:00
Louis Dionne
d7f58620ff [Example] Add a minimal implementation of the MPL 2015-02-26 12:35:06 -05:00
Louis Dionne
a46cd6a90c [Tuto + Functor] Document parameterized gtypes and pimp Functor's docs 2015-02-24 19:54:21 -05:00
Louis Dionne
cc5764bc7d [Cheatsheet] Arguments for elem were flipped 2015-02-23 14:54:33 -05:00
Louis Dionne
a25e84cf3b [Doc] Refactor the tutorial 2015-02-22 16:50:00 -05:00
Louis Dionne
9604c9a9f6 Replace List by Sequence 2015-02-20 11:05:43 -05:00
Louis Dionne
272ffa7900 Add the MonadPlus concept 2015-02-17 15:11:07 -05:00
Louis Dionne
02c9c47510 Remove TypeList and IntegerList 2015-02-15 12:38:04 -05:00
Louis Dionne
efd5aa9624 [Documentation] Rename group-typeclasses to group-concepts 2015-02-15 11:42:42 -05:00
Louis Dionne
17d2ce584c [Integral] Rename to IntegralConstant and improve the API 2015-02-10 20:03:49 -05:00
Louis Dionne
88549c004c [IntegralConstant] Remove the concept 2015-02-10 19:18:40 -05:00
Louis Dionne
4654c6786a Split instances for foreign types 2014-12-06 16:30:16 -05:00
Louis Dionne
8756e81977 Add boost/hana/config.hpp and BOOST_HANA_*_CHECK macros. 2014-11-10 17:52:33 -05:00
Louis Dionne
0f0c2c4430 Replace when<is_valid<...>> by when_valid<...> 2014-11-07 15:41:10 -05:00
Louis Dionne
049046478e Move ASSERT macros out of the details 2014-11-04 09:43:44 -05:00
Louis Dionne
40a7456bb1 Remove outdated TODOS. 2014-10-27 17:15:59 -04:00
Louis Dionne
cc8455dd65 Use the nested hana struct to instantiate unary type classes. 2014-10-27 16:14:02 -04:00
Louis Dionne
220d92ed82 Use a nested hana struct to customize stuff inside user defined objects. 2014-10-27 15:24:14 -04:00
Louis Dionne
716ff897cc Add the Enumerable type class. 2014-10-16 20:52:29 -04:00
Louis Dionne
c184a742fb Add compile-time strings 2014-09-30 10:23:45 -04:00
Louis Dionne
3bb1bb9c6b Allow instantiating unary type classes from a data type. 2014-09-08 22:39:10 -07:00
Louis Dionne
00642be684 Add the Either data type. 2014-08-26 15:09:51 -04:00
Louis Dionne
3692a7bb81 Add the IntegralConstant type class 2014-08-18 19:26:29 -04:00
Louis Dionne
307d3d0ec8 Huge reorganization and refactoring.
- Split type class instances into separate files
- Instances provided automatically by a type class are actually MCDs
- Test each instance in a single file, not one file per method
- Refactor the operator system to fix the ADL-related bug.
2014-08-18 19:26:29 -04:00
Louis Dionne
f2de95a841 Use detail::injection instead of a std::tuple in the tests 2014-08-16 14:25:57 -04:00
Louis Dionne
4c13c21f91 Add the IntegralDomain type class 2014-08-10 12:57:37 -04:00
Louis Dionne
f61ec22e11 Remove the Identity functor, which is now detail::Identity 2014-08-09 17:52:39 -04:00
Louis Dionne
cb9be38cf1 Add the Ring type class. 2014-08-09 09:45:33 -04:00
Louis Dionne
2b76377f91 Core: replace when_valid by when + is_valid 2014-08-07 22:38:54 -04:00
Louis Dionne
4df8c27cbb Finer grained use of operators 2014-08-07 21:05:38 -04:00
Louis Dionne
fecf7309d1 Add the Group type class 2014-08-07 17:01:22 -04:00
Louis Dionne
6c10ce440c Add the Identity functor. 2014-08-07 16:51:50 -04:00
Louis Dionne
474543ca14 Remove documentation for the laws.hpp headers of type classes.
This will be kept for internal use only.
2014-08-07 16:51:50 -04:00
Louis Dionne
b46db0bdc0 Add the Monoid type class 2014-08-07 16:51:49 -04:00
Louis Dionne
b6cef58ca1 Core: add are to make it prettier when there are many data types. 2014-08-05 19:52:44 -04:00
Louis Dionne
da8135ccec Foldable: flip the arguments of some methods 2014-08-05 19:52:44 -04:00
Louis Dionne
393cf06fb5 Tutorial: add a section on side effects 2014-08-05 14:44:02 -04:00
Louis Dionne
d4fde4f77a Documentation: refactoring and improvements in the tutorial 2014-08-04 18:44:38 -04:00
Louis Dionne
d6571e7681 Documentation: add indexes to the doxygen output 2014-07-31 18:15:27 -04:00
Louis Dionne
c382d9fca1 Tutorial: improve the section on data types 2014-07-31 16:31:56 -04:00
Louis Dionne
c85db2c4d2 Tutorial: make examples compilable 2014-07-31 15:09:34 -04:00
Louis Dionne
e9dfdeb57b Core: merge instantiates into is_a for the same functionality 2014-07-31 13:00:57 -04:00
Louis Dionne
b61dfc00a6 Core: document header structure and use when<> in datatype<> 2014-07-31 11:41:42 -04:00
Louis Dionne
c6f0420145 Functional: pimp the documentation 2014-07-30 15:21:39 -04:00
Louis Dionne
3488fe71cb Rename groups to avoid clashes when doing references 2014-07-30 11:23:38 -04:00
Louis Dionne
8a8ff797ab Split Core into subdirectories to reduce dependencies. 2014-07-30 11:15:26 -04:00
Louis Dionne
cf9c6ab821 Reformulation in the "getting concrete" section of the tutorial
Fixes #3.
2014-07-29 11:24:01 -04:00
Louis Dionne
8e0f4e10ed Fix broken link in the tutorial. 2014-07-29 10:19:50 -04:00
Louis Dionne
41d6b75bc2 Add the product Type class and make Pair a simple data type 2014-07-28 18:35:57 -04:00
Louis Dionne
74654d6159 Tutorial: Polishing and explain the reference 2014-07-28 12:52:27 -04:00
Louis Dionne
5f7e784899 Miscellaneous and minor documentation tweaks 2014-07-27 16:57:38 -04:00
Louis Dionne
08f8e5f1f4 Tutorial: Write section on data types 2014-07-25 22:42:07 -04:00