-
Notifications
You must be signed in to change notification settings - Fork 267
Expand file tree
/
Copy pathmixed-default-arguments.cpp
More file actions
40 lines (25 loc) · 991 Bytes
/
mixed-default-arguments.cpp
File metadata and controls
40 lines (25 loc) · 991 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
//=== Cpp2 type declarations ====================================================
#include "cpp2util.h"
#line 1 "mixed-default-arguments.cpp2"
//=== Cpp2 type definitions and function declarations ===========================
#line 1 "mixed-default-arguments.cpp2"
auto cxx(int x, std::string y) -> void {
std::cout << x << " \"" << y << "\"" << "\n";
}
#line 5 "mixed-default-arguments.cpp2"
auto cxx2(cpp2::impl::in<int> x, cpp2::impl::in<std::string> y) -> void;
#line 9 "mixed-default-arguments.cpp2"
auto main() -> int;
//=== Cpp2 function definitions =================================================
#line 1 "mixed-default-arguments.cpp2"
#line 5 "mixed-default-arguments.cpp2"
auto cxx2(cpp2::impl::in<int> x, cpp2::impl::in<std::string> y) -> void{
std::cout << "" + cpp2::to_string(x) + " \"" + cpp2::to_string(y) + "\"\n";
}
#line 9 "mixed-default-arguments.cpp2"
auto main() -> int{
cxx(1, "test");
cxx({ }, { });
cxx2(1, "test");
cxx2({ }, { });
}