AROS World Exec
General => General Chat => Topic started by: PurpleMelbourne on December 11, 2018, 07:08:39 PM
-
Hello all,
I don't know if everyone is up to date with the evolution of ARexx, or that Carl Sassenrath, the creator of most of AmigaOS (including exec) created the Rebol language. But as I'm not a coder myself, I'm hoping that someone has.
Because I know that ARexx can be updated to OORexx (Object Oriented) or further updated to NetRexx (Rexx+Java). But I don't know if Rebol makes a newer Rexx redundant.
If we were to have greater compatibility with the industrial OS/2 then perhaps updating to OORexx or NetRexx should happen.
Thoughts?
-
Python is THE "scripting/glue" programming language, with a VAST support and continuously increasing its adoption in practically any area.
It does NOT make sense to spend time/resources on trying to revival A/REXX. Better to port a modern Python version (2.7 doesn't make sense anymore, since it'll be completely EOL 1st January 2020) to AROS.
-
So we can use it to replace ARexx?
-
So we can use it to replace ARexx?
Not yet. The AmigaOS 4 library hasn't been ported to other Amiga-like operating systems. Currently AROS uses Regina which is an open source REXX interpreter.
-
So we can use it to replace ARexx?
Not for everything. Python cannot be used to entirely replace AREXX.
The AmigaOS 4 library hasn't been ported to other Amiga-like operating systems.
OS4 has no AREXX library: it reuses the 68K one directly coming from the Amiga o.s. 3.x.
-
The AmigaOS 4 library hasn't been ported to other Amiga-like operating systems.
OS4 has no AREXX library: it reuses the 68K one directly coming from the Amiga o.s. 3.x.
I meant the Python library it uses to access AREXX ports.
-
Ah, ok. Now I got it.
In the bounty which I've written for porting Python to AROS (https://power2people.org/projects/python/), I'd put a link to an old Python port (http://www.monkeyhouse.eclipse.co.uk/amiga/python/) which includes AREXX support. You can download the sources (http://www.monkeyhouse.eclipse.co.uk/amiga/python/AmigaPython-2.3.3a2_src.lha), and searching REXX you'll find the code.
The only problem is that the Python module has a small part written in 68K assembly, that should be ported to x86/x64/ARM, to make it work on AROS.
-
So can Python replace all the functionality of ARexx? Or is it only a 75% overlap?
-
From a pure functional point of view, Python can do MUCH better than AREXX.
However there are existing AREXX scripts or macros that need the be still executed, and in this case a parser + interpreter is still needed.
Everything else can be covered by Python.
-
A surgeon can do a lot better than a plumber. But they are not the same thing.
OK Python can do things that ARexx.
BUT can it do EVERYTHING that ARexx does? Can it replace the existing functionality?
I'm not asking if Python can do things Rexx cannot. I'm asking if Python can do ALL the things that Rexx can do.
Can Python REPLACE ARexx or can it only add to it?
-
As I said before, Python CANNOT replace the existing AREXX scripts or macro, for obvious reasons: they are completely different languages.
For the rest, a Python application can create AREXX ports, so being "reachable" by other AREXX-aware applications. And, as well, can send messages to other applications which are reachable through their AREXX ports.
TD;DR: no, Python cannot completely replace AREXX.
-
So although Phython does not deliver compatibility with existing REXX scripts, on a functional level it can do EVERYTHING which you can do with REXX regarding talking between applications using the AREXX ports?
OK then it does sound like going forward that Python can functionally replace ARexx :-)
So no need to upgrade from ARexx to one of the new ones. We would simply keep legacy ARexx, but mostly replace it with Python for the future. If you have existing ARexx scripts, they can be replaced with Python scripts using the ARexx ports.
I suppose its the ARexx ports that matter. It sounds like Python is the sensible general purpose solution.
-
Exactly.
BTW, it might be possible to create an AREXX interpreter in Python, although it'll be slow in execution, so not suitable for low-end systems (e.g.: 68K machines).
-
Existing ARexx code aside, isn't Lua a better alternative today than ARexx?
Lua is reasonable lean and can interact with applications in some ways that resemble ARexx, at least inside a process, some adaption to Amiga message system would probably be a good idea. It seems to have some momentum too.
Python, as mentioned is a good alternative, very mainstream, but it is a more heavy.
I would prefer moving towards both Python and Lua over ARexx, having used all three to some degree in the past.
-
RUST sounds like a good language in place of C++ to bond nicely with Assembly at the lowest levels. If the Amiga 3.1 source were translated into RUST, would that not make it a new piece of work according to the 15% difference engineering principle? And thus technically it could be an Open Source "original" work?
Python is very popular, and it sounds pretty good for the general purpose. Not sure it quite deserves to be called excellent? Is it that good that keeps with the Amiga spirit? A bit of popularity wouldn't go astray for a change of pace ;-)
Rebol is written by Carl Sassenrath, the father of Amiga's multitasking. It sounds excellent. So if it really is fit for purpose and not just exageration, then it seems part of our heritage to use it. And R3 of Rebol sounds very fit for purpose to do an "Amiga DE" networked ecosystem type of thing.
Does anyone know if Rebol has JIT? Or plans for it if not currently implemented?
Where would LUA fit in as far as the general public go? Should it be a sponsored part, or just another thing you can do if you are interested?
OORexx and NetRexx are sounding like out in the cold as far as going forward.
-
Converting the Amiga o.s. 3.1 sources to RUST is practically impossible: too much assembly language used, and a lot of work to do that nobody will do. It's not even convenient using AROS sources (C code) for similar reasons: no man power to do it (anyway RUST should first be ported to AROS, and here there's a similar problem).
Regarding LUA, yes: it's much more lightweight compared to Python. No doubt. And it's also a simpler language. That's the reason why it's usually preferred when you need something easier to embedded the scripting language (embedding LUA is trivial) and/or a small footprint (AFAIR its library takes around 200KB. But it passed long time since when I tool a look at it) and/or a simple language.
However the problem with languages such LUA, Ruby, R, Rebol, etc., is that they have not so much audience compared to Python, whereas the latter it's so much widespread now that has a MASSIVE support (many native libraries and wrappers to C/C++/Fortran libraries).
What can happen when you decide to use, say, Rebol, is that you start doing something. Then your script becomes more complex. And while adding new features you may want to use some functionality which you don't find in its standard library neither in some third-party one. Then basically you had to find a proper C/C++ library and write a Rebol wrapper for it: good luck!
So, it's really a practical question: with Python it's way easier to find a package (usually on the standard PIP packages site) for some functionality that you need. And even if you don't find it, there are many ways / tools (ctypes, cffi, cython, C++::BOOST, etc.) to quickly create a wrapper for it.
-
RUST sounds like a good language in place of C++ to bond nicely with Assembly at the lowest levels. If the Amiga 3.1 source were translated into RUST, would that not make it a new piece of work according to the 15% difference engineering principle? And thus technically it could be an Open Source "original" work?
It is not practical to take OS 3.1 and rewrite the C parts in Rust. First of all there are assembly language code in 3.1 that you cannot just take, it would violate the copyright. Second, if you where to rewrite it in Rust (translate), then you essentially end up with AROS written in Rust, and how many years have been spent on developing AROS so far?
Python is very popular, and it sounds pretty good for the general purpose. Not sure it quite deserves to be called excellent? Is it that good that keeps with the Amiga spirit? A bit of popularity wouldn't go astray for a change of pace ;-)
Rebol is written by Carl Sassenrath, the father of Amiga's multitasking. It sounds excellent. So if it really is fit for purpose and not just exageration, then it seems part of our heritage to use it. And R3 of Rebol sounds very fit for purpose to do an "Amiga DE" networked ecosystem type of thing.
Does anyone know if Rebol has JIT? Or plans for it if not currently implemented?
Where would LUA fit in as far as the general public go? Should it be a sponsored part, or just another thing you can do if you are interested?
OORexx and NetRexx are sounding like out in the cold as far as going forward.
If we look back to the old days (1970-80), a computer always came with a langauge with the intention that you could program it. This was often BASIC (I would have wished they would have picked Forth, but that is another discussion). All "home" computers were like that. When the Amiga arrived, that thinking was still very much present, which is why it was so important to have a language come with it (Microsoft BASIC). I remember when the Amiga (1000) was introduced that the graphics, sound and multitasking was the big thing. It was like coming from the future and blew everything away. In addition to this, there was also a strong thinking about all the languages you could use on it.
With the IBM PC and Macintosh, this thinking changed as people wanted to use their computers and not program it. Thus, application software and aimed for offices, for productivity.
The Amiga and other computers also came with programs to buy and hopefully "the killer app". But here there was (still) a stronger thinking that you should program it.
Today we get a computer with an operating system with a lot of things bundled with it, just look at anything like Linux, macOS or Windows. Loads of software and colourful icons/launchers to start the programs. Then you may add on some professional productivity on your own. There is not much thinking about languages anymore.
The Raspberry Pi is a bit different here in that it is supposed to be tinkered with and programmed, mainly for kids. The languages of choice seems to be Python and Scratch.
The Amiga originally had its Microsoft BASIC, but it was a dead end. Along came ARexx which became the language for the Amiga, which also had the ability to be used as a scripting glue language. You did not grow out of it even if you switched to a more "serious" language, you could still have it for as making your developed app customized by the end user.
What I am getting at here is that the thinking of computers have changed a lot since the era of the Amiga. But not everything has to be the same. Look at the Raspberry Pi which has a different thinking. Play with it, program it, connect it and have fun. Maybe we should think about where we want AROS to be. Is it a replacement OS for the Amiga, for some old people that have not passed away yet and that cannot let go
of the past? Should it try to compete with the main operating systems with a lot of apps? Maybe it would be better to look at tinkering market, much what RPi is used for? I can see that I could want to make things to interact with the world and do that on a small RPi/AROS box.
Getting back to topic (about languages). I think having a decent range of well supported programming languages could be a key part for AROS. ARexx is well established and should stay, Python is popular, but there is a long list to choose from, Rust, Golang, Scheme, Lisp, Lua and so on, just pick some (few) that are suitable for the platform and try to make them work well.
As I mentioned Lua, I think Lua is what should be picked today over ARexx if we where starting out fresh. Now we already have ARexx, so it has a bit less of a need. However, Lua is a multi-paradigm language that can act as a glue language and it is fairly light weight. I think it fits in quite nicely as an alternative to Python and ARexx.