/test/language/expanded/test_expanded17.e

http://github.com/tybor/Liberty · Specman e · 90 lines · 61 code · 8 blank · 21 comment · 4 complexity · 7262613d6725a1bada3fc8999e39ebaf MD5 · raw file

  1. -- This file is part of SmartEiffel The GNU Eiffel Compiler Tools and Libraries.
  2. -- See the Copyright notice at the end of this file.
  3. --
  4. class TEST_EXPANDED17
  5. create {ANY}
  6. make
  7. feature {ANY}
  8. a2: AUX_EXPANDED16A
  9. make
  10. local
  11. a1: AUX_EXPANDED16A; elt: AUX_EXPANDED16B; i: INTEGER
  12. do
  13. create a1.make(3)
  14. elt.set_all_with(1.5)
  15. from
  16. i := a1.upper
  17. until
  18. i < a1.lower
  19. loop
  20. if elt = a1.item(0) then
  21. error
  22. end
  23. i := i - 1
  24. end
  25. a1.set_all_with(elt)
  26. from
  27. i := a1.upper
  28. until
  29. i < a1.lower
  30. loop
  31. if elt /= a1.item(0) then
  32. error
  33. end
  34. i := i - 1
  35. end
  36. create a2.make(3)
  37. elt.set_all_with(1.5)
  38. from
  39. i := a2.upper
  40. until
  41. i < a2.lower
  42. loop
  43. if elt = a2.item(0) then
  44. error
  45. end
  46. i := i - 1
  47. end
  48. a2.set_all_with(elt)
  49. from
  50. i := a2.upper
  51. until
  52. i < a2.lower
  53. loop
  54. if elt /= a2.item(0) then
  55. error
  56. end
  57. i := i - 1
  58. end
  59. end
  60. error
  61. do
  62. std_output.put_string("TEST_EXPANDED17: ERROR%N")
  63. end
  64. end -- class TEST_EXPANDED17
  65. --
  66. -- ------------------------------------------------------------------------------------------------------------------------------
  67. -- Copyright notice below. Please read.
  68. --
  69. -- SmartEiffel is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License,
  70. -- as published by the Free Software Foundation; either version 2, or (at your option) any later version.
  71. -- SmartEiffel is distributed in the hope that it will be useful but WITHOUT ANY WARRANTY; without even the implied warranty
  72. -- of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have
  73. -- received a copy of the GNU General Public License along with SmartEiffel; see the file COPYING. If not, write to the Free
  74. -- Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
  75. --
  76. -- Copyright(C) 1994-2002: INRIA - LORIA (INRIA Lorraine) - ESIAL U.H.P. - University of Nancy 1 - FRANCE
  77. -- Copyright(C) 2003-2006: INRIA - LORIA (INRIA Lorraine) - I.U.T. Charlemagne - University of Nancy 2 - FRANCE
  78. --
  79. -- Authors: Dominique COLNET, Philippe RIBET, Cyril ADRIAN, Vincent CROIZIER, Frederic MERIZEN
  80. --
  81. -- http://SmartEiffel.loria.fr - SmartEiffel@loria.fr
  82. -- ------------------------------------------------------------------------------------------------------------------------------