aboutsummaryrefslogtreecommitdiff
path: root/clang/test/CXX/module/basic/basic.link/p3.cppm
blob: 945cfea1cffa07968872aec69bebd5a94a574e67 (plain)
1
2
3
4
5
6
7
8
9
10
11
// RUN: %clang_cc1 -std=c++20 -triple x86_64-linux %s -emit-module-interface -o %t
// RUN: %clang_cc1 -std=c++20 -triple x86_64-linux -x pcm %t -emit-llvm -o - | FileCheck %s

export module M;

// CHECK: @_ZW1M1a ={{.*}} constant i32 1
const int a = 1;
// CHECK: @_ZW1M1b ={{.*}} constant i32 2
export const int b = 2;

export int f() { return a + b; }