From 417c7772e4ea91210bf3fa1ee218fe7f4325a21d Mon Sep 17 00:00:00 2001 From: Sasha Koshka Date: Sat, 27 Jan 2024 01:48:29 +0000 Subject: [PATCH] Move addrspace to attribute file, will put more things in there --- llvm/attribute.go | 9 +++++++++ llvm/type.go | 6 ------ 2 files changed, 9 insertions(+), 6 deletions(-) create mode 100644 llvm/attribute.go diff --git a/llvm/attribute.go b/llvm/attribute.go new file mode 100644 index 0000000..ff1dfa1 --- /dev/null +++ b/llvm/attribute.go @@ -0,0 +1,9 @@ +package llvm + +import "fmt" + +type AddressSpace uint64 + +func (space AddressSpace) String () string { + return fmt.Sprintf("addrspace(%d)", space) +} diff --git a/llvm/type.go b/llvm/type.go index de81b6e..6bba3f3 100644 --- a/llvm/type.go +++ b/llvm/type.go @@ -174,12 +174,6 @@ func (this *TypeMetadata) String () string { return this.LLString() } -type AddressSpace uint64 - -func (space AddressSpace) String () string { - return fmt.Sprintf("addrspace(%d)", space) -} - type TypePointer struct { AbstractType AddressSpace AddressSpace