HN user

sarehu

34 karma
Posts0
Comments10
View on HN
No posts found.

It's my understanding that a theory of everything describes the rules by which the universe operates. It doesn't say anything about emergent properties of these rules.

For example, if everything in the universe obeyed Newtonian mechanics, I would say that Newtonian mechanics was a theory of everything. You would say that it isn't.

What about it? All Godel's incompleteness theorem says is that there will be open questions about a universe describable by finitely many rules. The laws of physics don't need to provide answers to questions about whether computers in its universe will halt or whether planetary systems are stable.

You can perfectly easily write with-foobar functions of any kind, so macros aren't a win there, except maybe in Lisp where it saves you a parenthesis or two. You can replice define-memoized-function with

   (define f (memoize (lambda args ...)))
so I don't see what macros gain you there. (Well, they save you from having to write lambda.) Especially if you're using a language with 'nicer' syntax, like Haskell:
    withFile $ \h -> do
      ...

    fib = memoize $ \n -> if n <= 1
                          then n
                          else fib (n - 1) + fib (n - 2)
Example (2) seems interesting though. And I'd like to see some examples of (3) that couldn't be so easily overcome. (Granted, my example is rather fake, since I don't know how you'd implement memoize for general types that only have a comparison function on them, without resorting to using some IO operation.)