mit-scheme-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Patch, or Incident at Orthogonal Gulch


From: Clive Tovero
Subject: Patch, or Incident at Orthogonal Gulch
Date: Wed, 12 Aug 2020 14:55:48 -0400
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0

#ifdef HISTORICAL_CODE

// The source of the following code is obscure, and what we do know is
// somewhat apocryphal....

// "I found Scheming Pony out in the pasture.  He was wandering
// 'round, dazed-like.  I was a-hoping he didn't get into the locoweed
// agin.  He brayed at me like a mule, and I looked into his saddle
// bags.  There were a bunch of wanted posters in there--on the front
// was 'Wanted: Daid or Alive (perferbly daid), *Schemin' Pony* for
// inefficient code and repeatedly ignoring indentation standards.
// REward: One used copy of _The C++ Programming Language_'. On the
// back of each of the posters was a bunch of scribbled notes."
//
// "S.P. managed to tell me that he had written an essay on
// programming languages with the style and clarity of one R. Feynman,
// Ph.D.  It looked more like a bunch of stoopid malarky to me, but it
// weren't none too bad for a horse.  I was able to recover the most
// of the essay and code from Scheming Pony's notes.
//
// [Now I have to drift on before mit-scheme-devel *runs me off*, and
// the crew from emacs-devel ain't too far behind, neither]."
//
// --
// Clive Tovero, Cowhand, saddle tramp, and sometimes trail boss.
// Punxsutawney, Pennsylvania, Feb. 2, '93

// Dawn of a New Morning: "Defun" of C++ Programming
//
//  _________________________________________
// ( After another day of apparently living  )
// ( Bill Murray's "Groundhog Day 2:         )
// ( Implementing Eval/Apply", I realized    )
// ( there might be a cottage industry in    )
// ( "upcycling" old code (see attachment).  )
// ( The proposal is to modify existing      )
// ( "Greenspun's 10th" systems to get the   )
// ( last 20% of the complete Lisp we need.  )
// ( Make A Lisp might be an interesting way )
// ( to do this in practice--it is a Lisp    )
// ( implementation done in over 80          )
// ( languages, apparently inspired by       )
// ( Norvig's Lisp on Python. It might be    )
// ( useful for language interop, running a  )
// ( little Lisp REPL in each and talking to )
// ( each other over a socket. Then, if I    )
// ( could convince Stroustrup to add Lisp   )
// ( style macros to C++ and jettison the    )
// ( cruft (*I see a similar idea in Julia's )
// ( macros*), I could finally wake up.      )
// ( Regards.                                )
//  -----------------------------------------
//        o
//         o
//          o
//
//       (\     /)
//       % ^---^ %
//       %{ @ @ }%%
//        ( *** ) \%%
//        / ** /   \%%
//       / ** / |   \---
//       \oo/  |   sjm
//
//  -- Scheming Pony
//
//
// [enclosure]
//
// P.S. Multimethods in C++?
// https://parasol.tamu.edu/~yuriys/papers/OMM10.pdf
// Am I dreaming?

// Example using Open Inventor [BjarneLisp === two "basis"
// languages (akin to a mathematical basis), a restricted subset of
// C++ as used in Inventor, and a restricted subset of Lisp
// (cf. Femtolisp from Julia), crossed (again "think math") to give us
// more power (outside of the class of power gained by Turing
// completeness) with less complexity for our brains.  The rest of the
// code (and fixing my bugs) is left as an exercise for the reader.

// TODO: reread [ https://en.wikipedia.org/wiki/Greenspun%27s_tenth_rule ]

LispValue LispMachine::apply(LispValue args)
{
    // TODO: SICP here (estimated time to complete: 1/2 hour)
}

LispValue LispMachine::eval(LispValue args)
{
    // TODO: SICP here (estimated time to complete: 3/4 hour)
    // Hint: use Open Inventor's dynamic type system,
    // multimethods--AKA "Actions", (SbName::getClassTypeId() ===
    // LispSymbol::getClassTypeId()) with Femtolisp's reader. Don't
    // under any circumstances add templates--our macros will do that.
    // Also avoid Scheme-like templated macros.
}

#endif // defined HISTORICAL_CODE



reply via email to

[Prev in Thread] Current Thread [Next in Thread]