Skip to content

Commit

Permalink
Revert adding builtin void type
Browse files Browse the repository at this point in the history
  • Loading branch information
lucteo committed Dec 6, 2024
1 parent c4a410c commit f20f872
Show file tree
Hide file tree
Showing 6 changed files with 0 additions and 17 deletions.
2 changes: 0 additions & 2 deletions Sources/CodeGen/LLVM/ConcreteTypeLayout.swift
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,6 @@ struct ConcreteTypeLayout {
self.init(size: 8, alignment: 8)
case .float128:
self.init(size: 16, alignment: 8)
case .void:
notLLVMRepresentable(^t) // Cannot be used in a type layout.
case .module:
notLLVMRepresentable(^t)
}
Expand Down
2 changes: 0 additions & 2 deletions Sources/CodeGen/LLVM/TypeLowering.swift
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,6 @@ extension IR.Program {
return SwiftyLLVM.FloatingPointType.fp128(in: &module)
case .ptr:
return module.ptr
case .void:
return SwiftyLLVM.VoidType(in: &module)
case .module:
notLLVMRepresentable(t)
}
Expand Down
7 changes: 0 additions & 7 deletions Sources/FrontEnd/Types/BuiltinType.swift
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,6 @@ public enum BuiltinType: TypeProtocol {
/// A built-in opaque pointer.
case ptr

/// A built-in void type.
case void

/// The type of the built-in module.
case module

Expand Down Expand Up @@ -66,8 +63,6 @@ extension BuiltinType: CustomStringConvertible {
return "float128"
case .ptr:
return "ptr"
case .void:
return "void"
case .module:
return "Builtin"
}
Expand All @@ -91,8 +86,6 @@ extension BuiltinType: LosslessStringConvertible {
self = .float128
case "ptr":
self = .ptr
case "void":
self = .void
case "Builtin":
self = .module

Expand Down
2 changes: 0 additions & 2 deletions Sources/IR/Mangling/Demangler.swift
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,6 @@ struct Demangler {
demangled = takeBuiltinFloatType(from: &stream)
case .builtinPointerType:
demangled = .type(.builtin(.ptr))
case .builtinVoidType:
demangled = .type(.builtin(.void))
case .builtinModuleType:
demangled = .type(.builtin(.module))
case .builtinWordType:
Expand Down
2 changes: 0 additions & 2 deletions Sources/IR/Mangling/Mangler.swift
Original file line number Diff line number Diff line change
Expand Up @@ -560,8 +560,6 @@ struct Mangler {
append(integer: 128, to: &output)
case .ptr:
append(operator: .builtinPointerType, to: &output)
case .void:
append(operator: .builtinVoidType, to: &output)
case .module:
append(operator: .builtinModuleType, to: &output)
}
Expand Down
2 changes: 0 additions & 2 deletions Sources/IR/Mangling/ManglingOperator.swift
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,6 @@ public enum ManglingOperator: String {

case builtinPointerType = "bpT"

case builtinVoidType = "bvT"

case builtinModuleType = "bmT"

case builtinWordType = "bwT"
Expand Down

0 comments on commit f20f872

Please sign in to comment.