cljs-dev

ClojureScript compiler & std lib dev, https://clojurescript.org/community/dev
dnolen 2019-11-19T00:48:41.350600Z

was a bit busy today - just updated changes and cutting a release now - but let's do the post tomorrow

alexmiller 2019-11-19T00:59:34.351500Z

fyi, now that gh is past the beta period, we are still working out getting the cognitect accts set up billing wise so I'm building sites manually again, so you'll need to ping me to publish

dnolen 2019-11-19T01:02:32.351700Z

k

eltonlaw 2019-11-19T05:54:33.355600Z

Hi, I'm encountering some weird behaviour and was wondering if this was a bug, for this code

(defmacro foo [x & args]
  (println "&form:" &form)
  (println "&env:" &env)
  (println "args:" args))

(foo 1 2 3 4 5 6)
in clojure:
$ java -jar clojure.jar
Clojure 1.11.0-master-SNAPSHOT
...
user=> user=> (foo 1 2 3 4 5 6)
&form: (foo 1 2 3 4 5 6)
&env: nil
args: (2 3 4 5 6)
nil
which makes sense, but in clojurescript looks like this:
$ ./script/repljs
ClojureScript 1.10.598
...
cljs.user=> cljs.user=> (foo 1 2 3 4 5 6)
&form: 1
&env: 2
args: (4 5 6)
nil

thheller 2019-11-19T10:04:26.357Z

@eltonlaw296 macros for CLJS are defined in CLJ. did you just use defmacro in the REPL? if so it'll be called as a regular function which will "eat" the first two args as &form and &env ending up with your result

eltonlaw 2019-11-19T11:36:31.358700Z

ah yea, I was using defmacro in the repl, I see I understand now thanks for clearing that up!

borkdude 2019-11-19T12:33:57.360Z

I ran into an issue with the analysis order in CLJS once: https://clojure.atlassian.net/browse/CLJS-2949 Funny enough to mention that I made the same "mistake" in a Clojure interpreter: https://github.com/borkdude/sci/issues/164

borkdude 2019-11-19T12:39:09.360600Z

what's up with this though?

$ clj -e '(def x 1) (declare y) (try (assert (pos? x)) (def y (+ 1 2 x)) y (finally (assert (pos? y))))'
#'user/x
#'user/y
4
$ plk -e '(def x 1) (declare y) (try (assert (pos? x)) (def y (+ 1 2 x)) y (finally (assert (pos? y))))'
Execution error (Error) at (<cljs repl>:1).
Var is not a function (near '...$test:null)])));})()...')

mfikes 2019-11-19T13:00:44.360900Z

Probably just a bug in Planck https://github.com/planck-repl/planck/issues/1022

mfikes 2019-11-19T13:01:24.361500Z

(It doesn’t happen with the Node or browser REPLs.)

borkdude 2019-11-19T13:06:50.361800Z

Ah right, it doesn't happen in a plk REPL, only with -e

borkdude 2019-11-19T13:08:48.362200Z

$ clojure -Sdeps '{:deps {org.clojure/clojurescript {:mvn/version "1.10.520"}}}' -m cljs.main -re node -e '(def x 1) (declare y) (try (assert (pos? x)) (def y (+ 1 2 x)) y (finally (assert (pos? y))))'
#'cljs.user/x
#'cljs.user/y
4

mfikes 2019-11-19T13:09:14.362600Z

Updated release notes to indicate 1.10.597: https://github.com/clojure/clojurescript-site/pull/332

borkdude 2019-11-19T13:24:14.363400Z

I notice that Herald is only a single first name (or last name). Is it incomplete?

dnolen 2019-11-19T13:44:51.363800Z

@mfikes looks good, feel free to merge

mfikes 2019-11-19T13:45:40.364300Z

@dnolen Merged

dnolen 2019-11-19T13:47:27.364700Z

@alexmiller please push the publish button whenever you get a chance 🙂

mfikes 2019-11-19T13:50:05.364800Z

I did my best to find the name of that contributor. That’s how his/her name is listed on GitHub

alexmiller 2019-11-19T14:05:31.365200Z

pushing...

alexmiller 2019-11-19T14:07:45.365400Z

done

dnolen 2019-11-19T14:09:28.365600Z

thanks!

borkdude 2019-11-19T14:46:38.365900Z

maybe an announcement on https://twitter.com/cognitect? 🙂

alexmiller 2019-11-19T15:42:08.366200Z

is everything official now?

borkdude 2019-11-19T16:30:12.366400Z

@alexmiller I guess so https://twitter.com/swannodette/status/1196824318442909696

alexmiller 2019-11-19T16:42:08.366800Z

https://twitter.com/cognitect/status/1196830919417618434

🎉 4