summaryrefslogtreecommitdiffstats
path: root/test/clang-tidy/Inputs/performance-unnecessary-value-param/header-fixed.h
diff options
context:
space:
mode:
Diffstat (limited to 'test/clang-tidy/Inputs/performance-unnecessary-value-param/header-fixed.h')
-rw-r--r--test/clang-tidy/Inputs/performance-unnecessary-value-param/header-fixed.h15
1 files changed, 15 insertions, 0 deletions
diff --git a/test/clang-tidy/Inputs/performance-unnecessary-value-param/header-fixed.h b/test/clang-tidy/Inputs/performance-unnecessary-value-param/header-fixed.h
new file mode 100644
index 00000000..f3e9e724
--- /dev/null
+++ b/test/clang-tidy/Inputs/performance-unnecessary-value-param/header-fixed.h
@@ -0,0 +1,15 @@
+// struct ABC is expensive to copy and should be
+// passed as a const referece.
+struct ABC {
+ ABC(const ABC&);
+ int get(int) const;
+};
+
+
+int f1(int n, const ABC& v1, const ABC& v2); // line 9
+
+int f1(int n, ABC v1); // line 11
+
+
+
+int f2( int n, const ABC& v2); // line 15