[a / b / c / d / e / f / g / gif / h / hr / k / m / o / p / r / s / t / u / v / vg / vm / vmg / vr / vrpg / vst / w / wg] [i / ic] [r9k / s4s / vip] [cm / hm / lgbt / y] [3 / aco / adv / an / bant / biz / cgl / ck / co / diy / fa / fit / gd / hc / his / int / jp / lit / mlp / mu / n / news / out / po / pol / pw / qst / sci / soc / sp / tg / toy / trv / tv / vp / vt / wsg / wsr / x / xs] [Settings] [Search] [Mobile] [Home]
Board
Settings Mobile Home
/g/ - Technology

Name
Options
Comment
Verification
4chan Pass users can bypass this verification. [Learn More] [Login]
File
  • Please read the Rules and FAQ before posting.
  • You may highlight syntax and preserve whitespace by using [code] tags.

08/21/20New boards added: /vrpg/, /vmg/, /vst/ and /vm/
05/04/17New trial board added: /bant/ - International/Random
10/04/16New board for 4chan Pass users: /vip/ - Very Important Posts
[Hide] [Show All]


🎉 Happy Birthday 4chan! 🎉


[Advertise on 4chan]


File: different-2943179577.jpg (33 KB, 500x359)
33 KB
33 KB JPG
>Lisp is a family of programming languages with a long history and a distinctive parenthesized prefix notation. There are many dialects of Lisp, including Common Lisp, Scheme, Clojure and Elisp.

>Emacs is an extensible, customizable, self-documenting free/libre text editor and computing environment, with a Lisp interpreter at its core.

>Emacs Resources
https://gnu.org/s/emacs
https://github.com/emacs-tw/awesome-emacs
https://github.com/systemcrafters/crafted-emacs

>Learning Emacs
C-h t (Interactive Tutorial)
https://emacs-config-generator.fly.dev
https://systemcrafters.net/emacs-from-scratch
http://xahlee.info/emacs
https://emacs.tv

>Emacs Distros
https://spacemacs.org
https://doomemacs.org

>Elisp
Docs: C-h f [function] C-h v [variable] C-h k [keybinding] C-h m [mode] M-x ielm [REPL]
https://gnu.org/s/emacs/manual/eintr.html
https://gnu.org/s/emacs/manual/elisp.html
https://github.com/emacs-tw/awesome-elisp

>Common Lisp
https://lispcookbook.github.io/cl-cookbook
https://cs.cmu.edu/~dst/LispBook
https://gigamonkeys.com/book
https://lem-project.github.io
https://stumpwm.github.io
https://nyxt-browser.com
https://awesome-cl.com

>Scheme
https://scheme.org
https://try.scheme.org
https://get.scheme.org
https://books.scheme.org
https://standards.scheme.org
https://go.scheme.org/awesome
https://research.scheme.org/lambda-papers

>Clojure
https://clojure.org
https://tryclojure.org
https://clojure-doc.org
https://calva.io
https://clojure.land
https://www.clojure-toolbox.com
https://mooc.fi/courses/2014/clojure
https://clojure.org/community/resources

>Other
https://github.com/dundalek/awesome-lisp-languages

>Guix
https://guix.gnu.org
https://nonguix.org
https://systemcrafters.net/craft-your-system-with-guix
https://futurile.net/resources/guix
https://github.com/franzos/awesome-guix

>SICP/HtDP
https://web.mit.edu/6.001/6.037/sicp.pdf
https://htdp.org

>More Lisp Resources
https://lisp.nexus
https://rentry.org/lispresources

(setq *prev-thread* >>106716971)
>>
Thanks for starting a new thread.
>>
File: 1711668374435133.png (133 KB, 400x400)
133 KB
133 KB PNG
>>106798388
(defun checked (n)
(let* ((abs (abs n))
(digits (mod abs 100))
(tens (floor digits 10))
(units (mod digits 10)))
(= tens units)))

