freenode/#lisp - IRC Chatlog
Search
9:44:04
beach
What does the situation look like in industry? Suppose for instance that someone wants to learn C# for Windows. Can they get away with using the editor they are already familiar with? It is not a rhetorical question and it is not meant for miatomi_. I am asking in general because I just don't know. If the answer is "yes", do they then miss out on some features that they could have had if they converted to whatever Microsoft
9:44:52
Shinmera
VS is free nowadays, and it uses the same kinds of keybindings people already know from other software.
9:45:58
Shinmera
I haven't checked, but I wouldn't be surprised if IntelliJ and Eclipse also support C#. Those are, I believe, the other two "top" IDEs.
9:47:13
beach
OK. Thanks. So when people complain about having to learn Emacs, they basically already know one of those, and they all have the same key bindings?
9:47:18
Shinmera
Generally if the language in question has enough industry pull most major IDEs are going to include support for it.
9:47:56
Shinmera
beach: They diverge in details, but most people complain about copy, cut, paste, undo, redo, open file, save.
9:48:36
Shinmera
And you can't really change them in Emacs because the defaults would clash with too many other keybindings. (C-c prefix, for instance)
9:49:31
Shinmera
I've considered the idea of including more standard keybindings in Portacle, but rejected it because it would make getting help harder since I'd have to change too much.
9:49:52
beach
That really sucks. I mean, Emacs predates all those, and I think the Emacs bindings are quite well thought out. Frequent operations are short, infrequent ones are long. And it is rare that two key sequences are similar if one is "dangerous".
9:50:13
basket
Shinmera: Emacs ships with cua-mode that does that; it's not too much of an issue for clashes because C-x and C-c are only cut and copy when the region is active
9:50:46
Shinmera
basket: I'm aware of cua mode, I still don't consider it a good idea, especially because C-c etc are still useful when regions are active.
9:52:58
scymtym
people's wish to keep working within their respective environments has been recognized in a certain way, though. many IDEs are now basing their support for programming environments on the "language server protocol" which is like a JSON-based, language-agnostic, specified version of the swank protocol
9:53:41
basket
Shinmera: Yes, but it does make it much more viable for newbies who just want a Lisp editor with familiar keybindings and see learning Emacs as a hurdle, I think
9:54:19
Shinmera
basket: I consider the potential for confusion in the bindings clash too high a risk
9:55:36
beach
We have had system administrators who found it a good idea to provide a "standard" startup file for (say) students. The result was that nobody knew exactly what key sequences to use, or what happened when the wrong one was accidentally issued.
9:59:13
pjb
At least Xcode implements the basic emacs control keys, and integrates good enough with an emacs editing workflow…
9:59:29
miatomi_
pjb: haha, fair. I love emacs too, I had the advantage of learning it before taking on clisp weirdly.
10:03:17
jdz
pjb: not sure it's Xcode specifically, because emacs keybindings work in all text fields on OSX.
10:10:32
d4ryus
readline, which is pretty wide spread among shell utilities, also uses Emacs Keybindings (as default, at least)
10:11:09
jdz
Yes, and Emacs users usually use them, other people even don't know their command line has undo.
11:47:10
hajovonta
when my program starts to grow, how do I keep the functions in order so that when loading the file, I don't get warnings like "undefined function" when the function definition comes later in the file?
11:47:43
hajovonta
or, maybe a better question can be that how can I easily reorder or at least analyze my file ?
11:51:20
hajovonta
this is because I need it to run in a screen, and then I connect to it via swank server
11:51:46
hajovonta
so things are further complicated by running screen -S 'sbcl --load whatever' ...
11:53:24
Shinmera
Unless of course you do stuff at load time that causes warnings. Function order won't matter, though.
12:49:55
Xach
If you put uiop-3.3.0 in ~/quicklisp/local-projects/ and (ql:quickload "circular-streams"), you can see it loads cffi and babel twice.
14:24:45
Xach
commit 4ed76c32050753c8a4450c342a1592881e11d63d seems to reference constant recompilation
14:39:07
Xach
Fade: good! though I did not spend as much time writing code with it as i wanted, so i'm going to stick with it more.
15:39:07
Bike
Let me help you out then, it's Bike 4283, Shinmeta 59821. Soon I will overtake you to take my rightful place
15:40:59
Shinmera
And the lord said: you shalt no longer mistype other's names, for I give you the power of tab completion
16:05:18
jmercouris
you won't believe it, but someone actually got really upset on #python like a year ago when I randomly brought it up
16:05:33
jmercouris
they went on a huge rant about how noobies will randomly type it into the terminal and see what happenes
16:06:12
jmercouris
When I first installed linux in seventh grade I did something similar, I actually deleted my mounting point
16:09:17
jmercouris
Xach: I never suggested anyone try the command, I don't ever give wrong advice (to the best of my knowledge)
16:12:00
jmercouris
shka: I think we'll be okay, pretty sure most people aren't running root nonstop
16:19:07
Bike
Shinmera: if you remember the mirai worm, the dev named themselves after that show. that's the Real World Connection
16:23:44
aeth
It is no longer a functional command because it was a meme so it should warn, at least with the GNU version. There are more dangerous variants, though.
16:28:37
Shinmera
Hmm yes, punishing curiosity is definitely a good thing and posting something malicious to trick people makes me a good, likeable person.
16:28:38
_death
will someone fall for (format t "~{,2F~^ ~}" (loop repeat 5 collect (random 1.0))) ?
16:29:31
jmercouris
It's definitely not trolling, I didn't have the intent to rile anybody up or trick anyone, I was just making a joke
16:30:03
jmercouris
The joke was that I was running the command somewhere on my system, or on one of my machines
16:31:03
jmercouris
I think we can let this one go now, I apologize, for anyone reading this conversation in the future, please do not run the command as it will recursively delete all of your directories given enough permissions to do so
16:51:02
pjb
jmercouris: can you imagine that some people actually drilled into their iPhone 7 to add an audio plug!
16:54:10
pjb
beach: For now, I have no idea. I'm looking for a new job (to pay taxes). I probably will be busy for the next one…
17:01:56
beach
Though, I understand that they are still looking for a program chair. If anyone knows anybody that might accept this important task, please contact a member of the steering committee.
17:41:57
sjl
Shinmera: I didn't have time to do much of anything last night, but maybe I can ask you some stuff today to clarify things in my brain
17:42:23
sjl
Shinmera: so, the general idea of Harmony is that you have a Mixer that plugs together a bunch of segments
17:43:24
Shinmera
A "mixer" is basically just a collection of segments that are run in order when the mixer is run.
17:45:44
sjl
one thing I wasn't clear on: are there actual separate buffers between each, or is it just a single buffer that gets operated on by each one in turn?
17:46:38
Shinmera
buffers are basically just float arrays. you can re-use them or not, but obviously if you have two channels you can't use the same buffer for both.
17:46:59
Shinmera
Harmony obscures that detail because it includes a system to automatically handle buffer allocation for you.
17:48:03
Shinmera
That stuff happens in pipeline.lisp. The actual allocation algorithm is in the Flow library, though.
17:49:19
sjl
what I'd probably want to do is use the vanilla mp3 source's (decode ...) to fill a buffer in memory in the initialize-instance :after method on my preloaded source
17:49:46
Shinmera
What I think you should do is look at https://github.com/Shirakumo/harmony/blob/master/sources/buffer.lisp and try to make it work with a data array that's initialised with a complete buffer read by cl-mpg123.
17:51:37
sjl
so instead of (play "foo.mp3" :sfx :type 'mp3-source), it would end up being (defparameter *foo* (read-mp3-file-into-buffer "foo.mp3")) ... (play *foo* :sfx :type 'buffer-source)
17:54:42
Shinmera
Maybe something like making play accept a CFFI pointer or some struct that encapsulates a raw audio array
17:54:58
Shinmera
And then change the source interface to include generic versions to decode stuff into such arrays.
17:55:10
sjl
What's the deal with https://github.com/Shirakumo/harmony/blob/master/sources/mp3.lisp#L70-L96 then?
17:55:51
Shinmera
That was a hasty attempt at making things work as I was pressed for time before a jam.
17:56:10
Shinmera
It's not because it ties logic that's part of the decoding and logic that's just part of the buffer together.
17:57:11
Shinmera
We'll probably want some class that contains a data array, size, encoding, channels, structure, and sample rate, from which actual sources can then be spawned.
17:58:51
Shinmera
The idea would be that you'd keep this structure around and allocate it ahead of time, whereas sources are used to actually play it back at run time.
17:59:39
sjl
well, I guess if you wanted multiple concurrent copies of some audio effect, you'd need to have multiple sources
17:59:46
Shinmera
You can, but especially with sfx where you might need to play multiple instances of the same thing simultaneously, that doesn't really work.
18:00:09
Shinmera
And just logic-wise it's easier to simply say "hey, play this back" and not have to worry about reusing it if you don't have to.
18:43:21
sjl
Shinmera: I guess the thing that still feels weird would be the filling of that preloaded buffer, because it would use an mp3-source to fill a buffer which would then be used by sources
18:43:36
sjl
or are you thinking there would be some really basic (read-mp3-file-into-buffer ) function
18:50:44
Shinmera
The high-level interface would probably then also get a LOAD function analogous to PLAY that loads to this buffer struct thingy based on the source implementation.
18:52:47
Shinmera
While I'm on that, more source types is another obvious improvement area. Especially supporting WAV, OGG, and FLAC would be good.
18:56:55
Shinmera
More filter segments on libmixed would also be nice, particularly high/low-pass filtering, reverb, and distorion.
19:05:49
jmercouris
beach: seems like people are always conflating language with implementation, now that you've made me aware of the difference, I see it everywhere: https://getstream.io/blog/switched-python-go/?a=b
19:22:48
bigos
https://github.com/bigos/qtools-testdrive/blob/hello-notepad/src/qtools-testdrive.lisp
19:32:09
bigos
i guess i will try another time, i found few c++ examples but i have no clue how to translate them to qtools, i guess it's time to have a break
19:39:27
phoe_
bigos: I have some qtools experience that includes translating C++ Qt to CL Qtools, I might be able to help you later on here or #lisp-pl
20:09:01
jmercouris
What's a good way of declaring an interface in CL? Let's say I have like a superclass "Potato" and then I want child classes to implement "grow" methods, how could I force them to do that?
20:12:16
Shinmera
jmercouris: Generally you don't force people to do things in CL. Just document it.
20:12:40
phoe_
it's GPL though, I haven't been able to contact the maintainer to relicense it elsewhere
20:13:27
jmercouris
Bicyclidine: pjb: thank you guys for your help, I'll either copy the macro into my code or just not use interfaces
20:13:50
Shinmera
If you want to check whether you didn't forget to implement methods, you could build a little tool that traverses the class hierarchy and checks whether your applicable generic functions do have a method that specialises on each class.
20:13:53
jmercouris
maybe this is an X-Y problem, let me describe what I'm actually trying to do, and you can tell me whether you think my approach is sound
20:14:57
jmercouris
Alright, so I have some graphical view, and I want to implement two different backends, because I want 99% of my code to be agnostic to the different graphical backends, I want to create an interface with some expected behavior, that way I can make a change to the "core" of the program, and know that it will work with both interfaces
20:17:34
phoe_
https://github.com/robert-strandh/McCLIM/blob/b3546424f68ccc72c762ccb8be16400768ad2479/Core/clim-basic/protocol-classes.lisp#L24
20:18:48
phoe_
jmercouris: I've mailed the author if he can relicense that code, maybe we'll get him to respond.
20:20:06
jmercouris
phoe_: http://gplv3.fsf.org/wiki/index.php/Compatible_licenses#GPLv2-compatible_licenses
20:23:42
phoe_
it's full GPLv2, so even using this code as a library in your code counts as being infected with stallmanovirus
20:24:58
jmercouris
phoe_: that's what I'm saying, I can't pull it into my code, I refuse that license
20:27:51
phoe_
in the worst case, I'll just clean-room reimplement that macro based on its specification
20:39:41
pjb
Not necessarily. AFAIK, You could include GPL2 code in a LGPL library, and use this library in a BSD project, as long as the library doesn't contain core functinality of your project, and it may easily be replaced by a BSD library.
20:44:43
phoe_
https://softwareengineering.stackexchange.com/questions/342156/can-i-use-some-gpl-code-in-lgpl-project
20:48:13
jackdaniel
also saying, that pulling gplv2 to repository makes your code have same license is bs, it just means, that derived work is gplv2 - you still may copy your bsd code from the core library to other bsd project without any implications
20:52:20
jackdaniel
I would appreciate (if you really dislike LGPL2+) not linking McCLIM project with a disclaimer, that it is a virus or as being infected by something, it is rude and belittles work of many people
20:59:53
phoe_
but it is a viral license, as https://www.gnu.org/philosophy/vaccination.en.html itself states