freenode/#lisp - IRC Chatlog
Search
8:13:03
equwal
Is there a reason why (defun test (x) (declare (ftype (number) number)) x) doesn't do the same thing as (defun ... (the x))?
12:30:21
lionrouge
because learning a language that is not supported at programming olympiads is not fun
12:31:03
jackdaniel
I would think that an interactive environment is much more pleasent to work with. Common Lisp transpiled to C doesn't work anything like C person could write
12:31:45
jackdaniel
as of ECL it won't work in that scenario, becasue C sources depend on a runtime library libecl.so
12:31:58
lionrouge
here in Russia there are several online platforms which are used to conduct programming olympiads. It's a major factor of motivation.
12:33:00
jackdaniel
I think that if teaching language supported by these platforms is a hard requirement, and these platforms do not provide lisp of any kind, you should pick another language
12:33:33
jackdaniel
working on transpilet source code is no fun nor a productive task (unless you are the compiler implementer, then you may find some joy in looking at these innards)
12:34:34
lionrouge
nobody will look at the transpiled code - whether it works and don't go over limits on CPU time and memory are the only things that matters
12:35:49
heisig
lionrouge: It is a shame that these competitions do not support modern Lisp compilers. A workaround might be to use a Lisp interpreter written in another language, like http://norvig.com/lispy2.html.
12:36:00
ogamita
lionrouge: there are several. clicc (free software), mocl (http://wukix.com commercial), ecl has been mentionned, but it uses C only as an assembler, you wouldn't maintain the generated C code.
12:36:55
ogamita
lionrouge: mocl works, but it only implements a subset of CL, so you cannot quickload random libraries and hope they will work. For newly written code targetting mocl, it is ok and works well.
12:37:51
jackdaniel
this is not a lisp descendant per se, but it works on s-expressions and (afair) has macros
12:38:10
lionrouge
confusedwanderer: thanks for Chicken Scheme! I heard of it some time ago but forgotten about it
12:39:53
ogamita
lionrouge: however, if you want to be able to maintain the C code, have a look at: https://github.com/informatimago/lisp-vs-c
12:40:17
lionrouge
what makes me sad if that these platforms do include modern languages: there is Go, D, Rust and even Kotlin ! And they are open-minded enough to even include OCaml and Haskell
12:41:14
ogamita
lionrouge: ie. "source equivalence", or "human reader equivalence" is of no use with C. (+ a b) and a+b are two totally different operations.
12:41:39
lionrouge
I wrote a letter to one (no answer yet). I think I should ask the other one (the third one has so much problems maintaining the server that it's definitely not in plans)
12:43:23
ogamita
lionrouge: there are automatical programming judges that support lisp. http://spoj.com does IIRC.
12:44:21
lionrouge
thanks ! But it has only English localization - it's often a problem for 13yo kids
12:46:55
lionrouge
ogamita: you mean including all the problems? I don't have that much time unfortunately
12:47:32
ogamita
Oh, right, there's not only the web site. And furthermore, some problem deal with text, so the solutions would have to be different too, they'd be different problems.
12:49:38
lionrouge
the other problem is that participants often are not allowed to have any electronic devices with them - only paper materials (language manuals, cheatsheets,etc.). And in order to use something like Chicken Scheme they need it installed somewhere to produce C code
13:02:36
elderK
lionrouge: I definitely support the use of Chicken Scheme. It's a fantastic Scheme implementation and compiles to C. It does, afaik, require you to link with libchicken although I'm pretty sure you can static link if desired. You might want to check out #chicken here on Freenode. Fantastic bunch.
13:06:36
ogamita
elderK: well the same is true of ecl. In #lisp we'd advise ecl rather than chicken…
13:09:32
ogamita
In CL there are no dialects, there are subset or superset of the CL language. There may be supersets of subsets of CL.
13:11:16
ogamita
otherwise, to confuse more: Have a look at (intersection common-lisp emacs-lisp scheme) http://www.informatimago.com/develop/lisp/com/informatimago/small-cl-pgms/intersection-r5rs-common-lisp-emacs-lisp/
13:15:12
beach
confusedwanderer: I think ogamita is referring to the fact that the channel topic is Common Lisp, not Lisp in general.
13:50:24
jcowan
No, there aren't. I had the ambition to make one using the Kawa framework (on the JVM), but then I got sidetracked by this R7RS-large stuff
13:52:41
Odin-
jcowan: I've wondered if there's an element of "might as well just do CL" to it, because cursory examination seems to indicate implementing ISLISP is kind of equivalent to implementing a fair portion of CL with no major incompatibilities...
13:54:36
Odin-
ogamita: And no substantial upgrades every decade or so, either, with compiler support lagging a version behind. :p
13:55:04
jcowan
EuLisp is a marginal case: if it were written "EU Lisp" it would definitely violate the stricture. As is, it can be read "European Lisp" or even "the good Lisp". :-)
13:56:07
jcowan
The main thing about ISLisp is that it's a static language. My CL-R effort is meant to be a kind of upgrade of ISLisp to full compatibility with CL.
13:57:33
ogamita
Now a nice tool would take a CL asdf system, and note all the non-ISLisp elements in the code.
13:57:53
Odin-
jcowan: Except EuLisp doesn't have anything to do with the EU, so debatable whether it applies. Otherwise Common Lisp kinda falls foul as well...
13:59:49
jcowan
ogamita: It's not so simple: ILOS is different enough from CLOS to make mere annotation insufficient.
14:00:51
Xach
heisig: http://report.quicklisp.org/2018-11-29/failure-report/petalisp.html shows many fresh problems for me
14:03:34
Xach
I got all new components for a Quicklisp build server, assembled them, and it won't boot. So I am now running quicklisp dist builds on a backup iMac via virtualbox.
14:04:00
Odin-
jcowan: The name EuLisp seems to be a few years older than the EU, funnily enough. :p
14:04:03
Xach
In the meantime I am looking for a PC speaker to maybe get beep code diagnostics. The case I got doesn't have one (maybe it's no longer common?)
14:06:37
Xach
dlowe: Interesting. I don't think the manual mentions one and I don't see one, but maybe I overlooked it.
14:45:35
ogamita
pfdietz: you can't complain that clisp is maintained and evolves, and complain that it is not and does not at the same time!
14:45:50
pfdietz
Let's make gratuitous changes to exported interfaces. What could possibly go wrong?
14:47:24
jackdaniel
yup, it is very tempting to clean up the exported interfaces to match better (for instance) a grand new refactored internals, but then half of the world breaks
14:50:22
ogamita
Otherwise, any time to win the lottery, you can put a few million on the table to clean the messes up quickly…
14:52:24
ogamita
jackdaniel: the bad half, the evil half that used foreign internals! Let them break and fall!
14:52:26
jackdaniel
changing names of exported interaces without a warning is breaking the contract between the API producent and consumer
15:22:40
jackdaniel
pfdietz: quick hack: you may call register-local-projects from sbcl and /then/ start clisp
15:24:10
Xach
i'd like to see something that is smarter - something that compiles the matching and does it *before* converting the pathnames to lisp strings.
15:36:11
Xach
the lights light up, the fans spin, but no display on DVI or HDMI. responds to power switch as expected.
15:36:41
jkordani_
xach: do you even have a list of beep codes? the manual is a little sparse on troubleshooting steps. Good luck
16:34:20
sjl_
> It is often useful to define multiple systems in a same file, but ASDF can only locate a system’s definition file based on the system name. For this reason, ASDF 3’s system search algorithm has been extended to allow a file foo.asd to contain secondary systems named foo/bar, foo/baz, foo/quux, etc., in addition to the primary system named foo.
16:34:59
pfdietz
clisp is not finding a name that follows that convention. Must be an older asdf version.
16:52:00
Bike
Hello again for stupidly obscure question time: is append with one argument an identity, and if so, can't the append method combination be :identity-with-one-argument t?
17:15:20
luis
TIL that each of APPEND's argument must be a proper list except the last, which may be any object.
17:23:09
jcowan
The idea is to think of 42 as an improper list with 0 elements. So 0 elements + 0 elements with a tail = 0 elements with a tail.
17:34:43
TMA
luis: the real trick is to implement your own APPEND-2 as an exercise and only then ponder about (append '(a b) 42)
17:38:16
jcowan
indeed, Scheme's list library has three predicates list?, circular-list?, and improper-list? that exhaustively partition all objects; note that they are O(n).
17:50:51
fiddlerwoaroof
This behavior of append reminds me of "modern" alist operations in ACL2 for some reason
17:50:54
fiddlerwoaroof
http://www.cs.utexas.edu/users/moore/acl2/manuals/current/manual/index-seo.php/ACL2____STD_F2ALISTS?path=3212/6222/289/3804