Win a copy of GANs in ActionE this week in the AI forum
or WebAssembly in Action in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Paul Clapham
  • Jeanne Boyarsky
  • Knute Snortum
Sheriffs:
  • Liutauras Vilda
  • Tim Cooke
  • Junilu Lacar
Saloon Keepers:
  • Ron McLeod
  • Stephan van Hulst
  • Tim Moores
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Joe Ess
  • salvin francis
  • fred rosenberger

Real-life Clojure examples

 
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Clojure's fully functional paradigm is a big shift for many people, including myself. My experience with functional languages comes from OCaml in university, and programming along SICP using Scheme/Racket. What are some good open-source Clojure projects that I could study to learn common idioms, techniques, and how larger projects are actually structured?
 
Rancher
Posts: 436
2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Toby Matejovsky wrote:Clojure's fully functional paradigm



Am I wrong or does Clojure use functional elements but is not a "fully" (i.e. pure) functional language (same with Lisp)?
 
Rancher
Posts: 175
Clojure Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Hauke Ingmar Schmidt wrote:

Toby Matejovsky wrote:Clojure's fully functional paradigm

Am I wrong or does Clojure use functional elements but is not a "fully" (i.e. pure) functional language (same with Lisp)?


I believe Clojure is a full-fledged Lisp dialect that also provides robust support for existing Java libraries. This means it is less hybridized than, say, Scala.

As a result, it's possible to use Clojure to develop a Swing app (see for example this slideshow) without deviating from Lispy syntax and functional conventions.
 
Hauke Ingmar Schmidt
Rancher
Posts: 436
2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sure, but Lisp itself is not a pure or fully functional language.
 
David Byron
Rancher
Posts: 175
Clojure Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Hauke Ingmar Schmidt wrote:Sure, but Lisp itself is not a pure or fully functional language.

Hence "less hybridized". ;)
 
clojure forum advocate
Posts: 3479
Mac Objective C Clojure
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Hauke Ingmar Schmidt wrote:

Toby Matejovsky wrote:Clojure's fully functional paradigm



Am I wrong or does Clojure use functional elements but is not a "fully" (i.e. pure) functional language (same with Lisp)?


Niether Clojure or Lisp are pure functional programming languages, not like Haskell any way.
As for the original poster, Github hosts tons of Clojure project. I'm pretty sure you will get some projects that you will like and learn a lot from them.
 
Toby Matejovsky
Greenhorn
Posts: 4
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That's fair, "fully functional" was the wrong description of the language. https://github.com/languages/Clojure is a good starting point to explore clojure projects.

Are there any specific ones that you (all) have found interesting?
 
Ranch Hand
Posts: 100
VI Editor Chrome Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Toby Matejovsky wrote:That's fair, "fully functional" was the wrong description of the language. https://github.com/languages/Clojure is a good starting point to explore clojure projects.

Are there any specific ones that you (all) have found interesting?



Bump for good Clojure code examples specific recommendations.

Thank you.
 
Rancher
Posts: 352
21
Mac OS X Monad Clojure Linux
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This comes up fairly often on the Clojure mailing list and the consensus seems to be that the Clojars project is a fairly good example to look at.

Toby's pointer to github projects written in Clojure is a good general place to start but I suspect most "real-life" Clojure code, at an application level, is behind corporate firewalls right now with only the libraries out in public. I'm hoping to open source some of the Clojure code that my company is creating but it may be a while before that happens (and, to be honest, much of that would really only be higher-level libraries built around other stuff).

It may just be too early in Clojure's cycle for a substantial amount of open source _application_ code.
 
Hussein Baghdadi
clojure forum advocate
Posts: 3479
Mac Objective C Clojure
 
What could go wrong in a swell place like "The Evil Eye"? Or with this tiny ad?
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!