Replies: 7 comments 34 replies
-
@baykus871 have a look at this list... any thoughts? |
Beta Was this translation helpful? Give feedback.
-
As a fellow language-designer (in Nim), first of all I must admit I admire your patience and commitment and craziness (and mine too lol). So, well done! Not that I'm an expert, but a few thoughts since I noticed the post and I have - at one point or another - played with some of the ideas...
I totally like the idea - even though my own - similar - site has been "under construction" for the past weeks. Most users want something quick and easy to get their hands dirty with. And that's probably the easiest way to make a new language accessible.
I'm not a fan of too... object-oriented languages and leaning towards minimalism is most definitely the opposite. I consider them too bloated. Plus, they are going slowly out of trend (thank god!).
Done that. Because, why not? I would prefer a minimalist, albeit as-batteries-included-as-possible approach. Plus, with Nim in mind, it's not difficult at all.
I have focused on the Webview idea. Think of Flutter but in a more ... alternative language. Why not? Also, libui is a great - quite OS-agnostic - option. In any case, great job! Keep up the passion. You have my respect! ;-) |
Beta Was this translation helpful? Give feedback.
-
This can be done via custom type definitions and dictionaries. Special types offers special dictionaries too. And that makes: After that, there can be some methods to handle with these like:
|
Beta Was this translation helpful? Give feedback.
-
You don't like but generics should be usable in Min. For example of usage:
and then:
|
Beta Was this translation helpful? Give feedback.
-
That is useful! |
Beta Was this translation helpful? Give feedback.
-
|
Beta Was this translation helpful? Give feedback.
-
Overall, I do like a lot of the ideas in this post. I'd like to refer to the issue I made almost three years ago. Since it seems like dynamic libraries aren't going to be a thing (which I honestly think is for the better, as they are a hassle to get working cross platform in other programming languages as well), would it be possible to add a simple wrapper around nimquery for web scraping? Many scripting languages have web scraping functionality. min can technically web scrape - it just isn't easy and requires parsing the HTML/XML by hand. I noticed that you were considering adding DSL for HTML/XML. Before that, I think it might make sense to add a way to quickly match existing HTML/XML strings.
I think that only a standard min flavor (the one with everything) should be offered unless someone can make a good case for the other smaller versions. Fragmentation is never good for languages, especially since (as far as I know) to run a certain min script you might need to change the flavor that you have installed on your machine. This could be replaced by a section that describes how to compile a more minimal version of min, similar to the one currently on the website. That way power users can still have the customization that they need without confusing novices.
I haven't read any other related information to this feature, so correct me if I am wrong. I think that a try online website would be pretty nice, just because min is pretty unconventional compared to other languages. I think that this is a nice feature, but I wouldn't consider it essential. The WASM route is probably the best one, but you have already tried it so it isn't simple/straightforward.
I would shy away from frameworks that describe GUIs using only web languages. Specifically, I don't know how I feel about using JS instead of min for a GUI application. Very generally, I think that a non-native gui (fidget, mui, dear-imgui, nuklear, etc...) would probably be best. A native GUI isn't consistently displayed between different machines. Additionally, non-native GUIs are easier to extend and work off of. While this might be abusing min (a lot), if someone wanted to implement something like google maps using min, the framework itself shouldn't limit them.
I think that this might be kind of nice to have, but also opens up a can of worms with supporting other DBs. This might be the exact kind of problem dynlibs would solve lol. sqlite is a good fit though if you decide to only include a single database, as it is fairly minimal as very fast. Quite a bit of text here, but remember that you don't need to implement anything I say 😄. You've done a great job with min and I do enjoy using it for smaller tasks with nim would be overkill, especially the REPL. Keep up the good work! |
Beta Was this translation helpful? Give feedback.
-
Right, I started thinking about releasing version 1.0.0 of min. The idea is to do so once the API stabilizes a bit, and overall it has been mostly stable (except a few symbols being removed or changed) for quite some time now, so we could be close, but there are still quite a few things that don't feel quite right yet, and possibly some (major?) incompatibilities to introduce before the big milestone. I just wonder what other people think...
What to include in the prelude?
At present, all standard library (native) modules are automatically imported at startup. This happens in the prelude file which is executed every time min starts up. While this is convenient and (until recently) it was the easiest way to use the symbols exposed in those modules, it also meant that there could be clashes in symbol names... which in turn lead to symbols being called
fwrite
ordswrite
etc., just to avoid collisions.Now min provides a more robust way of requiring modules and invoking methods, so maybe instead of using
dswrite
it would be possible to just call*dstore/write
, without importing the wholedstore
module by default.What do you think? Should the prelude only load and import a few of the stdlib modules like
Lang
,str
,seq
, but maybe don't import modules likecrypto
ordstore
?Searchable min-lang.org
This is an obvious one. min-lang.org should be searchable, to make it easier for developers to go through the min documentation.
I'll probably use LiteStore to add a full-text search API. The only problem is that at present there would be no direct link to a specific min operator, as they are grouped by module, so if you search for
invoke
you'd end up on thelang
module page."try min" online
It would be cool to be able to try min online. Other languages like Ruby and Nim itself provide a way to do so. For example, the Nim playground lets you compile your own Nim program on the fly.
The code is actually open source, and they are basically executing the compilation in a docker container. Min could provide something similar, but it would be better to offer a REPL-like experience. The catch? Security obviously, because I don't fancy exposing the full power of min to the internet unless it's through a completely sandboxes environment. Any idea on how to realize this? Yes, probably a docker container...
On the other hand, there are so many programming languages that don't offer anything like this and are surviving just fine, so meh...
min flavors vs. additional compilation flags
min currently comes in three flavors: standard, lite, and mini. Additionally, you can compile it with or without SSL support. Is this really needed? Would it make more sense to provide different compilation flags to specifically enable/disable each module (besides
lang
)?Not entirely sure. Maybe provide many different switches and release just the standard (full) min could be better. Any thoughts on this matter?
(See also #76 for more details)
What else is missing?
Then... well, there are a few other things on the radar, some are already planned as a matter of fact, others not so much. Let's see...
Multiline comments (planned)
Originally I was not gonna add them but they are kinda useful after all. They are probably going to be lispy flavored (like single-line comments), so something like this:
custom type definitions (planned)
This could be a very useful extension to make the
operator
symbol even more powerful. Essentially, create a new "type definition" representing a check to execute on a value. More info on #73.proc module (planned)
While there's already
exec
andrun
, it would be useful to provide access to running processes, suspend them, stop them, start them, etc. Essentially a min wrapper of some of the functionalities exposed by Nim's osproc module.Object system (probably dropped)
I don't think I am gonna bother with this. After all this language is supposed to be minimalist! You can already use dictionaries (and
invoke
works on plain dictionaries as well), and typed dictionaries like modules, errors, etc. I wouldn't like to add things like inheritance, not gonna go down that rabbit hole -- just use functional or concatenative programming instead!Dynamic libraries (probably dropped)
This used to be an implemented feature (see #8), but it wasn't working reliably, so it has been dropped for some time. Don't think we can resurrect this unless someone else comes up with a nice and tidy (with docs and tests) PR.
xml module (not sure)
Not sure if this would be beneficial or not. The idea would be exposing a module to easily write XML (and HTML) code in min. There's something like this for some lisps, e.g. PicoLisp's html function, but in a concatenative language with postfix notation it could look somewhat weird.
Imagine something like this:
Interesting, but not very intuitive. Perhaps it could operate in prefix notation instead, but then you'd expect some sort of interop with strings containing XML code I guess, and so an XML parser should be included in the language... not sure, but it could be cool.
yaml module (not sure)
Same as above... a YAML parser is quite big, and not sure if it would be that useful considering min is fully-interoperable with JSON already. There are already
from-yaml
andto-yaml
symbols, but they only work for simple objects containing strings (basically useful for extremely simple semicolon-separated frontmatters).sqlite module (not sure)
This would be cool, but it would increase the size of the executable. That's the only drawback really, otherwise I would have implemented it already. Instead, currently there's support for persisted in-memory (JSON) data stores in the dstore module. Kinda does the job for persisting (small amounts of) data, but it's far from being called a proper datastore, nevermind a database.
ui module (not sure/stuck)
Creating minimal UIs in min would be awesome, the problem is how. There's a lot of good UI libraries out there, some even fairly minimal but I didn't find anything suitable right now, especially nothing that has already been powered to Nim. Some of the possibilities are:
Benchmarks (not sure/stuck)
Last time I tried implementing some benchmarks it didn't quite work out as planned and I got depressed (see #31). The fact is that min is fast enough. How much is enough you say? Well, enough.
Improved multi-line REPL (stuck)
Cool idea but difficult to implement. See #52 and h3rald/minline#12.
compile to JavaScript or WASM (stuck)
That was the idea behind minimin. Tried it, didn't go too far. If anyone else wants to give it a try, please do! It could be an easy way to implement an online min playground!
Beta Was this translation helpful? Give feedback.
All reactions