Front Page All Articles Recent Changes Random Article

Contents

Concatenative language

  • ACL
  • Ait
  • Aocla
  • Breeze
  • Callisto
  • Cat
  • Cognate
  • colorForth
  • Concata
  • CoSy
  • Deque
  • DSSP
  • dt
  • Elymas
  • Enchilada
  • ETAC
  • F
  • Factor
  • Fiveth
  • Forth
  • Fourth
  • Freelang
  • Gershwin
  • hex
  • iNet
  • Joy
  • Joy of Postfix App
  • kcats
  • Kitten
  • lang5
  • Listack
  • LSE64
  • Lviv
  • Meow5
  • min
  • Mirth
  • mjoy
  • Mlatu
  • Ode
  • OForth
  • Om
  • Onyx
  • Plorth
  • Popr
  • Porth
  • PostScript
  • Prowl
  • Quest32
  • Quackery
  • r3
  • Raven
  • Retro
  • RPL
  • SPL
  • Staapl
  • Stabel
  • Tal
  • Titan
  • Trith
  • Uiua
  • Worst
  • xs
  • XY
  • 5th
  • 8th

Concatenative topics

  • Compilers
  • Interpreters
  • Type systems
  • Object systems
  • Quotations
  • Variables
  • Garbage collection
  • Example programs

Concatenative meta

  • People
  • Communities

Other languages

  • APL
  • C++
  • Erlang
  • FP trivia
  • Haskell
  • Io
  • Java
  • JavaScript
  • Lisp
  • ML
  • Oberon
  • RPL
  • Self
  • Slate
  • Smalltalk

Meta

  • Search
  • Farkup wiki format
  • Etiquette
  • Sandbox

Concatenative language/Simplicity

Good concatenative code is simple. When beginners first start learning a concatenative language, they often get lost in a sea of stack shufflers and overly complex code.

In the Factor community, we encourage beginners to post their code in the pastebin, so that we can review it and suggest idioms, abstractions and library words they can use to make the code simpler, shorter, and more readable (these three often go hand-in-hand: see Concision).

Slava wrote a blog post analyzing prevalence of shuffle words and combinators in the Factor source tree. The more complex shuffles, such as rot and roll, are only used a few dozen times in the entire code base (consisting of tens of thousands of lines), so indeed they are more of a crutch for beginners than a real tool that serious concatenative language programmers advocate using. Good code has simple data flow and does not need stack gymnastics. Factor's optimizing compiler, web framework and UI toolkit do not have any complex shufflers at all, and together they comprise some 30,000 lines of code.

This revision created on Sat, 3 Jan 2009 01:40:02 by slava

Latest Revisions Edit

All content is © 2008-2024 by its respective authors. By adding content to this wiki, you agree to release it under the BSD license.