(checked 106798388) => t
>>
>>106798425
no problem buddy
>>
>>106797917
What usenet newgroups are good to check out. Is comp.lang.lisp still alive?
https://eternal-september.org/
>>
File: gnus_20251005.11:22:13.png (250 KB, 898x816)
250 KB
250 KB PNG
>>106799675
I'm willing to give gnus a try, but I don't like how network requests block the UI.
>>
i find that i don't NEED paredit, smartparens, parinfer. snippets and evil too. when working with lisps, i just write parens first, code second, and move around code with c-m-k, arrows and c-s. when working with any other language, i have to occasionally use c-space c-w, but otherwise it's not different. it's pretty comfy.
>>
>>106798388
if you pretend to understand functional programming but have never heard of category theory, you're just a poser
>>
File: Land-Of-Lain.webm (1.1 MB, 1280x720)
1.1 MB
1.1 MB WEBM
>>
>>106798778
I raise you a
(defun checked (n)
(zerop (rem (mod n 100) 11)))
>>
>>106798778
What does let* do?
>>
>>106800798
It allows subsequent bindings to use previous ones.
>>
(((Lisp)))
>>
>>106800843
> McCarthy declared himself an atheist in a speech about artificial intelligence at Stanford Memorial Church.[33][34][35] Raised as a Communist, he became a conservative Republican after a visit to Czechoslovakia in 1968 after the Soviet invasion.
Lisp is the least Jewish language
>>
>>106800878
...
>>
>>106800889
Clisp is dead
>>
>>106800920
It is neither dead, nor truly alive.
A microcosm of the overall state of lisp in general, lol
>>
>>106800889
Lol, that’s real… who does that?
The more you know, eh?
>>
>>106801008
>CLISP has been using the menorah for the logo since the project was first started in the late 1980-ies by Bruno Haible and Michael Stoll. This probably reflects the authors' affection toward the Jewish people, Judaism or the State of Israel (neither of the two original authors is Jewish by birth).
The goodest of goys.
>>
File: '(smug-lisp).jpg (49 KB, 550x375)
49 KB
49 KB JPG
>>106800843
S-expression = (((Superior Expression)))
It's no wonder it's being adopted everywhere: GCC RTL, Tree-sitter, WASM...
>>
>>106801057
OCaml's build system uses S-expressions too
https://dune.build
>>
>>106794385
Thanks after more testing this is simpler
(defun map-buffer (func buffer)
(let ((result (generate-new-buffer "*map*")))
(with-current-buffer buffer
(save-excursion
(goto-char (point-min))
(while (not (eobp))
(princ (funcall func (buffer-substring-no-properties (pos-bol) (pos-eol))) result)
(terpri result)
(forward-line 1))))
(pop-to-buffer result)))

(defun process-csv (func buffer)
(map-buffer
(lambda (line)
(funcall func (split-string line ",")))
buffer))

(process-csv
(lambda (row)
(cl-destructuring-bind (name date value) row
(format "%s = %s" date value)))
(get-buffer "data.csv"))
>>
>>106800567
Nice, (mod (mod _ 100) 11) also seems to work for positive integers
>>
>>106801041
grim
>>
>>106802011
Just be thankful you were never like that.
>>
>>106801041
So, correct me if I’m wrong, but this would be like, suppose a regular israeli guy started the guile code. He decided to put up a big ascii-art depiction of the crucifixion every time you start guile?

