Hacker News new | past | comments | ask | show | jobs | submit | harryposner's comments login

> This would imply that you can jump into the same stack frame multiple times, or do other weird things.

Yep— this is how you can implement the `amb` operator with call/cc: https://ds26gte.github.io/tyscheme/index-Z-H-16.html


So the particular example here isn’t too different from exceptions. You’re unwinding the stack up to a predefined point— here, the callsite of foo, where with exceptions it would be up to the surrounding try/catch. Scala actually implements non-local returns (the only practical use I’ve had for call/cc) using exceptions: https://tpolecat.github.io/2014/05/09/return.html


You joke, and yet [Lucas 1988] uses an amusement park as a toy model to demonstrate how monetary shocks can affect real economic activity. The key difference between this and Chuck E. Cheese, though, is that Chuck E. Cheese is the only merchant that accepts their tokens for any sort of payment.

[Lucas 1988] https://home.uchicago.edu/~vlima/courses/econ203/fall01/Luca...


They do not exclude gas prices. The Consumer Price Index, which is what most people pay attention to and to which this article refers, currently weights gasoline at 3.7% of the basket of goods it tracks.

https://www.bls.gov/cpi/tables/relative-importance/2021.htm


Core CPI, which is what the Fed typically uses, excludes food and energy.


> But I haven't had a need to add any kind of plugin, and it's easy enough to fork a shell for an external process if needed.

For me, coming from writing Clojure with Neovim + vim-sexp + vim-fireplace, I would need Paredit and REPL integration.

Paredit is doable with Treesitter, and I'm actually really excited about Helix's Treesitter integration--- every time I write a non-Lisp language, I miss structural editing, so it'll be nice for other languages catch up to Lisp on that front. It doesn't really look like it's quite there yet, though. The built-operations that use Treesitter are spare [0], and while you could implement operations like promote, slurp, and barf with them, you'd have to clobber some register. I don't see at all how you could implement splice without an actual language, since you would need a way to select all siblings of the current node.

REPL integration absolutely needs a plugin language. Unlike the LSP, there isn't a standard protocol for communicating with a REPL, so each language requires its own REPL client. Unless they want to ship a REPL client for every language under the sun, they'll have to provide some way for users to implement their own clients. That said, every time I look at Conjure, they've added REPL clients for more and more languages [1], so maybe it is feasible to have it built into the editor.

[0] https://docs.helix-editor.com/keymap.html

[1] https://github.com/Olical/conjure/


> Paredit is doable with Treesitter

Yes, indeed.

Helix has built-in paredit-like navigation using tree-sitter, the default keybindings are alt-i, alt-o, alt-n and alt-p.

Maybe the Debug Adapter Protocol (DAP) used by vscode will solve the REPL issue in the future. Helix has experimental DAP support but it's still quite rough (but no Clojure DAP server yet).


From the beginning of SICP [0]:

> A powerful programming language is more than just a means for instructing a computer to perform tasks. The language also serves as a framework within which we organize our ideas about processes. Thus, when we describe a language, we should pay particular attention to the means that the language provides for combining simple ideas to form more complex ideas. Every powerful language has three mechanisms for accomplishing this:

> * primitive expressions, which represent the simplest entities the language is concerned with,

> * means of combination, by which compound elements are built from simpler ones, and

> * means of abstraction, by which compound elements can be named and manipulated as units.

Brainfuck is missing any sort of means of abstraction. The primitives are instructions, and the only means of combination is writing instructions in sequence, but there's no way in the language to refer to any sequence of instructions --- no functions, no subroutines, not even labels. This makes it utterly useless as a way to organize your thoughts on how to compute something.

[0] http://sarabander.github.io/sicp/html/1_002e1.xhtml#g_t1_002...


I’m not familiar with Erlang, but unless it has some really funky syntactic sugar, the Erlang examples aren’t tail-recursive. In all three, the continuation of the recursive call is the multiplication operation and not the conditional.


  user=> (rest '(3 . 4))
  (. 4)

  user=> (second '(3 . 4))
  .

  user=> (nth '(3 . 4) 2)
  4


Yes, I was wrong, my bad :)


An ascending price auction is strategically different from a second price auction when the bidders each have a noisy estimate of some underlying true value. With a second price auction, the only information you can incorporate into your bid is your own signal. With an ascending price auction, you can look at the prices at which the other bidders drop out (except the second highest bidder) and incorporate that information into the price at which you're willing to drop out. This also means that an ascending price auction raises more revenue than a second price auction, by the linkage principle.

https://en.wikipedia.org/wiki/Linkage_principle


Evidence by “That left Baidu, Google, and Microsoft. As the bids continued to climb, first to $15 million and then to $20 million, Microsoft dropped out too, but then returned. “. Microsoft could not have “returned” in a Vickrey auction


I didn’t read it as firing old people, but rather firing people for the plain old reason that they’re not doing a good job.


Consider applying for YC's Summer 2025 batch! Applications are open till May 13

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: