PageRenderTime 9ms CodeModel.GetById 2ms app.highlight 3ms RepoModel.GetById 1ms app.codeStats 0ms

/src/tools/interpreter/builtins/liberty_interpreter_external_type_integer_64_builtins.e

http://github.com/tybor/Liberty
Specman e | 43 lines | 23 code | 6 blank | 14 comment | 0 complexity | a3eee380b9eed59d51b4a85c8d42f541 MD5 | raw file
 1-- This file is part of Liberty Eiffel.
 2--
 3-- Liberty Eiffel is free software: you can redistribute it and/or modify
 4-- it under the terms of the GNU General Public License as published by
 5-- the Free Software Foundation, version 3 of the License.
 6--
 7-- Liberty Eiffel is distributed in the hope that it will be useful,
 8-- but WITHOUT ANY WARRANTY; without even the implied warranty of
 9-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
10-- GNU General Public License for more details.
11--
12-- You should have received a copy of the GNU General Public License
13-- along with Liberty Eiffel.  If not, see <http://www.gnu.org/licenses/>.
14--
15class LIBERTY_INTERPRETER_EXTERNAL_TYPE_INTEGER_64_BUILTINS
16
17inherit
18   LIBERTY_INTERPRETER_EXTERNAL_TYPE_INTEGERS_BUILTINS[INTEGER_64]
19
20creation {LIBERTY_INTERPRETER_EXTERNAL_BUILTIN_CALL}
21   make
22
23feature {}
24   new_integer (value: INTEGER_64): LIBERTY_INTERPRETER_OBJECT_NATIVE[INTEGER_64] is
25      do
26         Result := interpreter.new_integer_64(value, builtin_call.position)
27      end
28
29   left, target: INTEGER_64 is
30      do
31         Result := int64_target
32      end
33
34   right: INTEGER_64 is
35      local
36         obj: LIBERTY_INTERPRETER_OBJECT_NATIVE[INTEGER_64]
37      do
38         builtin_call.evaluate_parameters
39         obj ::= builtin_call.parameters.first
40         Result := obj.item
41      end
42
43end -- class LIBERTY_INTERPRETER_EXTERNAL_TYPE_INTEGER_64_BUILTINS