Carp icon indicating copy to clipboard operation
Carp copied to clipboard

Repl :t command doesn't work with (use)

Open ekzhang opened this issue 1 year ago • 3 comments

I think the REPL's :t command doesn't quite work as I would expect with namespaces that are opened!

Here's the output on carp-v0.5.5-x86_64-macos:

鲤 :t IO.read-file
=> (Fn [(Ref String <a>)] (Result String String) <StaticLifetime>)
鲤 (use IO)
鲤 :t read-file
I can’t find the symbol `read-file` at REPL:5:7.

Traceback:
  (type read-file) at REPL:5:1.

This is despite that I can otherwise call (read-file) directly after (use IO) works. The same happens in composition when I type use IO:

鲤 use IO
=> IO
鲤 :t (read-file "input")
Can't get the type of: (read-file "input") at REPL:2:7.

Traceback:
  (type (read-file "input")) at REPL:2:1.
鲤 :t (IO.read-file "input")
=> (Result String String)

But not with (use IO) — I'm not sure what the difference is here.

鲤 (use IO)
鲤 :t (read-file "input")
=> (Result String String)
鲤 :t (IO.read-file "input")
=> (Result String String)

ekzhang avatar Dec 03 '23 03:12 ekzhang

Is this project dead?

KoltPenny avatar Mar 26 '24 17:03 KoltPenny

@KoltPenny Hi, I wouldn't say that it's dead but it's very much on the back burner right now.

I'm the head maintainer of the project, and I'm currently working on a (commercial) game project (https://www.eriksvedang.com/2024/02/26/announcing-manahex.html), with more in the pipeline. I hope to be able to take the time off to work on "Carp 2.0" sometime in the future. Such a project was started, using LLVM, and it showed much promise but didn't reach feature parity with what's in this repo, and is thuse kept private for now. Until more active work is resumed, it seems unlikely that the project here will progress much. Feel free to try it out though, any feedback is appreciated! Even PRs could be interesting, as long as they're not too large.

Cheers, Erik

eriksvedang avatar Mar 26 '24 17:03 eriksvedang

@eriksvedang Thanks! Your new game looks great btw.

KoltPenny avatar Mar 26 '24 18:03 KoltPenny