home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 5 / Apprentice-Release5.iso / Environments / SmallEiffel 0.3.3 / SmallEiffel 68k / lib_test / test_inspect3.e < prev    next >
Encoding:
Text File  |  1996-06-13  |  531 b   |  31 lines  |  [TEXT/EDIT]

  1. -- Part of SmallEiffel -- Read DISCLAIMER file -- Copyright (C) 
  2. -- Dominique COLNET and Suzanne COLLIN -- colnet@loria.fr
  3. --
  4. class TEST_INSPECT3
  5.  
  6. creation make
  7.  
  8. feature 
  9.    
  10.    make is
  11.       do
  12.      attribute := '1';
  13.          inspect
  14.         foo
  15.          when '2' then io.put_string("Impossible%N")
  16.          when '3' then io.put_string("Impossible aussi%N")
  17.      else
  18.          end   
  19.       end; 
  20.  
  21. feature {NONE}
  22.  
  23.    attribute: CHARACTER;
  24.  
  25.    foo: like attribute is
  26.       do
  27.      Result := attribute;
  28.       end;
  29.    
  30. end -- class TEST_INSPECT3
  31.