View Poll Results: Do you like Lisp's style?

Voters
8. You may not vote on this poll
  • Yes

    7 87.50%
  • No

    1 12.50%

Thread: Lisp-style Opinions?

  1. #1
    The Registered User Aparavoid's Avatar
    Join Date
    May 2009
    Posts
    74

    Lisp-style Opinions?

    What is your opinion on Lisp-style syntax? I personally think it is really nice but I can also see both sides.

  2. #2
    Banned ಠ_ಠ's Avatar
    Join Date
    Mar 2009
    Posts
    687
    (+ 1 2)
    is about as sexy as it can get
    ╔╗╔══╦╗
    ║║║╔╗║║
    ║╚╣╚╝║╚╗
    ╚═╩══╩═╝

  3. #3
    Registered User
    Join Date
    Sep 2001
    Posts
    4,912
    There's several main things I absolutely love about it, I may edit when I think of others. Being fairly new to Lisp, I still have a hard time reading it very well, but here are my thoughts:

    1) It's perfectly consistent. Everything is broken down into a list, or a list of lists, almost like how XML is tags, and tags inside other tags. It's a nice clean way of making complex structures in a consistent way. It's also like OO language where literally EVERYTHING is a first class object: functions, classes, programs, etc... In Lisp, everything is a list (or an atom - a single element list) I like consistency, and I like nested lists.

    2) Macros - they're awesome in Lisp. You can have a lot more creativity than you can with macro functions in C, or any other language I've seen.

    3) Very easy to implement a whole language - mainly because of the two features above.

    4) The ability to execute run-time generated code, and delay evaluation of a list


    One thing I don't like about it (and this would depend on the situation) is the amount of abstraction away from the system. I really like the way C (or more specifically the everything-is-a-file philosophy found in some UNIX-based systems) has abstracted things into files, where you can open, close, read from, and write to anything (again - I like consistency). To me, that's the perfect level of abstraction. But programming in Lisp, you don't consider what's happening at the physical/system level, like you do when you work directly with memory and pointers. I've seen Lisp enthusiasts argue that this is a good thing, but it still feels weird to me. I've also heard Lisp enthusiasts argue that this means some Lisp implementations can run faster than C - but I fail to fully understand the arguments there. Also, I don't care for the fact that there's no standard way of working with command-line-arguments, threads, etc... With so many dialects, etc... it's a much more confusing world than "Standard C". If I get serious about one dialect, it'll probably be CMU-CL, where I can still work with UNIX system calls.

  4. #4
    Cat without Hat CornedBee's Avatar
    Join Date
    Apr 2003
    Posts
    8,895
    I don't like Lisp's uniformness. There is no syntactic distinction between, well, anything. A function definition has exactly the same syntax as a condition handler as an addition. This means that distinction between such concepts is entirely reliant on programmer discipline, a good convention, and familiarity with that convention. The last point makes it hard for beginners to read, the first is simply unrealistic.
    Never got into the language, really. I prefer Haskell for my functional needs.
    All the buzzt!
    CornedBee

    "There is not now, nor has there ever been, nor will there ever be, any programming language in which it is the least bit difficult to write bad code."
    - Flon's Law

  5. #5
    Registered User
    Join Date
    Dec 2008
    Location
    Black River
    Posts
    128
    The deep nesting of parens is sometimes hard to grok, but otherwise, I love Lisp's regular syntax. I agree with sean in that Lisp macros are one of the most powerful tools in any language, basically allowing you to completely redesign the language (Something that practically requires prefix syntax).

  6. #6
    Officially An Architect brewbuck's Avatar
    Join Date
    Mar 2007
    Location
    Portland, OR
    Posts
    7,396
    Lisp syntax is very close to the lambda calculus, and that's intentional.

    The lambda calculus, being a tool for formal analysis and proof about computation, is probably not the best formalism to describe real world problems. Yet there are quite a few Lisp junkies out there.

    I never bothered to learn it beyond a little bit of dabbling in Emacs Lisp. One of these days I'll pick up OCaml or Haskell.
    Code:
    //try
    //{
    	if (a) do { f( b); } while(1);
    	else   do { f(!b); } while(1);
    //}

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. WM_CAPTION causing CreateWindowEx() to fail.
    By Necrofear in forum Windows Programming
    Replies: 8
    Last Post: 04-06-2007, 08:23 AM
  2. Button handler
    By Nephiroth in forum Windows Programming
    Replies: 8
    Last Post: 03-12-2006, 06:23 AM
  3. WS_EX_COMPOSITED style (double buffering) problems
    By JasonD in forum Windows Programming
    Replies: 2
    Last Post: 10-12-2004, 11:21 AM
  4. IDEA: LISP Interpreter
    By ygfperson in forum Contests Board
    Replies: 4
    Last Post: 09-13-2002, 08:48 PM
  5. Tab Controls - API
    By -KEN- in forum Windows Programming
    Replies: 7
    Last Post: 06-02-2002, 09:44 AM