Author:halw

Date:2010-02-03T20:59:49.000000Z


git-svn-id: https://svn.eiffel.com/eiffel-org/trunk@436 abb3cda0-5349-4a8f-a601-0c33ac3a8c38
This commit is contained in:
halw
2010-02-03 22:33:57 +00:00
parent daa3f56d1d
commit 8a53f20b29
3 changed files with 11 additions and 12 deletions

View File

@@ -14,7 +14,7 @@ This tutorial will guide you through the use of AutoTest. A [[AutoTest|reference
{{Caution|At this time, AutoTest will work only for project targets in the classic Eiffel environment. This means that projects targeted to Microsoft .Net will not be able to use AutoTest.}} {{Caution|At this time, AutoTest will work only for project targets in the classic Eiffel environment. This means that projects targeted to Microsoft .Net will not be able to use AutoTest.}}
{{Recommended|During the transition to void-safe Eiffel, projects can be built using '''experimental''' mode. This mode is as stable as '''non-experimental''' mode, but includes some facilities that might break existing code in a few circumstances. However, since version 6.5, EiffelStudio itself is built in experimental mode, so we recommend that you use AutoTest only on projects also built using experimental mode. Experimental mode can be invoked by using the "-experiment" option from the command line, or on Microsoft Windows by following the '''Start''' menu path to EiffelStudio and selecting experimental mode. }} {{Recommended|During the transition to void-safe Eiffel, projects can be built using '''experimental''' mode. This mode is as stable as '''non-experimental''' mode, but includes some facilities that might break existing code in a few circumstances. However, since version 6.5, EiffelStudio itself is built in experimental mode, so '''we recommend that you use AutoTest only on projects also built using experimental mode'''. Experimental mode can be invoked by using the "-experiment" option from the command line, or on Microsoft Windows by following the '''Start''' menu path to EiffelStudio and selecting experimental mode. }}
{{SeeAlso|<br />[[AutoTest]] reference }} {{SeeAlso|<br />[[AutoTest]] reference }}

View File

@@ -87,15 +87,15 @@ So, this usage of the loop construct has been the traditional mechanism for trav
across my_list as c loop print (c.item) end across my_list as c loop print (c.item) end
</code> </code>
Here the <code>across</code> indicates an iteration process across the structure <code>my_list</code>. The <code>as c</code> indicates that a cursor object referenced by the name <code>c</code>, and available only for the scope of the iteration, will be created to effect the iteration. The element of <code>my_list</code> which is currently referenced by the cursor <code>c</code> is <code>c.item</code> as you see in the call to <code>print (c.item)</code> loop body. The loop body does not contain the call to the structure's <code>forth</code> feature, as our more traditional example did. Neither do you see the call to <code>start</code> nor the check of <code>off</code> in the exit condition. The semantics of the iteration abstract these for you and relieve you of their burden ... and some opportunities for error. Here the <code>across</code> indicates an iteration process across the structure <code>my_list</code>. The <code>as c</code> indicates that a cursor object referenced by the name <code>c</code>, and available only for the scope of the iteration, will be created to effect the iteration. The element of <code>my_list</code> which is currently referenced by the cursor <code>c</code> is <code>c.item</code> as you see in the call to <code>print (c.item)</code> in the loop body. The loop body does not contain the call to the structure's <code>forth</code> feature, as our more traditional example did. Neither do you see the call to <code>start</code> nor the check of <code>off</code> in the exit condition. The semantics of the iteration abstract these for you, relieving you of their burden ... while eliminating some opportunities for error.
Concerning cursors, both ways of using the loop construct to traverse a structure employ a cursor. In the traditional usage, the cursor is internal to the structure object, the instance of <code>LINKED_LIST [STRING]</code> called <code>my_list</code>, in the case of the example. Applying the feature <code>item</code> to <code>my_list</code> retrieves the list element currently referenced by the cursor. In the iteration version of traversal, the variable <code>c</code> holds the iteration cursor, external to the list object. So, you apply <code>c.item</code> to get the current list element. The obvious use is for instructions that should be part of the system but executed only in some circumstances, for example to provide extra debugging information. The advantage to the external cursor is that multiple traversals of the structure can occur simultaneously without interfering with one another. This is possible in the traditional usage, but only by saving and restoring the structure's cursor. Concerning cursors, both ways of using the loop construct to traverse a structure employ a cursor. In the traditional usage, the cursor is internal to the structure object. In the case of the example, that would be the instance of <code>LINKED_LIST [STRING]</code> called <code>my_list</code>. Applying the feature <code>item</code> to <code>my_list</code> retrieves the list element currently referenced by the cursor. In the iteration version of traversal, the variable <code>c</code> holds the iteration cursor, external to the list object. So, you apply <code>c.item</code> to get the current list element. The advantage to the external cursor is that multiple traversals of the structure can occur simultaneously without interfering with one another. This is possible in the traditional usage, but only by saving and restoring the structure's cursor.
At first observation, it may not appear that both traversal examples are using the same language construct. But, indeed they are. In order to see this more clearly, it will help now to examine (almost) the entire anatomy of the loop construct. At first observation, it may not appear that both traversal examples are using the same language construct. But, indeed they are simply two different forms of a single language construct. In order to see this more clearly, it will help now to examine (almost) the entire anatomy of the loop construct.
===Debug=== ===Debug===
An occasionally useful instruction is <code>debug</code> <code>(</code>''Debug_key'', ... <code>)</code> ''instructions'' <code>end</code> where ''instructions'' is a sequence of zero or more instructions and the part in parentheses is optional, containing if present one or more strings, called debug keys. The EiffelStudio compiler lets you specify the corresponding <code>debug</code> compilation option: <code>yes</code>, <code>no</code>, or an explicit debug key. The ''instructions'' will be executed if and only if the corresponding option is on. An occasionally useful instruction is <code>debug</code> <code>(</code>''Debug_key'', ... <code>)</code> ''instructions'' <code>end</code> where ''instructions'' is a sequence of zero or more instructions and the part in parentheses is optional, containing if present one or more strings, called debug keys. The EiffelStudio compiler lets you specify the corresponding <code>debug</code> compilation option: <code>yes</code>, <code>no</code>, or an explicit debug key. The ''instructions'' will be executed if and only if the corresponding option is on. The obvious use is for instructions that should be part of the system but executed only in some circumstances, for example to provide extra debugging information.
===Check=== ===Check===

View File

@@ -2,11 +2,10 @@
[[Property:link_title|]] [[Property:link_title|]]
[[Property:weight|2]] [[Property:weight|2]]
[[Property:uuid|056c0ab0-8e44-571f-f126-0b1850980754]] [[Property:uuid|056c0ab0-8e44-571f-f126-0b1850980754]]
Often, when we speak about Eiffel to prospective users, we hear them repeat misinformation about the method, the language, or the tools. Most of the time, the stories are familiar to us … and untrue. Here are a few of the myths that we hear most often, as recounted and debunked by Eiffel Trainer Hal Webre in his [http://www.eiffel.com/developers/presentations/eiffel_introduction/player.html?slide= introductory online presentation] to the series entitled [http://eiffel.com/developers/presentations/ "Where Eiffel Fits"].
Often, when we speak about Eiffel to prospective users, we hear them repeat misinformation about the method, the language, the method, or the tools. Most of the time, the stories are familiar to us … and untrue. Here are a few of the myths that we hear most often, as recounted and debunked by Eiffel Trainer Hal Webre in his [http://www.eiffel.com/developers/presentations/eiffel_introduction/player.html?slide= introductory online presentation] to the series entitled [http://eiffel.com/developers/presentations/ "Where Eiffel Fits"].
==Eiffel is an "academic" language== ==Eiffel is an "academic" language only: ''Wrong ... twice!!''==
Recently, I was offered the opportunity to speak to a local technology group about Eiffel for Microsoft .Net. The leader of this group is part of a small commercially-oriented software development company. Concerning Eiffel, he said, “All I know about Eiffel is that its an academic language.” Recently, I was offered the opportunity to speak to a local technology group about Eiffel for Microsoft .Net. The leader of this group is part of a small commercially-oriented software development company. Concerning Eiffel, he said, “All I know about Eiffel is that its an academic language.”
@@ -19,7 +18,7 @@ Secondly, Im not sure what “academic language” means exactly, but if it m
But Eiffel is also used successfully in many commercial and government endeavors. If you have any doubts, pay a visit to [http://eiffel.com/general/success-stories.html eiffel.com] and check out the success stories and customers testimonials. But Eiffel is also used successfully in many commercial and government endeavors. If you have any doubts, pay a visit to [http://eiffel.com/general/success-stories.html eiffel.com] and check out the success stories and customers testimonials.
==Eiffel is not for doing "real" work== ==Eiffel is not for doing "real" work: ''Who told you that!?!''==
Occasionally weve heard people say that Eiffel is only suitable for building “toy” systems. Occasionally weve heard people say that Eiffel is only suitable for building “toy” systems.
@@ -32,7 +31,7 @@ We see Eiffel being used instead of other technologies for systems in which scal
One of our customers is an organization that has developed a payroll system using Eiffel that every week pays over two hundred thousand employees in twenty thousand different institutions … the people in this organization would assure you that Eiffel is indeed industrial grade. One of our customers is an organization that has developed a payroll system using Eiffel that every week pays over two hundred thousand employees in twenty thousand different institutions … the people in this organization would assure you that Eiffel is indeed industrial grade.
==Not many people are using Eiffel== ==Not many people are using Eiffel: ''You wouldn't want to share an elevator with them all!''==
The answer to this one depends a bit upon your frame of reference. Some time ago Microsoft estimated that there were twenty million Visual Basic programmers world wide. The answer to this one depends a bit upon your frame of reference. Some time ago Microsoft estimated that there were twenty million Visual Basic programmers world wide.
@@ -45,7 +44,7 @@ Eiffel Software's dual licensing model gives developers the opportunity to learn
So, dont worry about it, plenty of people use Eiffel … and those numbers are increasing constantly. So, dont worry about it, plenty of people use Eiffel … and those numbers are increasing constantly.
==If we use Eiffel, we may not be able to find qualified programmers== ==If we use Eiffel, we may not be able to find qualified programmers: ''Gimme a break.''==
Through the years some potential Eiffel users have expressed to us a concern that if they embrace Eiffel, that they may not be able to find a sufficient number of qualified developers. Through the years some potential Eiffel users have expressed to us a concern that if they embrace Eiffel, that they may not be able to find a sufficient number of qualified developers.
@@ -56,7 +55,7 @@ First, almost all Eiffel people were proficient in some other technology before
Additionally, it is important also to understand that Eiffel developers are easy to create. Because Eiffel is simple, clean, and elegant, it doesnt take long to get people going with it. I teach a five-day course that contains fifteen programming exercises. Each time Ive taught the course, almost every student has finished every exercise. Students leave with a good foundation for how to begin saving time and money for their organization by constructing quality software with Eiffel. These people can be fluent in Eiffel in as little as a couple of months. This can be contrasted with the other extreme ... a well-known Microsoft Windows expert told me a couple of years ago that he estimates it to take 5 to 7 years to become truly fluent in C++/COM programming on Windows. Programmers who are proficient in other technologies often experience Eiffel as a breath of fresh air. Additionally, it is important also to understand that Eiffel developers are easy to create. Because Eiffel is simple, clean, and elegant, it doesnt take long to get people going with it. I teach a five-day course that contains fifteen programming exercises. Each time Ive taught the course, almost every student has finished every exercise. Students leave with a good foundation for how to begin saving time and money for their organization by constructing quality software with Eiffel. These people can be fluent in Eiffel in as little as a couple of months. This can be contrasted with the other extreme ... a well-known Microsoft Windows expert told me a couple of years ago that he estimates it to take 5 to 7 years to become truly fluent in C++/COM programming on Windows. Programmers who are proficient in other technologies often experience Eiffel as a breath of fresh air.
==Eiffel might not be around in five/eight/ten (choose one) years== ==Eiffel might not be around in five/eight/ten (choose one) years: ''Better clean your crystal ball, Nostradamus!''==
I think the first time I heard this one, it was about 1989. I think the first time I heard this one, it was about 1989.