Re: Web meeting: Datalog and Datahike

2019-10-19 Thread Daniel Slutsky
Video of the Scicloj meeting about Datahike we had on Monday: https://youtu.be/Hjo4TEV81sQ Many thanks to Konrad Kühne for the talk, Sami Kallinen for moderating, and Daniel Szmulewicz for some historical background he gave through the talk. On Thu, 10 Oct 2019 at 01:56, Daniel Slutsky wrote:

Re: Can't use my macro in fuction definition

2019-10-19 Thread rick
Macros also allow you to create a dsl to make your code easier to use or understand by obfuscating away bits. For example a macro that times a function call by proxying the call or wrapping a call to defn. That said, I consider many uses of macros that I’ve seen to be antipatterns that lead to

Re: Can't use my macro in fuction definition

2019-10-19 Thread Matching Socks
Macros manipulate program symbols. Macros fill the role that is filled by Perl scripts in the Java world, when they pre-process stuff (a database schema, or a gui model, for example) into actual Java code before you compile it. If a task could not be solved by pre-processing the source code b

Re: Can't use my macro in fuction definition

2019-10-19 Thread ru
суббота, 19 октября 2019 г., 17:15:23 UTC+3 пользователь Chris Nuernberger написал: > > Hey Ru, > > Renaming x to anything will result in roughly the same error in your > function. The problem is that your instance macro needs to know the > classname at compile time. As x is a runtime variab

Re: Can't use my macro in fuction definition

2019-10-19 Thread Chris Nuernberger
Hey Ru, Renaming x to anything will result in roughly the same error in your function. The problem is that your instance macro needs to know the classname at compile time. As x is a runtime variable, the compiler cannot see the literal value of x at compile time. Put another way, in your test f

Re: Can't use my macro in fuction definition

2019-10-19 Thread ru
Ok, Matching Socks. On what name should I replace the variable name "x" in the function definition so that the macro like it? суббота, 19 октября 2019 г., 14:09:01 UTC+3 пользователь Matching Socks написал: > > The macro is a code generator, with which the compiler computes the actual > defin

Clojure data science meetup: Berlin, Feb. 2020 -- survey

2019-10-19 Thread Daniel Slutsky
Scicloj is looking into organizing a Clojure data science meetup, close before ClojureD, on the end of Feb 2020 in Berlin. Are you joining us / interested? Please let us know -> *https://tinyurl.com/yyq8wgsm .* -- You received this message because you are subscrib

Re: Can't use my macro in fuction definition

2019-10-19 Thread Matching Socks
The macro is a code generator, with which the compiler computes the actual definition of the "test" function. What's there is x, and the macro does not like x. The REPL definition of JLabel worked because JLabel was the literal argument. See https://clojure.org/reference/macros, which is sub

Can't use my macro in fuction definition

2019-10-19 Thread ru
Dear Clojure users and team! I have defined a macros to get an instance of arbitrary Java class and tried to test it: ru@ru-iMacMint:~$ lein repl nREPL server started on port 46225 on host 127.0.0.1 - nrepl://127.0.0.1:46225 WARNING: cat already refers to: #'clojure.core/cat in namespace: net.