Newbie question here about "!!"

26 views
Skip to first unread message

Hank Lenzi

unread,
Jun 22, 2019, 5:22:32 PM6/22/19
to Eiffel Users
Hi all -

Pardon the totally non-deep question.
I am just learning Eiffel, so I got me a few books.
They all use "!!", as in Rist's book, like so:

class X
creation
make
test: REAL
format: FORMAT_DOUBLE
make is
-- show how real formatting is done
do
!!format.make (8, 2) -- create formatting object
test := 43.789
io.new_line -- start in column 1 of screen
io.putstring (“Value:%T”) -- label and tab
io.putstring (format.formatted (test)) -- display in width eight
end -- make
end -- class X

I can't seem to find that in Eiffel.com documentation. Is this deprecated?

Thanks,
Hank

Gary Smithrud

unread,
Jun 22, 2019, 5:53:12 PM6/22/19
to eiffel...@googlegroups.com
Yes, it is.  Sadly, no one has come out with an updated book (which would be great because of Void safety, etc).  You now use "create format.make (8, 2)" instead.

--
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.
Visit this group at https://groups.google.com/group/eiffel-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/eiffel-users/48aef703-dce1-4724-9b8b-ec946cb4ec44%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Hank Lenzi

unread,
Jun 22, 2019, 7:10:29 PM6/22/19
to Eiffel Users
Em sábado, 22 de junho de 2019 18:53:12 UTC-3, GMS escreveu:
> Yes, it is.  Sadly, no one has come out with an updated book (which would be great because of Void safety, etc).  You now use "create format.make (8, 2)" instead.
>

I guess if authors just put a webpage, updating details (e.g., ace files, etc.) it would greatly help.
Thanks.
-- Hank

Gary Smithrud

unread,
Jun 22, 2019, 7:56:33 PM6/22/19
to eiffel...@googlegroups.com
There is help out there.  Take a look at www.eiffel.org.  Search for reserved words will provide a quick list that you can use to map from the old usage to the new.  In addition there are examples, etc, and there might be a page that provides the changes from the old version (I remember seeing something a long time ago).  My machine is in pieces right now, so I can't provide links (and this is bleeping slow).

--
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.
Visit this group at https://groups.google.com/group/eiffel-users.

Peter Gummer

unread,
Jun 22, 2019, 11:06:28 PM6/22/19
to 'Alexander Kogtenkov' via Eiffel Users
Hi Hank,

The !! creation syntax has been obsolete for about 20 years. Ace files were replaced by ecf files about 15 years ago.

The book you are referring to must be very old, and the list of changes to Eiffel in that time would be very long.

- Peter

Hank Lenzi

unread,
Jun 29, 2019, 1:32:57 PM6/29/19
to Eiffel Users


The book you are referring to must be very old, and the list of changes to Eiffel in that time would be very long.

- Peter

Unfortunately, with the exception of A Touch of Class, all Eiffel books, to my knowledge are old. Even Touch is old, as the Traffic library has changed a lot, the old code is broken and I've had to hunt for a newer version (now it's Zurich, not Paris). I'm going through it methodically and taking notes, with updated information on the code change. I might post them somwehere, when and if I'm done. Also, I think the approach of giving us a huge library to explore is a plus, and much more realistic. 

The book I referred to was Rist & Terwilliger's Object-Oriented Programming in Eiffel, which somebody said it was good, because it builds on a single project througout the book. But then there are these quirks. 

It really is too bad no-one's written a new updated book. With the proliferation of publishers out there nowadays, I feel this is a missed opportunity. It seem to me that Eiffel has a core of dedicated true belivers who are experts and they've got their Eiffel projects to tend to, and they don't need or have time for any "evangelizing". This is understandable, but it does keep Eiffel too much under the radar. I have the luxury of not being a professional software developer, so I can just read what people think of Java and C++, and it seems people develop allergies in the long run, so I can just take my time to learn Eiffel but, boy, it shouldn't be so hard (just because of the outdated info out there, you know?). It's a good exercise, because I'm learning how awesome EiffelStudio is for going through code so, in fact, I take it as an opportunity and a challenge but I can't avoid thinking that some people would appreciate an easier path to learning Eiffel. My perception is that the same thing happened to Common Lisp and Smalltalk, and we are where we are today, with the Rubys and the Javas...

Cheers,
Hank

Larry Rix

unread,
Jun 29, 2019, 3:15:38 PM6/29/19
to Eiffel Users
Hi Hank!

Welcome to the fold!

I struggled with Eiffel for about a year until a particular internal event happened for me. I will pass this along to you (and any other reader) as a bit of advice.

Prior to Eiffel, I was an 18 year Visual FoxPro developer. It turns out that FoxPro is a completely horrid language for more reasons than I can count.

In the beginning, I was trying to frame Eiffel that I was learning in FoxPro terms. I kept looking for an Eiffel equivocation sans "here-is-how-we-do-it-in-fox". It turns out that this hobbled me badly. So badly, that I almost gave up trying to learn it.

Then it came to me—STOP! Quit trying to understand Eiffel through a _______ (FoxPro) lens! Throw away everything you've come to believe and all your muscle memory about "why-we-do-it-this-way", because that "way" requires a wiring of the head and mind that Eiffel will not fit into. This is most certainly a square peg attempt at forcing into a round hole.

I had NO WHERE to really turn on my own. So—here is what I did.

I realized that my struggle was largely with the Eiffel Compiler. BUT—it is precisely the Eiffel Compiler that takes my code text and translates it to C/C++ and then on to binary.

So—the epiphany—Larry, learn how to think like the Eiffel Compiler! How does the compiler see this? What are its rules? How does it interpret what I am writing?

What is lovely about Eiffel is that it has a very clean, clear, good, precise, and wonderful SPECIFICATION document (i.e. ECMA-367).

I decided right then and there that I would study that specification in grave detail. I would sit on it, sit with it, sit beside it, and read and re-read until it made sense. It took me about a week of that when things started to click. It was like the lights came on and it started making sense.

It wasn't just the specification, it was how it was written, worded, and its grammar and structure.

The final result is that I got about 80% of it and my brain got rewired in the process.

The Eiffel ECMA-367 is still one of the finest tools for learning Eiffel if you're serious about it. They key is to tell yourself that you're going to turn your brain into an Eiffel Compiler. You're going to teach your mind how to think like the Compiler. If you'll do that, I have found that about 95% of what I come upon in Eiffel is resolved in my own head. I still turn to the specification from time to time when I get something really squirrely. I can then also come here to ask more detailed question and the very bright and fine minds of this community give outstanding and quick answers!

So—that's my story and I;m stickin' to it! Learn to think like the Eiffel Compiler. Use the ECMA spec as your detailed and very precise guide, which will show you how it things, its rules, and its design.


Kindest regards,

Larry Rix 
 

Hank Lenzi

unread,
Jul 7, 2019, 12:11:33 AM7/7/19
to Eiffel Users


Em sábado, 29 de junho de 2019 16:15:38 UTC-3, Larry Rix escreveu:
Hi Hank!

Welcome to the fold!

(...)

The Eiffel ECMA-367 is still one of the finest tools for learning Eiffel if you're serious about it
.
(...) 
Kindest regards,

Larry Rix 

Great tips, Larry! 
BTW, I deeply appreciate your YouTube videos!

-- Hank
Reply all
Reply to author
Forward
0 new messages