author | Jan Vrany <jan.vrany@fit.cvut.cz> |
Wed, 06 Jul 2016 22:40:59 +0100 | |
changeset 71 | ab03b0a6d037 |
parent 53 | bbf3a88e2358 |
permissions | -rw-r--r-- |
27
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
1 |
" |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
2 |
Copyright (C) 2015-now Jan Vrany |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
3 |
|
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
4 |
This code is not an open-source (yet). You may use this code |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
5 |
for your own experiments and projects, given that: |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
6 |
|
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
7 |
* all modification to the code will be sent to the |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
8 |
original author for inclusion in future releases |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
9 |
* this is not used in any commercial software |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
10 |
|
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
11 |
This license is provisional and may (will) change in |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
12 |
a future. |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
13 |
" |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
14 |
"{ Package: 'jv:llvm_s' }" |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
15 |
|
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
16 |
"{ NameSpace: Smalltalk }" |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
17 |
|
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
18 |
LLVMType subclass:#LLVMTypeVoid |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
19 |
instanceVariableNames:'' |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
20 |
classVariableNames:'' |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
21 |
poolDictionaries:'' |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
22 |
category:'LLVM-S-Core-Types' |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
23 |
! |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
24 |
|
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
25 |
!LLVMTypeVoid class methodsFor:'documentation'! |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
26 |
|
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
27 |
copyright |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
28 |
" |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
29 |
Copyright (C) 2015-now Jan Vrany |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
30 |
|
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
31 |
This code is not an open-source (yet). You may use this code |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
32 |
for your own experiments and projects, given that: |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
33 |
|
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
34 |
* all modification to the code will be sent to the |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
35 |
original author for inclusion in future releases |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
36 |
* this is not used in any commercial software |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
37 |
|
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
38 |
This license is provisional and may (will) change in |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
39 |
a future. |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
40 |
" |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
41 |
! ! |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
42 |
|
50
dbda820d4d24
Support for creating recursive structures.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
27
diff
changeset
|
43 |
!LLVMTypeVoid methodsFor:'converting'! |
dbda820d4d24
Support for creating recursive structures.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
27
diff
changeset
|
44 |
|
dbda820d4d24
Support for creating recursive structures.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
27
diff
changeset
|
45 |
array: numberOfElements |
dbda820d4d24
Support for creating recursive structures.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
27
diff
changeset
|
46 |
"Create a fixed-size array whose elements are of type of receiver |
dbda820d4d24
Support for creating recursive structures.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
27
diff
changeset
|
47 |
`LLVMType int8 array: 13` returns `[ 13 x i8 ]`" |
dbda820d4d24
Support for creating recursive structures.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
27
diff
changeset
|
48 |
|
dbda820d4d24
Support for creating recursive structures.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
27
diff
changeset
|
49 |
self shouldNotImplement |
dbda820d4d24
Support for creating recursive structures.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
27
diff
changeset
|
50 |
|
dbda820d4d24
Support for creating recursive structures.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
27
diff
changeset
|
51 |
"Created: / 12-10-2015 / 18:28:05 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
dbda820d4d24
Support for creating recursive structures.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
27
diff
changeset
|
52 |
! |
dbda820d4d24
Support for creating recursive structures.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
27
diff
changeset
|
53 |
|
dbda820d4d24
Support for creating recursive structures.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
27
diff
changeset
|
54 |
pointer |
dbda820d4d24
Support for creating recursive structures.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
27
diff
changeset
|
55 |
"Return a pointer to the type represented by the receiver. |
dbda820d4d24
Support for creating recursive structures.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
27
diff
changeset
|
56 |
`LLVMType int32 pointer` returns int32_t*" |
dbda820d4d24
Support for creating recursive structures.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
27
diff
changeset
|
57 |
|
dbda820d4d24
Support for creating recursive structures.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
27
diff
changeset
|
58 |
self shouldNotImplement |
dbda820d4d24
Support for creating recursive structures.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
27
diff
changeset
|
59 |
|
dbda820d4d24
Support for creating recursive structures.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
27
diff
changeset
|
60 |
"Created: / 12-10-2015 / 18:27:44 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
dbda820d4d24
Support for creating recursive structures.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
27
diff
changeset
|
61 |
! ! |
dbda820d4d24
Support for creating recursive structures.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
27
diff
changeset
|
62 |
|
27
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
63 |
!LLVMTypeVoid methodsFor:'testing'! |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
64 |
|
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
65 |
isVoidType |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
66 |
^true |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
67 |
|
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
68 |
"Created: / 13-08-2015 / 16:52:36 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
69 |
! ! |
b26354bbff25
LLVM type system refactored to use a subclass per kind.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff
changeset
|
70 |