mirror of
https://github.com/EiffelSoftware/eiffel-org.git
synced 2025-12-08 07:42:33 +01:00
Author:admin
Date:2008-09-19T07:54:43.000000Z git-svn-id: https://svn.eiffel.com/eiffel-org/trunk@25 abb3cda0-5349-4a8f-a601-0c33ac3a8c38
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
[[Property:title|eiffel_scan console input]]
|
||||
[[Property:weight|2]]
|
||||
[[Property:uuid|ce4da828-6772-e1c3-0917-82f6669cccf9]]
|
||||
<code>
|
||||
-- Example of a lexical analyzer based on the Eiffel syntax.
|
||||
-- The analyzer itself is found in the file ``eiffel_lex'', which
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
[[Property:title|eiffel_scan console output]]
|
||||
[[Property:weight|3]]
|
||||
[[Property:uuid|a233d1b0-b964-ba44-7b24-7204d9fa6932]]
|
||||
<code>
|
||||
Scanning file `eiffel_scan.e'.
|
||||
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
[[Property:title|EIFFEL_SCAN Text]]
|
||||
[[Property:weight|1]]
|
||||
[[Property:uuid|092bd183-2fc4-ae65-02b9-d66933492a50]]
|
||||
<code>
|
||||
|
||||
class
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
[[Property:title|EiffelLex Samples]]
|
||||
[[Property:weight|0]]
|
||||
[[Property:uuid|2e4911de-4838-00fc-1742-a8ebd1ae05ff]]
|
||||
<code>
|
||||
|
||||
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
[[Property:title|Eiffel scanner]]
|
||||
[[Property:weight|0]]
|
||||
[[Property:uuid|c0d6ad9d-2bac-c5ad-69b6-873db2e47aa9]]
|
||||
In the directory '''$ISE_EIFFEL/examples/lex''' you will find a system that scans Eiffel classes. It consists of the class [[EIFFEL_SCAN Text|EIFFEL_SCAN]] . It uses the file [[EiffelLex Samples|eiffel_regular]] as lexical grammar to analyze an Eiffel class passed on the command line.
|
||||
|
||||
When compiling the example, the executable '''eiffel_scan(.exe)''' is created. Use the program as follows:
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
[[Property:title|Lex Sample]]
|
||||
[[Property:link_title|EiffelLex Sample]]
|
||||
[[Property:weight|2]]
|
||||
[[Property:uuid|79ad35f3-75a9-429c-ad47-f304fec23306]]
|
||||
* [[Eiffel scanner|Eiffel scanner]]
|
||||
|
||||
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
[[Property:title|Lexical analysis: the Lex library]]
|
||||
[[Property:link_title|EiffelLex Tutorial]]
|
||||
[[Property:weight|0]]
|
||||
[[Property:uuid|9ea43bef-1483-fbf2-4791-2be6a31d394d]]
|
||||
==OVERVIEW==
|
||||
|
||||
When analyzing a text by computer, it is usually necessary to split it into individual components or '''tokens'''. In human languages, the tokens are the words; in programming languages, tokens are the basic constituents of software texts, such as identifiers, constants and special symbols.
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
[[Property:title|EiffelLex Library]]
|
||||
[[Property:link_title|EiffelLex]]
|
||||
[[Property:weight|1]]
|
||||
[[Property:uuid|52e88d58-1a02-d4e2-5503-e405253e7656]]
|
||||
Type: Library <br/>
|
||||
Platform: Any <br/>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user