Files
llvm/flang/test/Fir/constant.fir
jeanPerier 1753de2d95 [flang][FIR] remove fir.complex type and its fir.real element type (#111025)
Final patch of
https://discourse.llvm.org/t/rfc-flang-replace-usages-of-fir-complex-by-mlir-complex-type/82292

Since fir.real was only still used as fir.complex element type, this
patch removes it at the same time.
2024-10-04 09:57:03 +02:00

17 lines
424 B
Plaintext

// RUN: fir-opt %s | tco | FileCheck %s
// CHECK-LABEL: define [3 x i8] @x
func.func @x() -> !fir.char<1,3> {
%1 = fir.string_lit "xyz"(3) : !fir.char<1,3>
// CHECK: ret [3 x i8] c"xyz"
return %1 : !fir.char<1,3>
}
// CHECK-LABEL: define i16 @z()
func.func @z() -> !fir.logical<2> {
%1 = arith.constant true
%0 = fir.convert %1 : (i1) -> !fir.logical<2>
// CHECK-LABEL: ret i16 1
return %0 : !fir.logical<2>
}