5 ms·
To me Eiffel and its pre/postconditions are clearly inferior to Dependently Typed languages like Idris. (Also check Agda, Liquid Haskell...)
by pezo1919 7y ago
To me Eiffel and its pre/postconditions are clearly inferior to Dependently Typed languages like Idris. (Also check Agda, Liquid Haskell...)
- carapace 7y agoWhy?
- pezo1919 7y agoBecause you can express these conditions and check compile time instead runtime.
- pjmlp 7y agoSome contracts can be checked at compile time, if enough information is present. In fact one of the design decisions driving C++ contracts, which now will probably only show up in C++23 due to some last minute issues, is how the optimizer can take advantage of contracts while generating code. Languages like Idris are quite interesting for us on HN, but I seriously doubt that the kind of developers that languages like Eiffel are targeted to, would be able to take advantage of them with their current tooling state.
- vyjcgtyjb 7y agoContracts will not be in C++23 and certainly not in C++20.
- ncmncm 7y agoC++26, if then. There were no actual issues. At the last minute a bunch of people came up with a bunch of incompatible complexifications in support of <1% uses, and that added enough confusion to kill it. Much of the confusion came from people afraid that the optimizations might be bad. Now the same people who came up with the complications are driving the redesign, with no clear goals or unifying architecture, and no participation by the original designers. Don't expect to see contract support anytime soon.
- pezo1919 7y agoCan you tell me what kind of contracts can be checked compile time? (I assume you did not just mean types asserts.) What I've read about Eiffel on many sites is only runtime check (on more advanced constraints).
- elviejo 7y agoExcept for the little fact that Eiffel has had those features since 1986. Agda first release was in 2007 Idris also in 2007 Liquid Haskell thesis was published in 2016
- pezo1919 7y agoNote the words "to me".