[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: How can I write this function better?
From: |
Marcin Borkowski |
Subject: |
Re: How can I write this function better? |
Date: |
Tue, 14 Mar 2017 13:44:33 +0100 |
User-agent: |
mu4e 0.9.19; emacs 26.0.50 |
On 2017-03-13, at 20:49, user <user0012@cocaine.ninja> wrote:
> Hello help-gnu-emacs, I'm looking for pointers with my luser-0x0 function. I'm
> sure there are better ways I could write this. I'm not asking to have you
> rewrite it for me, that'd be rude of me, but rather what I should to look at,
> such as documentation or learning new constructs etc. I'm _very_ new to
> programming and Lisp (learning Lisp and Forth as my first languages; quite
> fun). An explanation, which I first wrote for myself, is below the code.
>
> Thanks.
Quick comments off the top of my head (maybe completely wrong...)
1. No need to create one-use variables (there are probably various
schools on that...).
2. I think there is no need for `apply', either.
3. Instead of the low-level-ish set-process-filter and start-process,
why not use something much simpler like `call-process-shell-command'?
Hth,
--
Marcin Borkowski