LLVMTypeFloat.st
author Jan Vrany <jan.vrany@fit.cvut.cz>
Thu, 17 Sep 2015 17:17:56 +0100
changeset 42 23ae490859cd
parent 33 feabf14b6c1d
child 53 bbf3a88e2358
permissions -rw-r--r--
Fixed LLVMExamples>>example7_factorial_with_debug_info Pass DIFile instead of DICompileUnit to #createTypeFunctionIn:parameterTypes: Fixed #createParameterVariable: - parameters are numbered starting with 1.

"
    Copyright (C) 2015-now Jan Vrany

    This code is not an open-source (yet). You may use this code
    for your own experiments and projects, given that:

    * all modification to the code will be sent to the
      original author for inclusion in future releases
    * this is not used in any commercial software

    This license is provisional and may (will) change in
    a future.
"
"{ Package: 'jv:llvm_s' }"

"{ NameSpace: Smalltalk }"

LLVMTypeScalar subclass:#LLVMTypeFloat
	instanceVariableNames:''
	classVariableNames:''
	poolDictionaries:''
	category:'LLVM-S-Core-Types'
!

!LLVMTypeFloat class methodsFor:'documentation'!

copyright
"
    Copyright (C) 2015-now Jan Vrany

    This code is not an open-source (yet). You may use this code
    for your own experiments and projects, given that:

    * all modification to the code will be sent to the
      original author for inclusion in future releases
    * this is not used in any commercial software

    This license is provisional and may (will) change in
    a future.
"
! !

!LLVMTypeFloat methodsFor:'accessing'!

sizeInBits
    "For integer, pointer, FP  types, return the size in bits. For all 
     other types, throw an LLVMTypeError.

     LLVMType int32 sizeInBits -> 32
     LLVMType int1 sizeInBits  -> 1
    "
    ^ 32

    "Created: / 13-08-2015 / 17:02:36 / Jan Vrany <jan.vrany@fit.cvut.cz>"
! !

!LLVMTypeFloat methodsFor:'testing'!

isFloatType
    ^ true

    "Created: / 13-08-2015 / 16:51:28 / Jan Vrany <jan.vrany@fit.cvut.cz>"
! !