freenode/#lisp - IRC Chatlog
Search
20:36:51
charh
Hello! lispers, I have a beginner question. I am a systems administrator (Unix) and a beginner and autodidact.
20:37:01
charh
I write code in shell mainly. All my developments are related to operating systems. it's okay. but ... I want to be a true developer ... and I love Common Lisp as a language.
20:37:14
charh
I am reading practical common lisp, but finally I do not "click" with the development outside of an operating system
20:37:28
charh
My friends, my boss and any other people tell me "Do not learn lisp... is old and deprecated..., learn Java, Python, C, C ++, Rust ..." but I want Common Lisp, for me lisp is magic... I have a small code (in my git) and i love.
20:38:02
charh
yes, the question is more a suggestion from your experience, but i don't know any friend for talk o read about that.
20:39:01
trittweiler
I think you need to familarize yourself with a Common Lisp development environment. For example Emacs, and Slime (the Common Lisp editing mode)
20:40:21
trittweiler
The application design of Emacs can be quite illuminating by itself. (There definitely are other development environments, though, in case Emacs is just not your cup of tea)
20:41:18
charh
thanks trittweiler :), i have installed and configured (emacs + slime), I go to learnd (and read) more about that
20:41:26
Demosthenex
charh: i'm a systems guy too. CL is great for all kinds of backend tasks. python and java etc are for frontend stuff
20:43:34
Demosthenex
there's an analogy between learning lisp and latin. learning latin made you understand more about many different languages, it gave you depth, insight. lisp is the same
20:43:38
trittweiler
SICP (Structure and Interpretation of Computer Programs) is a very good book on learning the foundations of programming. It uses Scheme, a cousin of Common Lisp.
20:44:01
Demosthenex
with the exception where latin died off in usage, lisp is still used. all other languages are graduallying adding features lisp had many decades ago
20:44:26
trittweiler
there are also video lectures available from the 80s, which I found very enjoyable.
20:46:00
Demosthenex
i'm chafing over the gui and web frontends to everything. i'm tinkering with some personal apps that are often simple CRUD interfaces to a sql database. i don't want a gui, i want a curses based forms frontend
20:48:49
charh
oh ok, Demosthenex, fine! and thanks again :), any library for read and alternate between code and books?
20:49:17
trittweiler
If it's a good use of your time to learn Common Lisp is arguable. People in this channel would of course say yes. :) Python and Go would probably be more easily marketable skills (I think those are quite common in the devops world.) If your aim is to learn programming as a craft, Lisp will be a very good foundation like Demosthenex said
20:51:01
Demosthenex
ESR and other great programmers talk about a moment of enlightenment, where it just goes *SNAP* in your head and you gain insight. i was skeptical, but it's true
20:51:25
Demosthenex
absolutely changes your perspective when dealing with programming problems and other languages.
20:52:00
Demosthenex
i did a self study through "Practical Common Lisp" several years ago, it was time well spent.
21:00:19
Demosthenex
charh: use emacs. it'll open your eyes. plus it runs on lisp, so you can tinker anytime without needing a dev environment for little hings
21:03:58
charh
thanks Demosthenex :), I will search very information about emacs, your suggetions is goooood/great for me
21:05:58
Demosthenex
i have found Structured Terminal Forms Library (STFL), s-lang, ncurses forms, and others... but few bindings for cl.
21:26:03
whartung
emacs is all fine and good, but it doesn’t need to be the first step. You certainly don’t need Slime or anything fancy out of the box either. What you need, at a minumum is an editor that helps you with parentheses matching. Emacs will do that, but so will vi. emacs is nice because it’s got “lisp aware” indenting, which helps.
21:27:18
whartung
learning in a vacuum is all well and good, but it’s better if you’re trying to solve some problem. Computers without problems to solve are also known as “room heaters”
21:29:37
pjb
Yes, emacs is not necessarily the first step. But once you start using it, you'll always regret not having used it sooner.
21:30:20
pjb
I started using emacs in 1992, and I would have hit myself for not having started using it much earlier.
21:32:58
charh
whartung: my first step is a mix unix/CL and resolve problems outside shell scripting, I will rewrite my shell scripts in CL or the functionality
21:34:56
whartung
ok. That’s good. You might consider scsh — it’s a “Scheme Shell”, so, it’s a Scheme, not a Common Lisp, but it is designed to be a shell and has artifacts in place to handle things like sub processes and pipes and such.
21:35:37
whartung
that’s always been the problem I could never surmount in my “Lisp as shell” dabbling — finding a suitable usable pipe replacement, as it’s so engrained in the shell experience.
21:37:10
whartung
I edit with emacs, but that’s it. I leverage it’s autoformatting the most. I run Lisp in a separate window, and just continually reload my work. (defun l () (load “file.lisp”), and then just type (l) over and over (typiecally with REPL history ala readline)
21:38:15
whartung
I only say this as it’s one thing to want to learn from forms and the language, another to have to tool up an entire environemtn just to learn those forms and language — it’s not the same
21:38:49
charh
thanks whartung i was don't sure about scsh, but i will prove it! and read mooooore about emacs and CL :D
23:45:20
ebrasca
kenster: In serial experiments lain there where this virtual space with representations.
0:14:05
kenster
https://www.reddit.com/r/lisp/comments/8uxyg7/comfy_lisp_programming_project_wikify_episode_2/
0:23:12
zachk
Misha_B, you could try sorting both lists and seeing if they are equal, if they are sortable
1:00:28
kenster
ebrasca: I didn't see what you said but yeah I had to add that field to upload-session haha
1:18:24
ebzzry
Does any know why I get `Condition QL-HTTP::END-OF-DATA was signalled.` in Quicklisp?
7:38:30
joh11
if I called a function foo from the repl that calls another function bar, is there a way, when I recompile bar that foo automatically use the new version ?
7:38:59
pjb
This is not specified by the standard, but of course, one can design an algorithm to include in an implementation to do that.
7:39:21
pjb
Also, have a look at ibcl, you could implement it in an implementation independent way, as an add-on library.
7:39:34
pjb
https://www.informatimago.com/develop/lisp/com/informatimago/small-cl-pgms/ibcl/index.html
7:40:28
pjb
For functions defined in the REPL, this is already the case, it's automatic. Also, functions defined in different compilation units when compiled (usually different files).
7:40:55
joh11
Im just messing with sdl2 and wanted to leave my window opened while coding other stuff, this works with variables but not with functions apparently
7:41:29
pjb
joh11: said otherwise, the called functions are "hardwired" in the caller only when the called function is declared INLINE and not NOTINLINE, or when they're in the same compilation unit.
7:42:02
pjb
joh11: in the other cases, the calls go (semantically) thru the symbol-function, so if you redefine a function, it's taken into account next.
7:42:32
joh11
ok so if I mark foo as NOTINLINE, or place it in another file than bar it should work ?
7:43:21
pjb
If your program design depends on changing the function definition at run-time, do declare it NOTINLINE.
7:44:57
pjb
so about FUNCTION, FDEFINITION, SYMBOL-FUNCTION, the thing is that they return the function object. If you store it somewhere, and redefine the function, then those old function objects are still used.
7:45:22
pjb
This is one important difference between (apply (function foo) args) and (apply (quote foo) args).
7:46:29
pjb
In the first case, the function object is passed, in the second case, the symbol FOO is passed. In the later case the APPLY function will call SYMBOL-FUNCTION itself, so if the definition of FOO has changed, APPLY will use the last fbinding, ie. the redefinition.
7:47:01
pjb
Assume the function or object are not passed directly, but stored somewhere before the call.
7:48:20
pjb
For example, if you play with reader macros: (set-macro-character #\^ 'reader-macro-for-^) is better while developping it and testing it, because just redefining the function is enough for the reader macro to take it into account. With (set-macro-character #\^ #'reader-macro-for-^) you will have to re-evaluate this form each time you modify the function.
7:49:50
pjb
Ie. if you write a HOF (high order function, a function that takes functions as arguments), instead of restricting it to functions (checktype fun function), you should allow function designators (deftype function-designator () `(or function symbol)) (checktype fun function-designator)
7:56:48
joh11
ok so I moved bar to another file but now I have another problem : my (format t "test") are not displayed