>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 Resourceshttps://gnu.org/s/emacs
https://github.com/emacs-tw/awesome-emacs
https://github.com/systemcrafters/crafted-emacs
>Learning EmacsC-h t (Interactive Tutorial)
https://emacs.amodernist.com
https://systemcrafters.net/emacs-from-scratch
http://xahlee.info/emacs
https://emacs.tv
>Emacs Distroshttps://spacemacs.org
https://doomemacs.org
>ElispDocs: 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 Lisphttps://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
>Schemehttps://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
>Clojurehttps://clojure.org
https://tryclojure.org
https://clojure-doc.org
https://www.clojure-toolbox.com
https://mooc.fi/courses/2014/clojure
https://clojure.org/community/resources
>Otherhttps://github.com/dundalek/awesome-lisp-languages
>Guixhttps://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/HtDPhttps://web.mit.edu/6.001/6.037/sicp.pdf
https://htdp.org
>More Lisp Resourceshttps://rentry.org/lispresources
(setq *prev-bread*
>>105652614)
Gensokyo Emacs 4tw
https://youtu.be/RPeFQwBFURk?t=1623
>>105712003it has the lisp primitives as stated by John McCarthy, unlike clojure.
>>105712003My favorite Lisp is Pyramid Scheme
https://esolangs.org/wiki/Pyramid_Scheme
>>105712003>>105712042>common lisp>isn't common
>>105711000Claude is 100% better at programming elisp than Chatgpt shit. Yesterday I cried and kneeled. I made my own package at once. Ngl It was magical.
(ba-bomb-sh-ka)
https://babashka.org
>>105711984try unix ed written in chicken scheme
https://github.com/nmeum/edward
>>105712313Um...
http://xahlee.org/p/um/um.html
>>105711980 (OP)I wish I were a girl too
>>105712747>girlI'd just like to interject for a moment. What you're referring to as Girl, is in fact, GNU/Virgins, or as I've recently taken to calling it, GNU plus Virgins.
>Then if you become a hacker you can celebrate that by having a foobar mitzvah, a ceremony in which the new hacker stands in front of the assembled congregation of hackers and chants through the lines of the system source code. And we also have the cult of the virgin of emacs. The virgin of emacs is any female who has not yet learned how to use emacs. And in the church of emacs we believe that taking her emacs virginity away is a blessed act.https://archive.is/urcla
>>105712747No judgement on anyone but how many people here have unironic gender dysphoria? I just want to get an idea.
>>105712939what kind of person unironically wants to be male?
>>105712939nil
lisp hackers are always chads
>>105711980 (OP)i'm just trying Racket and its gui lib and it's pretty cool so far, i didn't expect a decent GUI out of most languages.
did anybody else try it? i'm willing to switch to a web interface eventually. should i just use web with Racket from the start or stick to the native GUI?
MIT
md5: 151bb54643ba8d3e5c6741eca748cdcd
🔍
Why did MIT dumb down its basic CS course 6.001 in 2008?
>>105713462the people got dumber
>>105713462Metacircular interpreters are useless
SUSsman
md5: 63b6019327bc77d3e4a9d7b39cc5fe4f
🔍
>>105713462Sussman is still scheming with SICP at MIT
https://groups.csail.mit.edu/mac/users/gjs/6.945/
>>105713848I love this retarded shit.
>>105713527This. People got dumber and standards of educational have been correspondingly depressed.
>>105713462old courses like sicp are now obsolete. today, programmers will never start from zero but will have to compose with libraries, sdks and ai.
>>105713741SICP isn't about utility. It's not a coding bootcamp that spits you out the other end ready to fuck up some corporate codebase. It is obtuse because it teaches computation itself. Scheme was chosen not because it's the most commercially competitive language but because it can teach you how to think like a machine.
>>105715041I think it's probably gonna take twenty years for people to really understand this, but I'm confident that you're wrong.
>>105715239that's sussman and abelson opinion; they talked during the last racketcon and said sicp was no more adapted to the kind of development you would do today. Sussman was trying to get rid of the sicp course at MIT for more than ten years when they finally ditched it.
>>105715194I think you perceive "usefulness" in a very narrow sense. IMO, metacircular interpreters are useless, but that's not because they're weird and obscure and can't be used for yet another JS framework, that's because there is literally no use for them (at least I'm not aware of one). In comparison, a lot of weird&obscure stuff is much more useful (and also very beautiful) - like Futamura projections or abstract interpretation or linear logic.
Maybe you think that metacircular evaluators are helpful for learning, but in my experience, implementing λ-calculus in Prolog was much more enlightening compared to implementing λ-calculus in λ-calculus. I think people should focus less on chapter 4 and more on chapter 5. Or perhaps different people are enlightened by different ideas in different proportions. Then we should try to predict the student's flavor somehow and give him a book that fits him better.
>>105712136That’s more due to a rising population of imbeciles.
>>105713741>>105715593>metacircular>uselessWrong. GNU Mes uses a metacircular evaluator to achieve the full-source bootstrap of Guix. It's very useful.
https://www.gnu.org/software/mes/manual/html_node/LISP-as-Maxwell_0027s-Equations-of-Software.html
https://guix.gnu.org/en/blog/2023/the-full-source-bootstrap-building-from-source-all-the-way-down/
gnu_lain
md5: 5e2511e6340a78027dd7eb089ef99008
🔍
>>105715993Technically, when you bootstrap something, you implement a different language, so that's not true metacircularity.
When you say "this implementation is metacircular" you don't provide much value over just saying "this is an implementation of X in X". The only interesting fact you can deduce from here is that this implementation can be safely thrown away if you actually use it somewhere. There is no point in such implementations. The actual meat is in implementing something different. And the greater the difference, the better, since it shortens your bootstrap chain when you go from assembly to a high-level language.
And there is no "beautiful" metacircularity in the Mes sources. Or at least I was unable to find definitions similar to those in your first link with quick grepping. Everything is based on primitives implemented in C.
Also, I think that while full-source bootstrapping is nice to have in some abstract sense, it's not a complete solution. Or, to be more precise, it is a solution on a software level, but in practice, you also must rely on your hardware and trust the chip producer (be it chip designer or chip fabber or someone in between).
>>105716313>>105715993I've been studying metacircular evaluators and just figured out how the binary lambda calculus self reductor works.
I'd say the biggest benefit to doing it is just showing how dead simple a programming language is. You can implement lambda calculus in like 3 lines of itself.
The point of doing this is that it lets you reason about how a language works without ever having to touch an implementation or learn another lower level language.
It also exposed me to a lot of type theory stuff incidentally which was interesting. It's a perfect academic method for introducing programming at it's core and lets you start off simple and add more and more language features in simple intuitive ways without ever falling into low level bullshit. So far I've gotten into lambda calculus, type theory, logic programming, and computability all through metacircular evaluators!
Finally it means once you understand the high level self evaluation, you can just translate that directly into a low level interpreter instead of working it out step by step. Also it makes porting incredibly easy. Like how I learned about interaction combinators and how they can be run massively in parallel automatically for huge speedups over C code.
>>105716677>You can implement lambda calculus in like 3 lines of itself[citation needed]
>>105716677>Like how I learned about interaction combinators and how they can be run massively in parallel automatically for huge speedups over C code.Requesting explanation.
>>105717314>https://anthonylorenhart.com/2021-09-04-Extremely-Simple-Self-Interpretation/ λ[Y[λ[λ[λ[
1[λ[λ[4[1][λ[λ[0[2][4]]]]]]]
[λ[1[λ[λ[λ[1[λ[7[4[λ[λ[λ[0[3]]]]]][λ[λ[1]]]]]]]]]
[λ[4[1[0]]]]]]
[λ[1[0][λ[4[λ[λ[λ[0[λ[λ[λ[2[7][10[6][λ[λ[1]]]]]]]]]]]]]]]]
]
]]][0][λ[λ[1]]]]
Though it's simpler to read it as
app = λ[λ[λ[λ[λ[2[4][3]]]]]];
lam = λ[λ[λ[λ[1[3]]]]];
var = λ[λ[λ[λ[0[3]]]]];
spine (app a b) l = spine a (b:l)
spine (lam f) (a:l) = spine (f a) l
spine (lam f) [] = lam (λ x . spine (f (var x)) [])
spine (var x) (a:l) = spine (var (app x (spine a []))) l
spine (var x) [] = x
>>105717373>https://zicklag.katharos.group/blog/interaction-nets-combinators-calculus/>https://github.com/HigherOrderCO/HVM/blob/73da3bbc4b222fb8f044fcc5dad202e9752a0abc/HOW.mdBasically interaction combinators are a model of computation like lambda calculus, only they're a graph instead of a tree and are evaluated in parallel instead of serially. They're entirely general and turing complete, and there's a GPU runtime that can process them with thousands of threads at a time. The base interpretation is about 10x-100x slower than conventional languages, but then you add in 10,000 threads running in parallel and suddenly it's an order of magnitiude faster than even optimized machine code(for massively parallel algorithms, it's still slow as balls for serial operations)
>>105717725There's also some other interesting shit related to/based on interaction combinators by the same guy.
There's a statically typed formal proof checker based on construction calculus(perfect for the static compilation autist who posts here occasionally), though hilariously it's written in 400 lines of PVRE JAVASCRIPT.
Also I'm like 90% sure that the type inference system in that can be repurposed into a logic programming language. And the major point of the entire thing is that it allows breaking beta reduction into O(1) steps, meaning it can be implemented in hardware, solving the entire graph reduction accelerator problem at the root.
Oh also the entire thing is automatically seamlessly garbage collected in parallel(the deletion operation is just one of the base primitives and runs like any other instruction deleting all unused data).
after about a day of deliberating whether i want to learn common lisp or scheme (racket) as my first lisp, i decided to commit to the latter.
my question is this: does it really even matter? is the difference between the two even significant when it comes to learning lisp as a whole? i mean, they're both lisp at the end of the day, right?
>>105717910It's basically the same, 80% of the time the only difference is aethetic(scheme usually loots "neater"), the other 20% of the time it's just which has the libraries you want(common lisp has quicklisp which is king of convenience)
Then all the dozen or so schemes are basically identical but all have incompatible library/hardware/compiler support.
I use common lisp, but literally ONLY because I like the emacs mode better than the one for scheme.
>>105717910Pure scheme is a meme. You are 99% will end up with an implementation-specific features to do any real work. At that point, you might as well as using CL.
>>105718021>implementation-specific featuresi'm not sure what you mean by that. do you mean features of the language that i would have to implement myself as opposed to relying on a library? isn't that sort of the whole point of lisp?
>>105718107It means every implementation of scheme is actually a slightly different language. Basically "scheme" doesn't really exist, there's just racket/gambit/chicken/chez/etc...
It's like lisp pre common lisp.
>>105717910Racket is great. Also, Felleisen's books are great.
https://felleisen.org/matthias/books.html
Even Cloudflare uses Racket extensively nowadays.
https://blog.cloudflare.com/topaz-policy-engine-design/
In scheme if you want to set 2 or more variables whose values all depend on the same condition, which way would you use? Or are there other ways?
;; Method A
(let ((a (if c something-a something-else-a))
(b (if c something-b something-else-b))
...)
...)
;; Method B
(let ((a #f)
(b #f)
...)
(if c
(begin
(set! a something-a)
(set! b something-b)
...)
(begin
(set! a something-else-a)
(set! b something-else-b)
...))
...)
;; Method C
(let-values (((a b ...)
(if condition
(values something-a something-b ...)
(values something-else-a something-else-b ...))))
...)
>>105716677>You can implement lambda calculus in like 3 lines of itself.If you are talking about something like this:
(define (e expr env)
(match expr
(('λ arg-name body) (λ (arg) (e body (λ (name) (if (eq? name arg-name) arg (env name))))))
((f arg) ((e f env) (e arg env)))
(var (env var))))
then I think it's a bad example. Here functions of the object language are represented via functions of the metalanguage (the part with (λ (arg) ...)). Depending on the semantics of your metalanguage (specifically, how it handles closures) you will implement different languages. The metacircularity allows you to "cheat" and don't specify the semantics of your object language in enough detail. In contrast, implementing λ-calculus in a different enough language (say, assembly or Prolog) forces you to explicitly state that closures copy the environment in which they are created (or do not copy, if you're making something like C with GCC extensions for nested functions instead of λ-calculus). Of course, you can do that as well in λ-calculus but then implementing λ-calculus in λ-calculus doesn't grant you anything and is not special in any way.
>>105719431Honestly I would use the method that looks better in the particular case. Probably A if I have only 2-3 variables, B if something-a etc. are huge expressions and C if they're small expressions. It's only a matter of taste.
>>105719494>probably Ano, C is always the correct choice here. it minimizes conditional checks. it makes state transition explicit (this situation is literally what VALUES is for).
>>105719494>implementing λ-calculus in λ-calculus doesn't grant you anything and is not special in any way.It's useful as a learning exercise. It's a decently varied and complicated program both to implement and read, but simple and short enough to be reasonable.
The whole point of lambda calculus is that it's extremely minimalist, which means writing an interpreter is much faster than any other language, and doing it in itself means your effort isn't split into learning two things at once.
Then lambda calculus has all sorts of interesting variants with type systems and proofs, etc... which you can now also try implementing the same way, it's a good stepoff point.
>>105719645But there is only one condition check in B as well? Also if you think that using two/three ifs instead of one is significant overhead that may matter somewhere, you should provide a benchmark. Or, if we are in that kind of discussion (low-quality argument about performance without any concrete code and godbolt links), I can just say that CSE will factor out condition if it's not just some variable (you ARE using an optimizing compiler, aren't you?) and branch predictor will have no trouble choosing the correct branch and in modern processors it's extremely hard to say whether one extra instruction is harmful or helpful without looking at the surrounding code.
>it makes state transition explicitI'm not sure I completely understand what you mean by "state transition" but presumably B makes it explicit too?
>(this situation is literally what VALUES is for)It looks like R7RS says nothing about how values or let-values should be used, only defines their behavior. There is no provided rationale.
The problem with method C in my opinion is that it's hard to see which expression corresponds to which variable, especially if they're big or if there are lots of variables.
>>105719802I'm in nicotine withdrawal so sorry if I come across as an asshole. B is absolutely trash of an option, it requires the programmer to scan the body of the LET to even determine that A and B are being set. this is a core complaint that I have with any imperative language, where you can enter however many levels of scopes and have absolutely zero idea of what shit is being mutated without checking every individual line.
functional, immutable languages require the programmer to explicitly return changed values from their scopes such that upper scopes must explicitly assign to those changes. when the programmer loops at the assignment, he knows exactly what variables will be changed without needing to consult any of the lower scopes, which massively aids readability.
I do not give a fuck about the performance, I give a fuck about DRY, where you are needlessly repeating a conditional call.
as for the spec not discussing the "purpose" of values, I do not give a fuck about that either. its purpose is able to be inferred quite easily by anyone with over a decade of experience programming.
>>105719431Definitely A, there's all sorts of ways to do this(macros, closures, mutation, etc...)
But really what are you saving? FOUR CHARACTERS "(if)" per variable?
And in the process making everything really confusing and weird for no reason. The macro is actually the least insane method and it's obviously massive overkill.
(shr-dom-to-xml `(html ((lang . "en"))
(head ()
(title () "Generate HTML with Elisp"))
(body ()
(h1 () "Hello"))))
Undocumented but useful;
>>105717725>only they're a graph instead of a treeall trees are graphs, a tree is just acyclic, rooted, and connected
>Q: Outside the C family of languages, what language(s) do you like the best? What in particular makes them interesting to you?
>Ritchie: I have to admire languages like Lisp. But, just as in the earlier question about a "simple" language, an astonishingly simple language grows in practice into something that can be fearsome.
>Stroustrup: Algol68, CLOS, and ML springs to mind. In each case, what attracts me is flexibility and some very elegant code examples.
I honestly do not understand how Bjarne could say he admired CLOS but then he implemented C++ classes in almost the most antithetical way possible.
>>105722355I think C++ predates CLOS, so (to be charitable to Bjarne) maybe he's admiring what CLOS did differently.
That CL trading book is really interesting, but he glosses over some stuff and the code is not that great imo. Clearly the guy is rich and got rich of trading, but I'm basing myself in his ideas and writing a clearer agent based trading thing.
Reposting the window scripts for anyone who hasn't seen them, and while I'm at it, I'd like to ask more about emacs documentation standards. I've always been fairly good about inline comments, and I try to write my code in a way where you can infer a lot from context, but docstrings have always been something I'm an utter nigger about. I also can't rely on my own intuition with Elisp, as I'm a newfag at it.
What are the minimal criteria in your opinions about docstrings, and what separates an okay docstring from a great one?
Thanks
https://pastebin.com/rgMtnRhd
https://pastebin.com/nsmmvTat
SAD
md5: 7a4da5a558d0b7632f2a261108ed3f54
🔍
>>105712003>>105712042>Smug Common Lisp Weenies gatekeeping the definition of Lisp againLisp could have been more popular by now if CL didn't exist and Schemers didn't throw a tantrum over R6RS.
>>105722333>all trees are graphsEvery data structure is either a large graph, or a group of graphs. Everything boils down to graphs.
Perhaps Lisp should have been defined in terms of graphs instead of cons cells, to keep it simpler.
>>105725774Reading your post made me think about the definition of data structure.
Is a data structure just an (un)ordered set of (type, name, value) tuples?
>>105725774A set is not, since you have to define it as a set of singleton graphs, but then you're left with the problem that you need to know what a set is in order to make that definition, and you need to know what a set is in order to define a set of vertices and edges in the first place.
>>105725853You can model a set as a graph by having a semantic node for the set itself, and nodes for each possible element, the inclusion would be modeled as edges from the semantic node to the element nodes. Obviously this is intractable in typical ways, but you can model it that way.
https://networkx.org/nx-guides/content/generators/sudoku.html
Here, to convert the colored graph to a normal one, you'd have a semantic node for the numbers 1-9. You have to do this a lot to encode things into stuff like sat solvers
>>105725916A graph requires a notion of a set in order to be defined in the first place.
>>105725957No you're right, I don't mean this in terms of defining a set, we have ZFST for that, I just mean that you can translate a set into a graph expression that way. If you've ever encoded sets as bit fields, you can think of the bits as the row corresponding to the source node in the adjacency matrix
>>105725992Oh sorry, I misunderstood. So you're basically defining some equivalence between inclusion and connectedness? That's quite a nice trick. Is this some HoTT-adjacent idea?
>>105726023I don't know the proper term for it, the general idea with the manipulation I suggested of adding the semantic node is to encode extra information as nodes themselves in order to articulate more complex properties of the data.
In the sudoku example, you can also encode row/column/cell semantic nodes in order to model each of those as a set, (does this cell have a 9).
It's a weird hack that you can also use to flatten out multigraphs as well
>>105726023>>105726062I use the term semantic, but you'll also see it described as virtual/fake. I prefer semantic because I think that describes the reason it's there better, it exists to provide information. Structural may also be a good term for it
Another good find
https://www.cliki.net/
from
https://cl-foundation.org/
>>105726362Of which is a redesign of:
https://common-lisp.net/
>>105719431Method A is definitely the most readable if the something-* are short. B and C are both unnecessarily bloated. Always go with the simplest and most readable option.
>>105718021>>105718143>you might as well as using CLCommon Lisp is a worse Lisp than Racket (or any other Scheme). Everyone should learn Lisp with a smaller/simpler implementation first before deciding if they want to move into that craptastic bloatware called Common Lisp.
Saying "you might as well use CL" is like saying "you might as well use C++" when in practice C would work just fine 99% of the time and be a better learning experience to most people.
This is why so many people give up learning Lisp, you idiots keep throwing them into the C++ of Lisp. I'd give up programming too if my first language was C++.
Stop recommending CL to a new learner. It's too much and has too many different ways of doing the exact same thing.
>>105726950CL isn't complicated at all though?
You know you don't have to IMPLEMENT a language to use it right?
The CL reference is simple and easy to read too http://clqr.boundp.org/download.html
>>105719431The clearest way would be something like
let (a, b) = condition (1, 2) (3, 4)
...
where condition is a function that selects the first or second parameter, it looks like C is the closest to that idea
>>105727271>CL isn't complicated at all though?I wouldn't call a 1000+ page specification "simple". The language is definitely bloated and complicated. It's even larger than COBOL, and twice (I think) as large as modern C++.
>The CL reference is simpleI can create a 50 page booklet on COBOL or C++ too. That doesn't mean those languages and their ecosystems aren't complicated for a new learner.
>you don't have to IMPLEMENT a language to use itMy point isn't about implementing Racket or some other Scheme. It's about showing a new learner of Lisp a simpler dialect with an easier learning curve. Something that doesn't have many different ways of doing the exact same thing in every programming paradigm that has ever existed.
People who are completely new to Lisp would benefit greatly from starting with a simpler dialect. They can always move to CL after becoming more comfortable with Lisp.
>>105728446>specificationThat has nothing to do with the language. Are computers impossible for a beginner because they'll have to learn quantum electrodynamics to understand how transistors function?
CL is exactly the same as scheme in use, easier even since there's only one version, there's a package manager, and the emacs integration is better.
Racket by comparison is extremely complex with massive amounts of complicated functions and an entirely separate editor and environment.
>>105711980 (OP)I'm new to lisp. what scheme do you fags use? mit-scheme fucking sucks. it doesn't have reverse search. arrow doesn't even show the last command. are all lisp REPLs like this?
>>105729223>I'm new to lisp.actually, I shold have said:
>I'm reading the SICP.
>>105729223for guile you have to put stuff in the .guile to make it usable, so maybe you need to do that for mit. But either way mit scheme is a toy education scheme, i would use something more popular like chicken or guile
>>105729420I just installed something called "chezscheme" from the ubuntu repos.
>Chez Scheme Version 9.5>Copyright 1984-2017 Cisco Systems, Inc.whatever. al least supports the shit I like in the CLI
>>105729258For SICP, you should use Racket and DrRacket. Not because it's the best scheme (it's too different for other scheme that it's its own language), but because it has SICP mode.
Added animations to lem (just for fun). Anyone got ideas for more fun cosmetic/useless stuff to add?
bFNSYs
md5: a0a709a6c3fad0b99c4d7e4948a07227
🔍
>>105730000https://ash-k.itch.io/textreme
I'm finding the sicp explanation of orders of growth frustratingly vague. I have a vague understanding of them from before I started reading sicp but I want to use sicp as an opportunity to get a more precise understanding.
Specifically for its example of recursive fibonacci in 1.2.2 it says "In fact, it is not hard to show that the number of times the procedure will compute (fib 1) or (fib 0) (the number of leaves in the above tree, in general) is precisely Fib(n + 1)."
I can see that this is true but i really have no clue how I would go about proving that.
Then in the next section it says that the order of growth of R(n) is f(n) where k_1 f(n) <= R(n) <= k_2 f(n).
It says that the order of growth of the number of operations for a tree is the number of nodes, and the order of growth of recursive fibonacci is phi^n.
In the last section we proved that Fib(n) = (phi^n - psi^n)/sqrt(5). So I can make an expression for the number of leaves in the recursion, but I don't see how I can relate that to the total amount of nodes. I can also see how I could get the 1/sqrt(5) out of the order of growth expression by putting sqrt(5) in k_1 and k_2, but I don't see how I could get the psi out.
Does anyone have a more detailed write up that actually shows how they did that?
>>105730379psi is (1 - phi)
Modus theme should be the default instead of whatever the current one is.
Is it possible to use something like Guile or Babashka to replace makefiles on hobby Cpp projects? Any of you have tried?
>>105730000Command Pallete?
>>105730668>Command Pallete?How do you mean? Isn't that basically what M-x is for?
>>105730000Is the source for your animations available online?
>>105730000Very based quads
I found a nice org-mode reference.
https://github.com/fniessen/refcard-org-mode
>>105729420>for guile you have to put stuff in the .guile to make it usableFor me it's
(use-modules
(system repl common)
(ice-9 readline))
(activate-readline)
(repl-default-option-set! 'prompt "> ")
(repl-default-option-set! 'value-history #f)
(repl-default-option-set! 'on-error 'report)
(fluid-set! *repl-stack* (list #t))
>>105730733I mean to make it fancier, with text descriptions (maybe LLM generated) of every available command.
>>105730668>Is it possible to use something like Guile or Babashka to replace makefiles on hobby Cpp projects? Any of you have tried?I haven't tried but comparing which file was last modified is just
(define (newer? source object)
(let* ((a (open-fdes source O_RDONLY))
(b (open-fdes object O_RDONLY))
(c (> (stat:mtime (stat a)) (stat:mtime (stat b)))))
(close-fdes a)
(close-fdes b)
c))
So if (newer? "main.cpp" "main.o") is #t the build rule for that file is run
>>105730379>I can see that this is true but i really have no clue how I would go about proving that.by induction
same way you prove 1 + 2 + 3 + ... + n = n(n+1)/2
>>105734281actually it's technically binary induction or double induction: let P(n) be the statement "recursive fibonacci procedure with input n computes fib(0) or fib(1) a total of fib(n) times" then prove P(0), P(1), and the inductive step:
If P(n) and P(n+1) then P(n+2)
this is half way between ordinary induction and full induction
>>105734320that's induction
>>105731413Not yet, I'm going to try merging it upstream at some point though. Not quite ready, though it's usable already.
>>105730000>Anyone got ideas for more fun cosmetic/useless stuff to add?If lem has the equivalent of *compile* maybe on switching to each error it could have an animated highlight, like the source location of each error fades to red or something
>>105725684since when were you under the impression that i want lisp to get popular? you can go play with the other retarded children writing python
>>105734728I like this idea, thanks anon
>>105735957>uses common lisp>thinks he isn't a retardwe got a live one here boys
we need a common lisp thread at this point to get rid of retards like
>>105736508
>>105735000trips of truth
Added nine-slice view backgrounds, now we have Final Fantasy Lem. Color scheme sucks but it's fun, I'll add a couple more pleasing ones soon.
>>105737644Nice job anon, another idea is animating the cursor like 4coder so it zips between positions on switching buffers
https://youtu.be/Y-mW1QK5rhU?t=177&mute=1
will have to try lem desu
>>105738067I like this one, better than the neovide version of it that's a little too much. Thanks!
CL's pathnames are stupid and insane.
>>105738865what do you mean?
Emacs align still is too hard for my sleep deprived brain to understand.
How would one align CLOS classes like so?
>>105738892Doesn't sly do that automatically for you or something
>>105725318>Tile windowsVery neat, anon.
>>105739490It helps with indentation, but it won't do vertical alignment. For that, you might have to run `M-x align-regexp` a few times or do it manually.
>>105738865Nah they are fine, most people just don't understand how they work.
>>105736788Hitler dubs of confirmation
>>105737644Very niece
>>105725318If you use flymake-mode or flycheck-mode while writing Elisp, Emacs will tell you what you're doing wrong with the docstrings. With that said, here's a few rules you can follow.
- The first line should be a brief summary.
- (Packages like marginalia will display these in a useful way.)
- Keep the width of the docstring within 80 characters.
- If your function has parameters, each parameter should be mentioned in the docstring in ALL CAPS.
- (Xah Lee doesn't like this convention, but it's what everyone does.)
- You can link to things like functions or info nodes by wrapping them in backtick and single quote.
- For example: `use-package' or `(eww) Top'.
- If you use keyword parameters a lot, the docstring for use-package offers a good example of how to format a lot of keyword parameters.
- https://github.com/emacsmirror/emacs/blob/bd04818e53be49f2a087de8a92cb02549f8c2407/lisp/use-package/use-package-core.el#L1835-L1898
Xah Lee's reference for Elisp docs is useful too.
http://xahlee.info/emacs/emacs/inline_doc.html
>>105738892evil-lion is good for this kind of textual alignment.
https://github.com/edkolev/evil-lion
>>105743090emacs already has M-x align, but I think he just can't into regex.
Church numerals. Just Church numeral my shit up
>https://github.com/nightfly19/cl-arrows/blob/master/arrows.lisp
Apparently I had the same exact idea as this person down to the naming of functions. I guess I will kms?
>>105711980 (OP)>ᵋLisp GeneralI just noticed the little "ᵋ" before "Lisp".
>>105744717ᵋᵐᵃᶜ ヽ( ˙꒳˙ )ノ
http://xahlee.info/comp/unicode_index.html
>>105744669isn't this a common idea?
also I would've thought this should use consp rather than listp for these but idk
My personal emacs configuration files have total 68829 line. Is it normal?
>>105745822Wat. Mine used to be ~300 until I switched to lem, where it's like 3 things.
>>105745822i'm assuming that's counting your installed packages
I want to program an advanced tuner for musical instruments. I'm currently reading SICP. As such, I would like to use Scheme for this. What libraries can I use for reading WAV files, performing fast operations on arrays on floats (at the very least, doing fast fourier transform), listening to audio from the microphone and drawing some plots?
>>105746187>math and i/ojust use the C libraries that do this, specially the real time signal stuff.
>>105746255How do I do that from Scheme? Also, that sounds like a pain in the ass.
>>105746187chez scheme has good C interop. Otherwise just use CL with cffi, tons of good C libraries that you can use for that
>>105746269https://www.gnu.org/software/guile/manual/html_node/Programming-in-C.html
>>105746269>that sounds like a pain in the assI think making FFT actually fast (without C libraries) is hard even in more performance-oriented languages than Scheme. Here in the readme dude says that using FFTW via FFI is 10× faster compared to a pure-BQN code:
https://github.com/mlochbaum/bqnoise
I doubt that Scheme can compete with array languages here, so your slowdown will probably be more than 10 times. Though maybe you'll be able to make it just fast enough for your requirements.
>>105746540he could always implement fftgen in Lisp instead of OCaml
>>105746187>music>schemehttps://github.com/schemedoc/awesome-scheme#graphics-music-audio-video
Also
https://github.com/bintracker/bintracker
>>105746187https://github.com/ul/chez-soundio
https://akkuscm.org/packages/chez-matrices/
https://akkuscm.org/packages/gnuplot-pipe/
>>105746540FFTW is actually a hyper-autistic code generator written in ocaml (that generates C code).
My emacs just crashes, no slowdown, no warning. It justs closes. I am using ubuntu and it is self-compiled. How do I start debugging this? I can't tie it to some specific thing, or reproduce it.
>>105747407M-x toggle-debug-on-error if it happens during use
If it's during launch run emacs --debug-init
Also https://elpa.gnu.org/packages/bug-hunter.html
>>105746578>>105747358TIL. Actually I've seen Oleg Kiselyov's papers about code generation in MetaOCaml via staging, with high-performance libraries as a main use case, but this is the first time I see code generation in real world. Very cool.
>>105747407Maybe it segfaults or gets OOM-killed? Check the system logs (probably journalctl on ubuntu)
What are some tips with org mode styling? I like using it, but at present I have some issues with how flat the color scheme is. I've messed with the heading styles but I still find myself having to kind of squint and it makes me feel old
>>105748986- I like to use olivetti-mode while viewing org documents.
- I also turn on org-indent-mode.
- I also like to make the heading sizes bigger.
;; https://emacs.stackexchange.com/a/75240/37580
(defun my/org-faces ()
"Customize faces for `org-mode`."
(interactive)
(set-face-attribute 'org-document-title nil :height 2.0)
(set-face-attribute 'org-level-1 nil :height 1.4)
(set-face-attribute 'org-level-2 nil :height 1.2))
(use-package org
:ensure nil
:hook ((org-mode . org-indent-mode)
(org-mode . olivetti-mode)
(org-mode . my/org-faces))
;; etc ......
)
I really wanted to like org-modern, but it fucks with indentation and code blocks too much. I know about org-modern-indent, but I could not manage to get things working just right.
>>105749041>org-modernI actually tried reinstalling it, and ...the bugs I mentioned might have been fixed. Code block indentation looks stable now. ...oh, I'm reading the README... they just disable the fanciness on code blocks if org-indent-mode is on.
>>105748986>I have some issues with how flat the color scheme isWhat themes have you tried so far?
>>105749150I'm presently using the doom tokyo night theme, I've looked at a couple of others for org specifically, (can't remember off the top), but I haven't been fully satisfied
>>105749182To my eyes, that's a decent color scheme. Contrast is sufficient and the color choices for org headings harmonize well with each other. In your eyes, is it close to what you want but missing something? If so, you might want to start with this theme as a base and then use set-face-attribute to set your own colors for the parts that aren't satisfying you.
I like going to this site and hitting <SPACE> to get inspiration for color themes sometimes.
https://coolors.co/generate
>>105746187Ok, so far I have implemented reading a WAV file in racket. Fuck me. Scheme is hell on my level of knowledge. Also, chatgpt makes mistakes all the time and is basically useless as a result.
https://pastesio.com/reading-wav-in-racket
Time to go to sleep. Next goals (for tomorrow) - uhh, figure out the fft thing, I guess. Also, maybe plot the wave as a plot.
>>105738067Thanks for the suggestion anon, I went ahead and added the smooth cursor. Might look a bit jaggedy in the webm but it feels smooth. Still a WIP though.
>>105750973>>105738067Maybe better? If not just take my word for it lol.
>>105751042I'm retarded forgot picrelated.
(lambda (f) (lambda (x) (f ((lambda (f) (lambda (x) x)) f) x))
>>105750147Congratulations.
>>105752806Also this might help:
https://planet.racket-lang.org/package-source/williams/science.plt/4/8/planet-docs/science/fft.html
Church numerals are still breaking my brain, but I'm making progress. I've wished once or twice that I came to SICP from at least a passing background in formal lambda calculus rather than coming to lambda calculus through the lens of SICP. Either way, I'll spend as long as I have to here because understanding how closures, lambdas and first-class functions interact in Church numerals seems to be a significant core understanding... if not the singular core understanding.
Not that Church numerals are in and of themselves important, of course. For any real-world application, there's no reason why you need to encode numbers in an enormous sequence of function calls when you could do so with one assembler instruction. It just seems like it's foundational for understanding FP as a paradigm and that you need to breathe these dynamics naturally if you want to do any conceptual work in FP which actually leverages its strengths.
Is there an autoformatter for Racket like Black for Python?
seems like a lot of guile projects use a really functional programming style. Is there a good scheme resource for learning it or should i just make an excursion to haskell and come back when i understand it
>>105753762parendit
>>105753800scheme is very functional. There is no way from escaping it.
You don't need to learn haskell to write guile code...
>>105753800>Is there a good scheme resourceMy son... you seem like you haven't heard the Good Word yet...
>tried to make a personal elisp package that aims at dealing with a big json file
> asked it to Claude
> It generated bullshit elisp codes
> make a Python script by Claude AI
> wrapped it with elisp code
> work perfectly
I think elisp is just suck at dealing json. Ended up feeling like, elisp is for mental masturbating
>>105753800what do you want to understand?
functional programming => everything is a function => everything is a expression.
pure functional programming => everything is a pure function (one argument, no side effect, referential transparency).
>>105756827emacs has native json parsing now. The goyAI has little elisp in its stolen training set, so it can't copy much. It has petabytes of json handling python code.
Good morning sir.
>>105756827"AI" can't write good elisp because it's a predictive statistical model that hasn't been trained on enough elisp code to be able to do so.
"AI" isn't "smart". It can't figure out how to do something if it hasn't seen it done before.
>>105756827Claude is terrible at writing Lisp. All of them are. Deepseek might be the least bad, weirdly enough.
>>105756827slop bots are pathetically bad at anything other than python or webshit languages. and even then you're going to get hacky ugly code that uses entirely made up libraries and methods.
https://anonradio.net/
Lispy Gopher Show
Every Wednesday at 00:00 UTC
https://time.is/compare/0000_2_July_2025_in_UTC
I don't know what the topic is going to be this week, but it's going to be in about 26 hours from the time of this posting.
The chat for the show is on LambdaMoo which you have to telnet into to access.
telnet lambda.moo.mud.org 8888
connect Guest
They're going to be hanging out in some Sushi place. To get there, do this when it's close to showtime.
@who
Pick a user that's at the Sushi place, and type:
@join username
Substituting username for the user's name, and it'll teleport you to where that user is.
>>105759392The host:
https://gamerplus.org/@screwlisp
>>105757088>>105757279>>105757331>>105757336It seems like eslip is nearing its end, and there may be fewer new zoomers becoming the emacs chad
How to write a simple CLI interface in scheme like
$ scriptname /path/to/input --switch-flag-on --output /path/to/output
?
>got used to jetbrains because of work
>happy to be back using emacs again but there's some friction
Main thing I miss from jetbrains is extract method/variable, is there a way to get something similar?
>>105725072>CL trading bookwhat?
>>105760777Guile has getopt-long.
https://www.gnu.org/software/guile/manual/html_node/getopt_002dlong.html
>>105749182Why not look at prot's themes? His ef-themes has a big selection of variants and usually stuff is nicely configured.
>>105757279Aren't they always looking for training data? Most elisp is free stuff, not proprietary, so training it should be easy.
>>105763518I wonder if it might actually be the parens, god knows it's somehow mindfucked a lot of nocoders before, what if there's some sort of actual physical reason for it? Like dyslexia but only for programming in lisp, that also affects AIs?
>>105761395>Main thing I miss from jetbrains is extract method/variable, is there a way to get something similar?This is up to the language server. Clojure-lsp has lsp-clojure-extract-function.
>>105763518>>105763538It isn't just the availability of training data, it's up to the creators whether they value Elisp code as high as python etc. Maybe they run more code from popular languages through training more.
Even if they don't, while elisp code is mostly open source there is nowhere near as much of it as for langs like python.
>>105763538>I wonder if it might actually be the parens,In the world of AI the parens are just another character to predict.
>>105763744Yeah but a string of repeated characters, which is common and normal in lisps, is in almost all other cases really bad to the point there's lots of specific training to avoid it.
>>105763779>Yeah but a string of repeated characters, which is common and normal in lisps, is in almost all other cases really bad to the point there's lots of specific training to avoid it.Half of all shitlangs:
}
}
}
Option<List<String>>();
And there is a temperature setting in the decoding which controls the randomness of output. Maybe they turn this down when they detect code analysis is on the table.
In either case, even "old" decoding methods like nucleus sampling are flexible enough to manage repeated characters if the probability is high enough.
>>105760777(define (parse args)
(match args
[() '()]
[("--switch-flag-on" . rest) (set! flag on) (parse rest)]
[("--output" path . rest) (set! output path) (parse rest)]
[(($ path? path) . rest) (set! input path) (parse rest)]
[(option . rest) (warn 'unknown-option option) (parse rest)]))
;; chez, gambit
(parse (command-line))
;; racket
(parse (current-command-line-arguments))
;; guile
(parse (program-arguments))
;; also guile
#!/usr/local/bin/guile -e main -s
!#
(define (main args)
(parse args))
gambit creates scriptname on compilation which is just a sh/bat file that passes its args to gsi, other schemes often delineate user args with -- so you may want to scan to -- before parsing
>>105760777Guile has a section in the manual doing exactly this.
>>105763538The computer doesn't care about the parens. It's trivial to match them. They're not actually significantly different from languages with curly braces. What filters people arguably isn't the parens at all -- it's just the convention of stacking them at the end of expressions rather than giving every paren block its own newline and indentation.
>>105765927What filters people is the requirement to learn something. People fucking hate having to think.
Ask yourselves what kind of person has been the majority who went into computer science or learned to program in the last decade or so. Exactly.
Lisp encourages you to actually think about programming the act of programming itself which requires thinking a bit more deeply. You'll never get adoption among these people because you struggle to even convince them that even basic linear algebra should be a required topic to learn. They'll cry about learning maths. They'll say "don't reinvent the wheel" not because it's efficient but because they don't understand how the wheels were made and that would require effort that may not reward them with money at the end of it, so why bother? Most people know that the days of Moore's law have been over for decades, but did they then get serious about writing performant code? No. They just stuck their heads in the sand, continued writing shit, probably even worse shit than before, and now we get bloated messes that somehow negates decades of advances in chipmaking. They follow 'best practices' not because it's a good idea but because they're religious codes made to tard-wrangle morons who can be expected to fuck things up. These people realistically shouldn't be coding anything at all. Lisp is ironically probably much simpler than most languages, if anything. People make excuses for them out of politeness but everyone knows the field is dominated by morons.
>>105766539>now we get bloated messes that somehow negates decades of advances in chipmakingIt strikes me almost as an unintentional corollary to the Jevons paradox. Jevons at least had some optimism that not all increased activity from more efficient resources would be wasted -- and if we're being fair here, it's probably still at least roughly true with programming -- but... yeah, it does seem in a general sense that the increases in computing power has been a vehicle for the VC vultures to drop lower and lower quality people into dev roles in pursuit of the almighty bottom dollar.
>>105766539Both ocaml people and lisp people have shown that for "learning programming" it doesn't really matter if you are C-like, lisp or ML-like. There are some talks about janestreet folks teaching non-technical workers and they did fine with ocaml.
sushi
md5: a17472fd4a497fff0cbaf071c7182727
🔍
>>105763413/g/reat book
https://files.catbox.moe/f6d04n.pdf
I trust you guys more than /dpt/.
What're your rules of thumb for using macros in C?
My personal line is when I start putting control flow operations in them or generate function signatures and the like. I don't think using macros to achieve metaprogramming is a good thing
ponder
md5: 130d21aa2eddea3882b725d7415021a3
🔍
I love lisp so much it's unreal
>>105769797>What're your rules of thumb for using macros in C?1) don't
>>105769797>generate function signatures and the likeShould use C++ (or some newer and better language) at this point
>>105770758this
>>105769797What are you writing in C?
...And are you using Emacs to write it?
1000+
md5: 59cca2853524c020dce98e6c2119b03e
🔍
Interesting
https://clojure.org/news/2025/06/27/deref
>eca - Editor Code Assistant (ECA) - AI pair programming capabilities in any editor (https://github.com/editor-code-assistant/eca)
I don't believe Clojure is the future of Lisp
If someone here wants to start with chicken scheme:
A Introduction to CHICKEN Scheme (installation, usage, libraries, documentation)
https://www.youtube.com/watch?v=aIwt7ocBBdo
>>105774818nice video anon
>>105746601>https://github.com/bintracker/bintrackernice chickenware
All accumulators must die. All accumulators are bastards. Drop kick accumulator babies into trash compactors.
>>105769797#define profile ... /* to print __LINE__ */
#define CASE(item, type) ... /* to permit refactoring later */
switch (t) { CASE('.', DOT) ... }
#undef CASE
#define lerp(a, b, t) _Generic ...
// perhaps controversially
#define range (a, b, c) for (int a = b; a < c; ++a)
>>105769797>What're your rules of thumb for using macros in C?My rule is to ignore most of these rules of thumb and think about whether it actually works and whether the code is better off for having them or not.
>>105711980 (OP)I wish I was this cute.
>>105775251The compiler should just rewrite expressions that generate stack temporaries to an accumulator where it identifies them
Why is clojure tooling so shit? If I don't use it consistently I forget the CLI/deps.edn format and ALWAYS take hours setting up a new project
A while back some people were saying the CL metaobject protocol was like wizardry. Can someone give some examples of this? I can only find the trivial ones like counting instances of a class.
>>105778387Well you modify the object system itself so it really is whatever you want. I'll give you an example. I'm not using this yet but I made a prototype that worked.
I'm making a game, so something I'd like to optimize for is consing. I have a few ways to get around it, like pooling or using SBCL arenas. So as a test I made a MOP metaclass that automatically creates an array per class, and transparently pools it behind the scenes. The usage looks the same as any normal class, but in the background when you make a new one it reuses already allocated memory instead of allocating anew.
>>105778432This sounds cool, and I do understand the concept, but I'm really wondering if anyone has a specific code example that they think is a cool use of MOP.
>>105778432are you that g*rman who makes CL games by any chance
>>105763158>https://www.gnu.org/software/guile/manual/html_node/getopt_002dlong.htmlnice
demo
md5: 6a108f0b28afe66791c4b1dfc8e02416
🔍
>>105773639looks good
https://github.com/editor-code-assistant/eca-emacs
>decide to look into doxygen highlighting minor mode
>don't actually use doxygen, but the comment style is familiar
>look online
>doxymacs is the #1 rec but it's 16 years old
>try https://github.com/Lindydancer/highlight-doxygen
>works alright
>accidentally type something it interprets as a code block
>c-ts-mode starts repeatedly activating and deactivating every keystroke
>emacs slows to a crawl
>debug
>read some of the documentation for the package
>test configs
>finally scroll down to this
>>https://github.com/Lindydancer/highlight-doxygen/blob/eec4874e2e89d4eb39091aad89a67dff8f8ec84c/highlight-doxygen.el#L373
>for the code block formatting that I don't even want, it's repeatedly creating synthetic buffers and applying the mode, then 'copying' the formatting into the real buffer
>it's slow as shit
I'm at a loss
I just had an idea, imagine a variation of interactive, specifically for functions that insert text, where instead of typing in the minibuff, it displays what it will generate as you type
>>105783912I've seen evil do something like this already during regexp search and replace.
:'<,'>s/pattern/replacement/
As you type pattern and replacement, you see the speculative changes happen in the buffer. I don't know how evil does this though. You still type in the minibuffer in this case though.
>>105784091>You still type in the minibuffer in this case though.Yeah, probably would keep that for sanity's sake.
I was just using the org insert link feature, and I was thinking about how having visual feedback would be nice. I also have buffer macro for c structs where being able to see it would help me.
>>105774818I wanna try many of these langs but my work requires me to interact with Windowze so i stick with Python for necessity and Bash whenever i feel i can
>Captcha:KYSMSS
>>105784929You won't notice a difference when starting out, Sly is a fork of SLIME so it's the same thing with a couple different minor features. Use Sly if you want ASCII art in your prompt basically.
>>105784957>SLY's highlights are:>A full-featured REPL based on Emacs's comint.eldoesn't that make a difference? i ended up going with SLY because i'm accustomed to other comint based modes like M-x shell
>>105785204Yea but a lot of the history navigation stuff is just handled manually by SLIME with the same keybinds, it feels almost the same to me.
>>105712867What's that tattoo on her leg? Down by her ankle.
>>105784929I picked sly. because it seems slightly more maintained.
>>105784929SLY maintainer is a douchebag.
No I won't motivate. Stick around for long enough and you'll see.
>>105765142I don't get how this part
[(($ path? path) . rest) (set! input path) (parse rest)]
Is supposed to work, there doesn't seem to be any path? type or function in any implementation of scheme I can find.
>>105786300It's not a function. It's a pattern for match to work with.
https://www.gnu.org/software/guile/manual/html_node/Pattern-Matching.html
Search for "a record" on that page to see what $ is for.
>>105786136same guy that maintains eglot? lmao, explains a lot of things. Average portuguese
>>105786834I did, there's no record path?, it doesn't work.
After more searching it only exists in racket, there's nothing like it in other schemes, not even as a module.
match
md5: b6d30e5595e45b669d72882037808ee4
🔍
>>105787937match is what you need to understand.
>>105787960You're not reading my posts, I get match, I know what the $ means.
I'm saying there's no such thing as "path?"
>>105786300>I don't get how this part ($ path? path) Is supposed to workI messed up it's a typo, the pattern should be (? path? path) where path? could be (in guile at least)
(define (path? path)
(and (file-exists? path)
(eq? (stat:type (stat path)) 'regular)))
In anon's original input
>>105760777>$ scriptname /path/to/input --switch-flag-on --output /path/to/outputthey want to match 3 common cases: (--switch), (--switch option), and (path). path is tricky as it could be positional, optional, or overridden by later paths. The function
>>105765142 handles the latter case so the final pattern can report any failed matches (which is nearly certain, most command line lists start with the name of the program), instead of raising these questions with anon I tried to do the least annoying thing and let them fix it
>>105788263just use optparse in guile ffs.
every fucking day schemers are reinventing the damn square wheel.
this monad stuff doesn't make any sense
>>105788640The first reply to
>>105760777 was
>>105761388 which has stackoverflow vibes, we don't know which scheme anon is using (and Shinn's match is well ported) so I just posted a small transparent function as an example of parsing args
Weird question but
do you guys do any lisp programming in android? if so, what do you use? emacs on android? cl-repl? or plain termux?
>>105788776I use Emacs on android to write Emacs Lisp. Yes.
>>105788776Lem worked on termux for me
>>105788672It's just a monoid in the category of endofunctors, what's the problem?
Added a little asset preview, had something like this in Emacs a while back but it was janky. I don't know if I'll keep it as part of the frontend or make it a contrib but I find it useful for gamedev/webdev.
Why are sbcl backtraces so fucking unreadable?
>>105790006wtf I find SBCL incredible for debugging, literally my favourite compiler to work through issues with
>>105790006It's pretty shouty, but I've only found disable-debugger and not any settings for controlling verbosity
>>105789945That's pretty cool, like the embedded asset previews in templeos
>>105790178That's not what inspired me or anything..
>>105790186Your secret is safe with me anon
>>105790006>>105790014He's kinda right, you need to adapt a bit and learn what to look for, there is a lot of noise there that is not very interesting.
>>105788776You can try picolisp:
https://picolisp.com/wiki/?PilBox
>>105785245BGC (big gnu cock) ownership branding
>>105753762raco pkg install --auto fmt
ed
md5: cab4960827bed83dbd3e680a67e9027a
🔍
>>105712364>https://github.com/nmeum/edwardEd, man! !man ed
https://www.gnu.org/fun/jokes/ed-msg.html
>>105712364>2.4mb of tests
I've been using emacs for 5 years but I don't get the appeal of org mode. I just don't use it. Just memorize it with your brain bro
gonna try out GNU Hyperbole. wish me luck
>>105795074Do you get the appeal of markdown? Org-mode has a lot in common with it.
>>105797554>Do you get the appeal of markdownNo
If I learn Clojure, does that knowledge transfer to Elisp?
Also, what are your go-to projects when learning a new language?
Hello is Dylan worth messing with or just a pointless diversion?
>>105799062>Also, what are your go-to projects when learning a new language?a small database-backed web site
>>105799062I don't have go-to projects in a new language, I prefer to just do something that feels right for them. It should be something with a serious challenge and something I haven't done before.
Question for the thread btw, can people tell me why they like Clojure? I like the sequence abstraction but I really feel like many changes make it a weaker language than Common Lisp and I'm not sure why I'd want to use it. I want to understand what people love about it.
>>105799480I'm too much of a javelet to even know how to build and deploy a clojure project. Literally got filtered by deps.edn.
>>105797554My life is simple enough that I don't care about optimizing stuff, and as a wagie I must balance myself between been to productive and people start asking me for stuff and being fired. I use orgmode at <job> but only its basic functionalities and to generate integrated reports with org-babel's sql mode.
>>105800333wagie dub trips
I want to write a tiny GUI application (basically an input field, two radio buttons and logic to detect where is yt-dlp in your $PATH). Is ClojureDart overkill for this? Should i just make a Swing application and compile it with Graal?
>>105799480Dunno about mainline Clojure, but Babashka is very easy to deploy on Windoze, not using Powershell is worth the slight bloat.
>>105801378>I want to write a tiny GUI applicationI feel like Racket would be good for this. It has a decent cross-platform GUI library in its standard lib.
https://docs.racket-lang.org/gui/
https://github.com/mfelleisen/7GUI
https://alex-hhh.github.io/2021/09/screenshots.html
I'm a very lazy person with ADHD.
Is learning emacs mostly for org-mode worth it ?
>>105801852If you're lazy with adhd what do you want org mode for
>>105801859idk dude, be more organized i guess ?
>>105801881give it a week and see if it's for you, i'm not a note-a-holic just just regular markdown-mode does the trick for me
>>105799137very cool lang, you can also look up rhombus-lang
>>105801852yes, you can compile org mode to many different formats (or even html)
>>105800333I started using org mode because it was markdown but more geared toward notes/lists, as well as the emacs compatibility
I'd been using a mix of markdown and latex for most of my text documents for a while depending on the complexity.
Org files are extremely easy to write for the most part even without emacs, so there's little complexity
t. Barely use the fancy features of org
http://anggtwu.net/index.html#eev
do you use avy-goto-char or avy-goto-char-2
>>105806328evil-avy-goto-char-timer
>>1058063281 gives too many results, so 2.
Why can't it get rid of the vim keybinding?
(define-key evil-normal-state-map (kbd "gg") nil)
>>105807123`C-h k g g` says:
g g runs the command evil-goto-first-line (found in
evil-motion-state-map), which is an interactive native-comp-function
in ‘evil-commands.el’.
It's in evil-motion-state-map. I'm curious why you want to disable this binding.
I feel bad for just becoming aware of justfiles. I love them for writing project-specific tasks, and they're well supported in Emacs.
https://github.com/casey/just
https://github.com/leon-barrett/just-mode.el
https://github.com/leon-barrett/just-ts-mode.el
https://github.com/psibi/justl.el (not evil friendly yet)
>>105799137overly verbose and the object model seems to be a total clusterfuck.
>>105808293I was considering using Babashka's tasks for the same niche. Wonder which one is better.
>>105808442If you're mostly running shell commands (which is what I'm doing), just is a better fit. Just also has a polyglot mode that lets you write and run scripts fragments in another language, so you can mix just with babashka if you want.
https://github.com/casey/just?tab=readme-ov-file#shebang-recipes
>>105808467I like "just" as a word, too. It feels emphatic (and good).
>>105778142Looks like Janet might be the answer if JVM FFI isn't necessary.
spent a few hours fucking around trying to replicate bash scripts using guile.
It's uh, not easy to do process control.
Like I couldn't even figure out how to do it and had to resort to running parallel in bash inside scheme.
Is the only way to figure out the fork commands and manually track all the pids and control them with unix signals? Is there nothing better than that? I thought I could use threads for a while but it just doesn't work when I have to make system calls.
not really a lisp question but im using neovim for scheme and using blink.cmp for completion, the full name of the functions using symbols such as ! or ? dont show up, anyone know of a fix for this?
>>105810401>anyone know of a fix for this?yeah use emacs
Has anyone ever used TAGFILES for scheme?
Xref-find-definition and find-references don't work for me. The file was generated with etag myfile.scm
>>105810899scheme was made to be used in a repl only, it's an educational programming language.
>>105808293Before finding just, I was using ondir to load and unload shell functions. I am happy to be able to deprecate that workflow, because I changed shells recently from zsh to nushell, and ondir doesn't work in nushell. However, just will work fine, and it's simpler.
https://github.com/alecthomas/ondir
>>105810401Try extending ALPHANUMERIC with ?! in https://github.com/Saghen/blink.cmp/blob/main/lua/blink/cmp/completion/accept/prefix.lua it'll be something like that, if lua has string literals grep ?! for special handling in stuff like ternary operators in other languages
>>105810899>The etags program handles more than 20 languages, including Emacs Lisp, Common Lisp, Scheme, C, C++, Ada, Fortran, Java, LaTeX, Pascal, Perl, Python, Texinfo, makefiles, and most assemblers. The program has no switches for specifying the language; it recognizes the language in an input file according to its file name and contents.It's apparently supported by emac, does find-tag like https://ftp.gnu.org/old-gnu/Manuals/emacs-lisp-intro/html_node/etags.html describes at least work?
>>105811540the tag file is generated correctly. it seems xref just shits the bed.
>>105810016chibi-scheme has nice (chibi shell) module. I haven't used it, but tests definitely look better than pipeline and other guile bullshit:
https://github.com/ashinn/chibi-scheme/blob/master/lib/chibi/shell-test.sld
Docs: https://synthcode.com/scheme/chibi/lib/chibi/shell.html
You may find it more bearable.
>>105811784https://github.com/emacs-mirror/emacs/commits/master/lisp/progmodes/xref.el
I can't see anything sussy in recent commits but you could try dropping in an older version of xref.el (this would be a good feature for emac to have for regression testing)
file
md5: d32eb560794eec5bab1f54f726293a05
🔍
PSA: NEWCOMERS: there's a maintained fork at sharplispers/lparallel
https://github.com/lmj/lparallel/issues/51
>>105811909try creating a scheme file in a separate folder.
Define a main function, some other bullshit.
Run etags.
Try M-? on one of them.
I've started using the scratch buffer for scripting really minor shit I need in the moment, it's quite lovely
emjois
md5: 932a57e539efd3aa9e4f7e4a1dc6f889
🔍
>>105812769what the heck
I've been using emacs for 5 years, but I didn't know such shits
and I was like
>Who the fuck use this shits?I would get rid of it
>>105807331I want to get rid of it cuz I find 'go' better
>>105813880It's a recent addition, 29.1 according to NEWS. I prefer C-x 8 RET for inserting emojis.
>>105813880>I would get rid of itwhy? facilitating the input of text is an essential goal of emacs. see the venerable MULE and its countless input-methods
>>105815401thanks
>>105815676sorry for my harsh words.... :) (I'm asshole) I know many ways to type emojis, so it's kind of redundant for me, and it's hard to memorize.
r
md5: df0d0e10fe7285fc1e2149c566dd480a
🔍
>>105812769Not the most ergonomic binding...
>>105813831I wrote a nice function in the *scratch* buffer the other day, but I forgot to save it in a file, and I had to rewrite it today. Thankfully, it wasn't that long, and the second time around went faster.
Why does this work in Elisp? I thought you had to use funcall.
((lambda () (+ 1 2)))
>>105817264You're making a function which requires no arguments and will just evaluate (+ 1 2). The function is then applied to nil, so it evaluates to 3.
>>105817264Lisp-2 only affects symbol binding. Lambda returns a function directly.
I finally got multiprocessing working in guile. it's kindof a pain but not really that complicated once you figure out how exactly to do it.
Lots of extremely perplexing and frightening errors involved, makes debugging very difficult and scary. I almost forkbombed myself a few times and completely broke a dozen terminals making interactive debugging effectively impossible.
Also some of the function dexcriptsion are INSANE shit like "input a non zero number to KILL ALL PROCESSES ON THE COMPUTER"
Why the fuck would I want to do that exactly? Hell why the fuck CAN I do that with a single command?
Put simply all you have to do is (primitive-fork), use a conditional to determine which process is the child and have it execlp sh sh -c, and then waitpid WAIT_ANY to get the result asynchronously.
In it's finished form it's only a few lines, but man was it an experience getting there.
>>105817706TIL. Thank you.
>>105812362non-ironically used it (the old one) in a script at my day job.
I'm using WSL2 on Windows but want to try out emacs (or maybe lem). Should I run it in my linux VM or on Windows?
>>105818412from what i've heard, running emacs natively on windows is notoriously slow. not sure if they have fixed that