TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Can Haskell power the next Ruby on Rails?

29 pointsby psibiover 11 years ago

3 comments

beatover 11 years ago
I&#x27;ve had similar thoughts about Clojure, as I&#x27;ve been using it for back end work rather than Ruby. Clojure has a lot of the same elegance I&#x27;ve come to love in Ruby, all wrapped in yummy functional goodness. Then again, as a dynamic language, it has many of the same shortcomings.<p>Scala has tried to go down the same route with the Play! framework. I tried it, but frankly, I found Scala very obtuse and difficult. I don&#x27;t like languages that make me feel like the biggest problem is that I&#x27;m stupid, because I know I&#x27;m not stupid (by contrast, when I hit ignorance-based problems in Clojure, the solution when discovered makes me feel smarter and makes the language look even lovelier). Scala reminds me uncomfortably of the things I don&#x27;t like about C++.
xiaomaover 11 years ago
I wonder what Justin would think of Scala?<p>I&#x27;ve seen rails programmers put Scala Play apps together at a good speed. While Scala doesn&#x27;t enforce Haskell&#x27;s pure functional paradigms, it does allow them. And it almost goes without saying that type safety was a top priority in its design.
programminggeekover 11 years ago
No, it can&#x27;t. Haskell is not a prototyping language.<p>Ruby (and more generally dynamic languages like PHP&#x2F;Python) are and Rails like frameworks are amazing tools for prototyping when you don&#x27;t know what you are building, need to iterate quickly, and need to prove out an idea. Dynamic languages are great for building things that are very dynamic, things that are in fact a kind of prototype.<p>Haskell and other languages with things like type checking and compilers and so on are designed to be safer, smarter, and are better long term for projects where the cost of complexity and maintenance are more significant and the development investment will get a payback.<p>If you don&#x27;t know if a project is going to work, you shouldn&#x27;t spend a huge investment to find out if it will work. So, use a tool like Wordpress, Drupal, Rails, Django, etc. to build out the minimum viable thing that you can build to prove out the idea and see if there is a real business there. Once you prove out the prototype and you know it is going to be a long term project that can pay for itself in terms of ongoing development investment, you need to throw the prototype away and build it with a tool like C#, Go, Java, Haskell, etc.<p>Most projects never realize they are no longer a prototype and should no longer be written in a prototyping language. Thus, you get all of the problems that come with a prototype without a lot of the solutions that we already have for solving them like compilers and such.<p>Interestingly, if you use a tool like Rails, there is enough there that you can get far past the point of a prototype before realizing it is no longer the right tool for the job. This is evidenced by the fact that there are now a ton of people talking about large project OOP and structure in Ruby and Rails, without them realizing that it&#x27;s always going to be an uphill battle in Ruby because of the language itself.<p>So, if the question is if Haskell can be the next great prototyping language, then I don&#x27;t think it is. If the question is if Haskell can be the language that you could migrate a project to after you realize it&#x27;s no longer a prototype, then yeah it might be.<p>Building a large production product with long term maintenance and scaling needs in a prototyping language is very likely a bad idea and is probably why there are so many projects that start to be really difficult in dynamic languages after they reach a certain size.
评论 #7280590 未加载