PageRenderTime 16ms CodeModel.GetById 12ms app.highlight 1ms RepoModel.GetById 1ms app.codeStats 0ms

/src/wrappers/llvm/library/types/llvm_vector_type.e

http://github.com/tybor/Liberty
Specman e | 38 lines | 17 code | 3 blank | 18 comment | 0 complexity | 9635c9473ee1e028898d5ea8bb57a390 MD5 | raw file
 1class LLVM_VECTOR_TYPE
 2-- A type representing a vector
 3inherit LLVM_SEQUENCE_TYPE
 4create {ANY} make
 5create {WRAPPER, WRAPPER_HANDLER} from_external_pointer
 6
 7feature {ANY} -- Creation
 8   make (a_type: LLVM_TYPE; a_count: NATURAL_32)
 9         -- Creates a vector type with `a_count' elements of `a_type'.
10      require a_type/=Void
11      do
12         handle:=llvmvector_type(a_type.handle,a_count)
13      end
14feature {ANY}
15   size: NATURAL_32
16         -- Size of current vector
17      do
18         Result:=llvmget_vector_size(handle)
19      end
20invariant type_kind.is_vector_type_kind
21end -- class LLVM_VECTOR_TYPE
22
23-- Copyright (C) 2009-2017: Paolo Redaelli
24
25-- This file is part of LLVM wrappers for Liberty Eiffel.
26--
27-- This library is free software: you can redistribute it and/or modify
28-- it under the terms of the GNU Lesser General Public License as published by
29-- the Free Software Foundation, version 3 of the License.
30--
31-- Liberty Eiffel is distributed in the hope that it will be useful,
32-- but WITHOUT ANY WARRANTY; without even the implied warranty of
33-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
34-- GNU General Public License for more details.
35--
36-- You should have received a copy of the GNU General Public License
37-- along with Liberty Eiffel.  If not, see <http://www.gnu.org/licenses/>.
38--