So, that seems a bit bananas if you ask me.
>>
>>106801736
> (mod (mod _ 100) 11)
We need a (mood …) and a (moood …) defines for efficiency. I’ll draft a new srfi for all such things (e.g maap, leet, leeet, etc. and of course combinations like (rem(mod become reom and reod (they do the same thing).
>>
File: lisp-development.jpg (186 KB, 735x848)
186 KB
186 KB JPG
>>106802550
>>
>>106802725
Risupu
https://en.wikipedia.org/wiki/Lisp_(group)
>>
File: lisp_alien_smug.png (132 KB, 378x389)
132 KB
132 KB PNG
thread theme
https://youtu.be/WOVOJgLDVas?list=PL4PBIkIu5AtheHUzL5eNrktTmbhqGH8ev
>>
How do you organize your config style-wise?
My ad hoc solution I just came up with looks like this:
;;; Code:
;; === Section ===
;; = Subsection =
;; A comment.
() ; A margin comment.
>>
>>106804478
Why not something like org style?
I'm not organizing my .emacs, I've been carrying it forward since about 1987, the first one on 8" floppy
>>
>>106804478
I do comments and margin comments the same way you do.

I use a leading ";;;;" to mark major headings (which you're calling a section). I can then use consult-line and then type ";;;;" to give me a way to jump between headings quickly. I don't really do subsections, but if I wanted to, I think I'd increase the number of semicolons I use for them.
>>
>>106800798
>What does let* do?
Get in the habit of asking Emacs.
C-h f let* RET

let* is a special-form in ‘C source code’.

(let* VARLIST BODY...)


Bind variables according to VARLIST then eval BODY.
The value of the last form in BODY is returned.
Each element of VARLIST is a symbol (which is bound to nil)
or a list (SYMBOL VALUEFORM) (which binds SYMBOL to the value of VALUEFORM).
Each VALUEFORM can refer to the symbols already bound by this VARLIST.

‘let*’ is also a generalized variable.
Probably introduced at or before Emacs version 13.8.
This function has a ‘byte-compile’ property ‘byte-compile-let’ and a
byte-code optimizer ‘byte-optimize-letX’. See the manual for details.
>>
>>106805178
>Probably introduced at or before Emacs version 13.8.
never understood this. like what do you mean you're not sure
>>
>>106800023
>i find that i don't NEED paredit, ....
I don't need a girl with big tits, but it's nice when they're there.
>>
>>106799878
TIL gnus has its own site.
https://www.gnus.org/
>>
>>106805185
>never understood this. like what do you mean you're not sure
C-h f help-fns--first-release RET
C-h f help-fns--mention-first-release RET

If you look at the source for the first function, you can see that they guess the Emacs version number by examining etc/NEWS*.
>>
>>106805178
>Get in the habit of asking Emacs.
I'm thankful for the strong documentation culture in the Emacs community that makes this possible.
>>
Just tried using gnus for rss (nnrss backend). Can't believe it is this much shit. You get errors out the ass when you try to add an rss feed, and then open it. The ZeroHedge feed I added opened up in mml format, and not in nicely readable, elfeed-like format.

I give up. I think the only reasonable way to use gnus is
- newsgroups
- (maybe) email, but I am skeptical as mu4e handles my email needs like a champ without the whole Gnus "you gotta massage it" AUTISMO
>>
>>106805378
>strong documentation culture

right now this is what's stopping me from using Lem. 20 years of slowly documenting everything in it + a culture and community that fosters such a thing is incredibly powerful.
>>
>>106805570
>20 years
Isn't it more like 40 years?
>>
>>106805789
Oh yeah you're right.
>1985 was 40 years ago.
where did the time go bros...
>>
>>106804478
outline mode sir
>>
>>106805848
just tangle out from your init.org
>>
>>106805848
What is the value of your outline-regexp?
>>
Do you use use-package? Why not?
>>
>>106805911
I do. It's a reasonable way to declare a package dependency.
>>
>>106805869
default value sar
>>
>>106805864
every time I updoot either org, magit or roam breaks so I don't want to rely on them for by config.
>>
Sirs, what do you use for HTML editing?
nXML seems broken?
>>
>I need to install a lsp for each python env so eglot knows where things are
I hate my chud life
>>
>>106800889
Common Lisp is not CLISP you retard.
Common Lisp is a language, CLISP is a largely abandoned implementation of Common Lisp. Most active implementations of Common Lisp are mainly SBCL, ECL, Lispworks, and Allegro CL, with SBCL being by far the most popular in the Open Source community. There are no jewish symbols on SBCL nor on the other implementations.
>>
>>106806359
Which python env manager are you using?
>>
File: 1663974271223931.gif (2.77 MB, 512x293)
2.77 MB
2.77 MB GIF
>>106801057
This whole time I thought sexps was sex parens
>>
File: 1729938469827509.gif (2.59 MB, 498x277)
2.59 MB
2.59 MB GIF
How do I use Guile's statprof?
I put it around some code which returns a number, but it gives me the error "Wrong type to apply: 28172".
>>
existting dynamic systems are not enough (Smalltalk has shitty parallelism, Erlang and Common Lisp have no green thread inspection, only Erlang allows for OS-esque (what a VM ultimately boils down to btw, properly introspective VMs are akin to OS shells that are hyper-focused on the production of software and the analysis of running code).
static systems with modern type systems give you far more mechanisms to define and interact with in a deterministic, auditable manner.
>>
Been using dillo, haikuos, and modern emacs lately. Feels like the future that could have been. Main downside is 99% of the web is unusable. But that's probably a sign that we shouldn't use that part of the web anyway. Dillo has had a development resurgence in the last few years, and there are nice plugins for gopher / gemini including css. It's become my go-to for reading docs that are only online. I recommend checking out the reader mode plugin too. It makes certain websites that are otherwise broken easily readable.
>>
I want to write a lisp compiler/interpreter in assembly as a kind of ansi c alternative. So far I've thought about inverting the call stack so that
(+ (* 2 2) (* 3 3))

becomes something like
push add
push mul
push 2
push 2
eval
push mul
push 3
push 3
eval
eval


Storing the last function pointer in ebp and fetching arguments with [ebp - 4], [ebp - 8] etc. Compilers are new territory for me so any pointers or resources would be appreciated, especially in non C and non stack based function calling in assembly.
>>
>>106809540
>dillo
https://dillo.org/ - Is there a better place to look for info that the main site? A lot of links are broken.
>>
>>106809609
Nevermind, found up-to-date info.
https://dillo-browser.github.io/
>>
>>106807219
none. should I be using something other than python?
>>
>>106806619
autistic chud status - triggered
>>
>>106809599
- First that's not how stacks usually work. See Forth for example.
- Then that's really inefficient
If the functions aren't from variables you can inline their pointers and/or the call.
Then value reprensentation is pretty important. I'd recommend you look into NaN-boxing and how Guile does it for example (it's well explained in the last pages of their documentation).
And in general i'd recommend you mess a lot more with assembly and actually benchmark stuff, it helps you to design "from the bottom up" for efficiency.



[Advertise on 4chan]

Delete Post: [File Only] Style:
[Disable Mobile View / Use Desktop Site]

[Enable Mobile View / Use Mobile Site]

All trademarks and copyrights on this page are owned by their respective parties. Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.