Groups keyboard shortcuts have been updated
Dismiss
See shortcuts

installing on Ubuntu

121 views
Skip to first unread message

r...@amalasoft.com

unread,
Nov 12, 2022, 5:14:17 PM11/12/22
to Eiffel Users Group
 Hi All
I've avoided this for quite a while now - ever since my old CentOS box gave its neck quite some time ago.  I finally broke down and created a VirtualBox VM with Ubuntu Linux, on which to install Eiffel and see if my hundreds of classes (that I have offered for free to the Eiffel community for many years, though with very limited takeup) would build ok.
Setting up the VM was more of a pain than I recall, as the Ubuntu distro didn't have gtk and a few other bits I'd taken for granted in the past.  I managed to find the cutesy apps that are used for that, without too much effort.
For Eiffel, I figured it's high time I tried the latest version, so I downloaded (directly into the Ubuntu VM), the 22.05 linux-x86-64 package and then the fun started.
I noticed, after beating my head against the wall for a while, that the .ecf files in the precomp folder were all for Windows - with backslashes in the paths and, yet more baffling, the "wel" cluster.
It wasn't just the vision2 ecfs, it was all of them (w/o the wel part).  The platform was specified as windows, for some unexplained reason.
Add to that confusion the fact the, despite being directed to install (unzip) into /usr/local/<Eiffel Version>, there seems to be hardwired, somewhere, a totally different path (the ~/.es/eiffel_blahblah stuff, that was missing the precomp .ecfs anyway.
I'm done until somebody can explain why either 1. I'm more or an idiot than I realized, or 2. how the heck to get this done so that I can try to test some extant stuff (and to try to continue to hail Eiffel's portability).
And No, this is NOT .Net.  I'll need to take a break between getting the "easy" stuff to work and heading down that path (but it will come).
Thanks
R

Ulrich Windl

unread,
Nov 14, 2022, 2:22:02 AM11/14/22
to eiffel...@googlegroups.com
>>> <r...@amalasoft.com> schrieb am 12.11.2022 um 23:14 in Nachricht
<20221112151414.cf48dd763fcaf5d4...@email25.godaddy.
om>:
> Hi All
> I've avoided this for quite a while now - ever since my old CentOS box gave
> its neck quite some time ago. I finally broke down and created a VirtualBox
> VM with Ubuntu Linux, on which to install Eiffel and see if my hundreds of
> classes (that I have offered for free to the Eiffel community for many years,
> though with very limited takeup) would build ok.

If you like pain and VMs, you could also try Qubes OS: There creating VMs is rather painless, but exchanging data can be quite paoinful due to the high security. However per standard, there's only Debian (11 at the moment) and Fedora (can't remember the current number, they change so fast) for user VMs available.

> Setting up the VM was more of a pain than I recall, as the Ubuntu distro
> didn't have gtk and a few other bits I'd taken for granted in the past. I
> managed to find the cutesy apps that are used for that, without too much
> effort.
> For Eiffel, I figured it's high time I tried the latest version, so I
> downloaded (directly into the Ubuntu VM), the 22.05 linux-x86-64 package and
> then the fun started.
> I noticed, after beating my head against the wall for a while, that the .ecf
> files in the precomp folder were all for Windows - with backslashes in the
> paths and, yet more baffling, the "wel" cluster.
> It wasn't just the vision2 ecfs, it was all of them (w/o the wel part). The
> platform was specified as windows, for some unexplained reason.

Well, it's little known, but slashes work for almost all Windows filesystem calls (just as backslashes do).
So Eiffel could use slashes everywhere. However some hardcore Windows users might get upset seeing forward slashes in paths...

> Add to that confusion the fact the, despite being directed to install
> (unzip) into /usr/local/<Eiffel Version>, there seems to be hardwired,
> somewhere, a totally different path (the ~/.es/eiffel_blahblah stuff, that
> was missing the precomp .ecfs anyway.

That does not sound good.

> I'm done until somebody can explain why either 1. I'm more or an idiot than
> I realized, or 2. how the heck to get this done so that I can try to test
> some extant stuff (and to try to continue to hail Eiffel's portability).
> And No, this is NOT .Net. I'll need to take a break between getting the
> "easy" stuff to work and heading down that path (but it will come).

Maybe a packaging error.

> Thanks
> R
>
> --
> You received this message because you are subscribed to the Google Groups
> "Eiffel Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to eiffel-users...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/eiffel-users/20221112151414.cf48dd763fcaf5d
> 42559c6c92f6fc53b.726ecbd1f1.wbe%40email25.godaddy.com.



Louis M

unread,
Nov 14, 2022, 9:57:12 AM11/14/22
to eiffel...@googlegroups.com

Hello R,

I just try to install the Eiffel 22.05 package on Ubuntu 22.04 and everything work like a charm (at least, for a basic hello world and a basic Vision 2 applications). As I remember it, the ecf files of EiffelStudio always used backslashes, but the Eiffel compiler seems to be able to adapt it depending on the system. Here is what I did so that you can see what the problem is:

# sudo apt install libgtk2.0-dev libxtst-dev libgtk-3-dev
# sudo tar xvfj Eiffel_22.05_rev_106302-linux-x86-64.tar.bz2 -C /usr/local/
# export ISE_EIFFEL=/usr/local/Eiffel_22.05
# export ISE_PLATFORM=linux-x86-64
# export PATH=$PATH:$ISE_EIFFEL/studio/spec/$ISE_PLATFORM/bin
# estudio

You may have to erase (or rename) the ".es" directory in the home directory to make it work.


I hope this helps.

Good day,

Louis M

r...@amalasoft.com

unread,
Nov 14, 2022, 10:25:53 AM11/14/22
to eiffel...@googlegroups.com
Thanks Louis, but that's not what I'm seeing.  The first big issue, for me, is that the tarball I downloaded  has Windows-oriented ecf files, including "wel" clusters in the vision2 precomp ones.
The other big issue is that, despite extracting the tarball into /usr/local, something in ec is looking to /usr/lib for the Eiffel libraries, and, just for fun, expects to see stuff in the  "$ISE_LIBRARY/library" (zero style points for that one, but it pays NO attention to the value I have set in my 'dot' files, so I had to add sym links from what seem to be hard-coded paths (in /usr/lib) to the actual, recommended location in /usr/local.
The tarballs I downloaded were the "linux" ones, and I downloaded them from the Ubuntu VM (in VirtualBox), just to be sure that the platform wasn't overriding my explicit selection of "linux".
Another issue, when I hand-tweak all the paths, is that after FINALLY being able to execute 'ec', it expects me to call, from the W or F dirs, a finish freezing that has the $ISE_PLATFORM value on the end of it.  There is not such script or app anywhere in the distribution.
It's all so wrong that I can only guess that it's some evil spirit trying to get me to switch to some horrible language (that's not going to happen, but imagine if I were a newby and not a 30-year Eiffel veteran).
Ugh.
R

Louis M

unread,
Nov 14, 2022, 10:56:26 AM11/14/22
to eiffel...@googlegroups.com

Did you export the environment variables "ISE_EIFFEL" and "ISE_PLATFORM" (and possibly "ISE_LIBRARY" and "EIFFEL_LIBRARY"). Because without these, the Eiffel compiler looks indeed in /usr/lib/EiffelStudio for libraries.

But I do agree that the fact that veteran programmer has difficulties does not look good for the new programmer.

Good day,

Louis M

r...@amalasoft.com

unread,
Nov 14, 2022, 11:31:41 AM11/14/22
to eiffel...@googlegroups.com
Hi Louis
I have "sourced" them, and also logged out and back in.  I checked the values with echo $ISE_LIBRARY and other interesting ones, and, at least in the terminal window, the values appear correct.  Not sure if there might be an issue with exec-ed programs, but they should get the values from the enclosing shell.  I'll try explicit exports in the .bashrc and .profile declarations, just for fun.
Thanks
R

Ulrich Windl

unread,
Nov 15, 2022, 2:08:32 AM11/15/22
to eiffel...@googlegroups.com
>>> "'Louis M' via Eiffel Users" <eiffel...@googlegroups.com> schrieb am
14.11.2022 um 15:57 in Nachricht
<ff5d8782-58b8-c7cc...@tioui.com>:
> Hello R,
>
> I just try to install the Eiffel 22.05 package on Ubuntu 22.04 and
> everything work like a charm (at least, for a basic hello world and a
> basic Vision 2 applications). As I remember it, the ecf files of
> EiffelStudio always used backslashes, but the Eiffel compiler seems to
> be able to adapt it depending on the system. Here is what I did so that
> you can see what the problem is:
>
> # sudo apt install libgtk2.0-dev libxtst-dev libgtk-3-dev
> # sudo tar xvfj Eiffel_22.05_rev_106302-linux-x86-64.tar.bz2 -C /usr/local/
> # export ISE_EIFFEL=/usr/local/Eiffel_22.05
> # export ISE_PLATFORM=linux-x86-64
> # export PATH=$PATH:$ISE_EIFFEL/studio/spec/$ISE_PLATFORM/bin
> # estudio
>
> You may have to erase (or rename) the ".es" directory in the home
> directory to make it work.

Hi!

My expectation is that any upgrade should handle such a case, not requiring the user to remove anything manually (actually I never liked the concept of having some directory outside installation and working directory that contains a lot of stuff). We are in 2022, no longer setting interrupt jumpers on ISA cards ;-)

Regards,
Ulrich


Ulrich Windl

unread,
Nov 15, 2022, 2:11:14 AM11/15/22
to eiffel...@googlegroups.com
>>> <r...@amalasoft.com> schrieb am 14.11.2022 um 16:25 in Nachricht
<20221114082549.cf48dd763fcaf5d4...@email25.godaddy.
om>:
> Thanks Louis, but that's not what I'm seeing. The first big issue, for me, is
> that the tarball I downloaded has Windows-oriented ecf files, including "wel"
> clusters in the vision2 precomp ones.
> The other big issue is that, despite extracting the tarball into /usr/local,
> something in ec is looking to /usr/lib for the Eiffel libraries, and, just
> for fun, expects to see stuff in the "$ISE_LIBRARY/library" (zero style
> points for that one, but it pays NO attention to the value I have set in my
> 'dot' files, so I had to add sym links from what seem to be hard-coded paths
> (in /usr/lib) to the actual, recommended location in /usr/local.
> The tarballs I downloaded were the "linux" ones, and I downloaded them from
> the Ubuntu VM (in VirtualBox), just to be sure that the platform wasn't
> overriding my explicit selection of "linux".
> Another issue, when I hand-tweak all the paths, is that after FINALLY being
> able to execute 'ec', it expects me to call, from the W or F dirs, a finish
> freezing that has the $ISE_PLATFORM value on the end of it. There is not such
> script or app anywhere in the distribution.
> It's all so wrong that I can only guess that it's some evil spirit trying to
> get me to switch to some horrible language (that's not going to happen, but
> imagine if I were a newby and not a 30-year Eiffel veteran).

Could it be there is a mismatch between the syntax your shell expects and the syntax you use? Meaning: Are you sure the environment variables are set up correctly?
> https://groups.google.com/d/msgid/eiffel-users/ff5d8782-58b8-c7cc-2d97-5804b8
> 74d558%40tioui.com.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Eiffel Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to eiffel-users...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/eiffel-users/20221114082549.cf48dd763fcaf5d
> 42559c6c92f6fc53b.fd2df9262a.wbe%40email25.godaddy.com.


r...@amalasoft.com

unread,
Nov 15, 2022, 7:28:12 AM11/15/22
to eiffel...@googlegroups.com
Thanks Ulrich
I've verified that the vars are valid in the executing shell(s), of course.  Even verified, I need to add sym links from /usr/lib to the actual location in /usr/local.
None of the "slash direction", env vars, and such explains the "wel" references in the vision2 ecf files,
or the lack of 'config" files when attempting to finish_freezing, or the message from ec that says I need to call finish_freezing-<version num>, or the lack of error messages or non-zero exit codes after failing to launch estudio (though I do, now, get the opening banner before it exits), or other things.
The tarball, at least, has the wrong .ecfs.  The installation instructions on the website do not explain what is happening.
This is likely an easy fix, if someone in power would take a look, and in the mean time, it's an embarrassment that Eiffel can ill afford.  All I wanted to do was to verify that my existing classes _still_ worked on a Linux platform, just as they used to.  My goal, assuming that, was to show evidence of my claim that Eiffel is portable across Windows and Linux, and maybe, just maybe, get somebody to try it.
R

-------- Original Message --------
Subject: Antw: [EXT] RE: [eiffel-users] installing on Ubuntu
From: "Ulrich Windl" <Ulrich...@rz.uni-regensburg.de>
Date: Tue, November 15, 2022 2:10 am
To: <eiffel...@googlegroups.com>

>>> <r...@amalasoft.com> schrieb am 14.11.2022 um 16:25 in Nachricht

Louis M

unread,
Nov 15, 2022, 8:34:17 AM11/15/22
to eiffel...@googlegroups.com

I know that this is not what you are looking for. But since it works great on my machine, as an alternative, do you want me to test your libraries to see how it goes. Do you have a test suite you want me to launch?

Good day,

Louis M

r...@amalasoft.com

unread,
Nov 15, 2022, 8:45:44 AM11/15/22
to eiffel...@googlegroups.com
Thank you Louis, for that incredibly generous offer, but be careful what you sign up for :) (there are well over 800 classes)
I'd very much like that, at some point, along with trying some of the apps I've written over the years, but I'd rather get this mystery solved, and get things squared away first.
Thanks
R

Jocelyn Fiat

unread,
Nov 15, 2022, 8:47:52 AM11/15/22
to eiffel...@googlegroups.com
Hi ,

I am surprised that installing EiffelStudio is not as expected.
You may also want to use the installation script from https://www.eiffel.org/setup/
It is helpful to automate installation for CI tasks.

The simple way to use it
it will download the latest stable version, and install in the current working directory, in the case of Eiffel 22.05, it will be installed in sub directory ./Eiffel_22.05/
In addition, the script creates a file  in ./Eiffel_22.05/setup.rc to help setting the environment to use that EiffelStudio installation.
In most shell, from terminal, you can do "source ./Eiffel_22.05/setup.rc"  or you can copy the content to your .bashrc, or .zshenv, or similar setting file.

I hope it helps,
Best regards,





--
Jocelyn
------------------------------------------------------------------------
Eiffel Software
https://www.eiffel.com
Customer support: https://support.eiffel.com
User group: https://groups.google.com/forum/#!forum/eiffel-users
------------------------------------------------------------------------

Louis M

unread,
Nov 15, 2022, 9:30:41 AM11/15/22
to eiffel...@googlegroups.com

Well, that will, of course, depend on how time consuming the process is. But I don't care helping a fellow library creator when needed.

Good day,

Louis M

r...@amalasoft.com

unread,
Nov 15, 2022, 9:36:16 AM11/15/22
to eiffel...@googlegroups.com
Thanks Jocelyn!  I'll give that a try!
R
-------- Original Message --------
Subject: Re: Antw: [EXT] RE: [eiffel-users] installing on Ubuntu
From: Jocelyn Fiat <jf...@eiffel.com>
Date: Tue, November 15, 2022 8:47 am
To: eiffel...@googlegroups.com

Hi ,

I am surprised that installing EiffelStudio is not as expected.
You may also want to use the installation script from https://www.eiffel.org/setup/
It is helpful to automate installation for CI tasks.

The simple way to use it
it will download the latest stable version, and install in the current working directory, in the case of Eiffel 22.05, it will be installed in sub directory ./Eiffel_22.05/
In addition, the script creates a file  in ./Eiffel_22.05/setup.rc to help setting the environment to use that EiffelStudio installation.
In most shell, from terminal, you can do "source ./Eiffel_22.05/setup.rc"  or you can copy the content to your .bashrc, or .zshenv, or similar setting file.

I hope it helps,
Best regards,



Jocelyn
------------------------------------------------------------------------
Eiffel Software
https://www.eiffel.com
Customer support: https://support.eiffel.com
User group: https://groups.google.com/forum/#!forum/eiffel-users
------------------------------------------------------------------------
--
You received this message because you are subscribed to the Google Groups "Eiffel Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to eiffel-users...@googlegroups.com.

r...@amalasoft.com

unread,
Nov 16, 2022, 3:18:01 PM11/16/22
to eiffel...@googlegroups.com
Hi Jocelyn

Well, that went a heck of a lot more smoothly.  I still have issues, but that's a separate story (and thread)
I began, before, by downloading the tarball directly from account.eiffel.com.


It had the wrong stuff in it, apparently, include the aforementioned references to "wel" in the vision ecfs.  That cannot be right.  If the script is the way to do it, versus the download method, it should be pointed out at the download site AND the content of the tarballs really needs checking.

Having downloaded anew (via the script, as you suggested), and fiddling a tiny bit with the stuff I had fouled up before, installation went very smoothly indeed!!  Many thanks.

That's the good news.

When I went to compile a small (but GUI) test program, I encountered a rather unsettling error.
I have a venerable class that traverses a directory and, during traversal, builds a string for an error message (using append).
I now get this VUAR(2) error: Actual argument type: IMMUTABLE_STRING_32.

It seems that (and I might be wrong with my assumption) it is the string size that is the issue, and not the readable/immutable difference (immutables are children of readables).

The offending line is:
m.append ("Directory [" + path.name + "] does not exist.")

The source code is declaring the args and vars as "STRING"s
Is the size of string constants in 22.05 now set tp 32 bits, regardless of any other system settings?

Thanks

Alexander Kogtenkov

unread,
Nov 21, 2022, 5:20:40 AM11/21/22
to eiffel...@googlegroups.com
There were changes in the strings classes to guarantee absence of data loss. In particular, (IMMUTABLE_)STRING_32 no longer automatically converts to (…)STRING_8. The opposite conversion is OK. Given that (I assume that) `path.name` is of type IMMUTABLE_STRING_32, the type of the computed actual argument is also a 32-bit string, whereas the type of the formal argument is 8-bit.
 
A quick-and-dirty solution is to try `path.name.to_string_8`. As soon as it works, you can consider changing the library/program to use 32-bit strings instead of 8-bit ones in the future versions.
 
Hope this helps,
Alexander Kogtenkov
 
 
Wednesday, November 16, 2022 11:18 PM +03:00 from r...@amalasoft.com:
 

r...@amalasoft.com

unread,
Nov 21, 2022, 8:04:53 AM11/21/22
to eiffel...@googlegroups.com
Thanks Alexander!  That's what I did (the to_..8).  Changing every string instance to 32s might seem the next logical step, but will increase the memory footprint for every application.  I will, however, redo any strings having to do with "the outside world", like file and directory names, to assume 32 unless told otherwise.  It seems we've already taken the leap to increase the char size in the program text, to support all those cute new operators like ++, +=.  Oops, my bad, I'm confusing the new Eiffel syntax additions with C++.  Sorry,

For those not yet dealing with the 32-8 issue (if anyone), be certain to check that conversion using to_string_8 is viable by calling is_valid_as_string_8 (or relying on the precondition in to_string_8 if you don't mind throwing an exception, I suppose).
 I'd like to find a better (and easier) solution than converting everything to 32, but nothing jumps out at me at the moment.  For the memory consumption issue, perhaps we could have STRING_GENERAL be a but more general, and have the compiler decide when/if shrinking to 8 bits is viable.  Or not.  Just a thought.
Thanks again,
R

Ulrich Windl

unread,
Nov 22, 2022, 2:00:15 AM11/22/22
to eiffel...@googlegroups.com
Hi!

I think from a software engineering point of view the whole STRING thing is a
big mess:
Shouldn't there be a single STRING type possibly with an "encoding"
attribute?
So strings could be converted as needed, but typically one application would
use only one type of STRING encoding.
Also when starting with an encoding like UTF-8 it should satisfy most needs.

Maybe for interfacing (APIs, etc.) there could be another type of string that
has implicit encoding, but the main STRING type should be able to generate such
and constructors should be able to convert from such. So user-visible strings
should just be STRING.

Regards,
Ulrich

>>> <r...@amalasoft.com> schrieb am 21.11.2022 um 14:04 in Nachricht
<20221121060447.cf48dd763fcaf5d4...@email25.godaddy.
om>:
> ( http://e.mail.ru/compose/?mailto=mailto%3aeiffel%2du...@googlegroups.com)
> wrote:
>
>
> I know that this is not what you are looking for. But since it works great
> on my machine, as an alternative, do you want me to test your libraries to
> see how it goes. Do you have a test suite you want me to launch?
> Good day,
> Louis M
> On 2022-11-15 07:28, r...@amalasoft.com
> ( http://e.mail.ru/compose/?mailto=mailto%3aeiffel%2du...@googlegroups.com)
>
>
>>>> <r...@amalasoft.com
> ( http://e.mail.ru/compose/?mailto=mailto%3a...@amalasoft.com) > schrieb am
14.11.2022 um 16:25 in Nachricht
>
<20221114082549.cf48dd763fcaf5d4...@email25.godad

> dy.
> ( http://e.mail.ru/compose/?mailto=mailto%3aeiffel%2du...@googlegroups.com)

>>
>> Hello R,
>> I just try to install the Eiffel 22.05 package on Ubuntu 22.04 and
>> everything work like a charm (at least, for a basic hello world and a
basic
>> Vision 2 applications). As I remember it, the ecf files of EiffelStudio
>> always used backslashes, but the Eiffel compiler seems to be able to adapt

> it
>> depending on the system. Here is what I did so that you can see what the
>> problem is:
>> # sudo apt install libgtk2.0-dev libxtst-dev libgtk-3-dev
>> # sudo tar xvfj Eiffel_22.05_rev_106302-linux-x86-64.tar.bz2 -C
/usr/local/
>> # export ISE_EIFFEL=/usr/local/Eiffel_22.05
>> # export ISE_PLATFORM=linux-x86-64
>> # export PATH=$PATH:$ISE_EIFFEL/studio/spec/$ISE_PLATFORM/bin
>> # estudio
>> You may have to erase (or rename) the ".es" directory in the home
directory
>> to make it work.
>>
>> I hope this helps.
>> Good day,
>> Louis M
>>
>> On 2022-11-12 17:14, r...@amalasoft.com
> (
http://e.mail.ru/compose/?mailto=mailto%3aeiffel%2dusers%2bunsu...@googlegroups.com)
.
>> To view this discussion on the web visit
>>
>
https://groups.google.com/d/msgid/eiffel-users/20221112151414.cf48dd763fcaf5d

>> 42559c6c92f6fc53b.726ecbd1f1.wbe%40email25.godaddy.com.
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Eiffel Users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to eiffel-users...@googlegroups.com
> (
http://e.mail.ru/compose/?mailto=mailto%3aeiffel%2dusers%2bunsu...@googlegroups.com)
.
>> To view this discussion on the web visit
>>
>
https://groups.google.com/d/msgid/eiffel-users/ff5d8782-58b8-c7cc-2d97-5804b8

>> 74d558%40tioui.com.
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Eiffel Users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to eiffel-users...@googlegroups.com
> (
http://e.mail.ru/compose/?mailto=mailto%3aeiffel%2dusers%2bunsu...@googlegroups.com)
.
>> To view this discussion on the web visit
>>
>
https://groups.google.com/d/msgid/eiffel-users/20221114082549.cf48dd763fcaf5d

>> 42559c6c92f6fc53b.fd2df9262a.wbe%40email25.godaddy.com.
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "Eiffel Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to eiffel-users...@googlegroups.com
> (
http://e.mail.ru/compose/?mailto=mailto%3aeiffel%2dusers%2bunsu...@googlegroups.com)
.
> To view this discussion on the web visit
>
https://groups.google.com/d/msgid/eiffel-users/63733B7F020000A10004FB0B%40gws

> mtp.uni-regensburg.de.
> --
> You received this message because you are subscribed to the Google Groups
> "Eiffel Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to eiffel-users...@googlegroups.com
> (
http://e.mail.ru/compose/?mailto=mailto%3aeiffel%2dusers%2bunsu...@googlegroups.com)
.
> To view this discussion on the web visit
>
https://groups.google.com/d/msgid/eiffel-users/20221115052808.cf48dd763fcaf5d

> 42559c6c92f6fc53b.5847a22ffc.wbe%40email25.godaddy.com.
> --
> You received this message because you are subscribed to the Google Groups
> "Eiffel Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to eiffel-users...@googlegroups.com
> (
http://e.mail.ru/compose/?mailto=mailto%3aeiffel%2dusers%2bunsu...@googlegroups.com)
.
> To view this discussion on the web visit
>
https://groups.google.com/d/msgid/eiffel-users/9fd65791-cd37-305b-45fc-aaa72c

> 7facb5%40tioui.com.
>
> --
> Jocelyn
> ------------------------------------------------------------------------
> Eiffel Software
> https://www.eiffel.com
> ( http://www.eiffel.com)
> Customer support: https://support.eiffel.com
> ( http://support.eiffel.com)
> User group: https://groups.google.com/forum/#!forum/eiffel-users
> ------------------------------------------------------------------------
>
> --
> You received this message because you are subscribed to the Google Groups
> "Eiffel Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to eiffel-users...@googlegroups.com
> (
http://e.mail.ru/compose/?mailto=mailto%3aeiffel%2dusers%2bunsu...@googlegroups.com)
.
> To view this discussion on the web visit
>
https://groups.google.com/d/msgid/eiffel-users/CAFq%2Bd47d1D_LZX9%3Dw8jEPOGtU

> AVZDNWQk7UivzT%2BjfSVqiMXiw%40mail.gmail.com.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Eiffel Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to eiffel-users...@googlegroups.com
> (
http://e.mail.ru/compose/?mailto=mailto%3aeiffel%2dusers%2bunsu...@googlegroups.com)
.
> To view this discussion on the web visit
>
https://groups.google.com/d/msgid/eiffel-users/20221116131756.cf48dd763fcaf5d

> 42559c6c92f6fc53b.16887dd34a.wbe%40email25.godaddy.com.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Eiffel Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to eiffel-users...@googlegroups.com.
> To view this discussion on the web visit
>
https://groups.google.com/d/msgid/eiffel-users/1669026036.787545215%40f330.i.
> mail.ru.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Eiffel Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to eiffel-users...@googlegroups.com.
> To view this discussion on the web visit
>
https://groups.google.com/d/msgid/eiffel-users/20221121060447.cf48dd763fcaf5d

> 42559c6c92f6fc53b.2ba1482ad6.wbe%40email25.godaddy.com.


Finnian Reilly

unread,
Dec 2, 2022, 4:54:51 AM12/2/22
to eiffel...@googlegroups.com, r...@amalasoft.com
Hi Roger,
I will be announcing a plan to migrate Eiffel-Loop to work with the latest compiler and libraries before the end of the year.

This will bring to the community what is possibly the best solution to this problem namely class ZSTRING which mostly uses area: SPECIAL [CHARACTER_8] but when necessary additionally employes SPECIAL [CHARACTER_32], but only for the characters that didn't fit into the 8-bit array. I did some more work on it recently so it now conforms to READABLE_STRING_32. Also class ZSTRING has a very rich set of additional routines to do use things like Python style TUPLE substitution, etc. For many operations the performance is close to STRING_8 because internally it uses STRING_8 routines.

File and Directory paths
Also in regards to file and directory paths. The Eiffel-Loop classes FILE_PATH and DIR_PATH are more memory efficient then the ISE PATH class by an order of magnitude.
Firstly because they use class ZSTRING to store the path data and
Secondly because the path is always split internally into two components,  base * and parent and the latter is always a shared string cached in a global hash set. Therefore in a scenario where you have a large list of strings with common parents, this amounts to a massive memory saving. This has additional benefits because in many computations you are only interested in the base name or the parent separately and not joined in one string. Also certain operations become extremely fast, for example checking if two file paths are in the same directory becomes a comparison by reference a = b.

There is also a related class EL_PATH_STEPS for situations where you need to slice, dice and compare paths at the step level. Effectively each step is represented by a unique 32-bit token.

Finnian Reilly

unread,
Dec 2, 2022, 5:24:00 AM12/2/22
to eiffel...@googlegroups.com
On 22/11/2022 06:59, Ulrich Windl wrote:
Also when starting with an encoding like UTF-8 it should satisfy most needs.
UTF-8 is fine for storing text in files but will not cut it for an internal STRING representation. The problem is it is no longer possible to use array indexing to locate a particular character in the string, because a single utf-8 character can be anywhere from 1 to 4 bytes, so you have to check the size of each character preceding the character you wish to access. There was a class in GOBO that attempted to do this but it was extremely slow because of this problem. That is why ZSTRING only uses Latin-x or Windows-x codecs, and Unicode for supplementary characters.
-- 
SmartDevelopersUseUnderScoresInTheirIdentifiersBecause_it_is_much_easier_to_read
Reply all
Reply to author
Forward
0 new messages