| File | Lines added | Lines deleted |
|---|---|---|
| test-files/all.cpp | 50 | 0 |
| test-files/primitive-all.cpp | 29 | 0 |
| test-files/primitive-dec.cpp | 21 | 0 |
| test-files/primitive-inc.cpp | 21 | 0 |
| test-files/vector-all.cpp | 34 | 0 |
| File test-files/all.cpp added (mode: 100644) (index 0000000..107f097) | |||
| 1 | #include <cstdlib> | ||
| 2 | |||
| 3 | #include <vector> | ||
| 4 | |||
| 5 | inline void | ||
| 6 | doNothing() | ||
| 7 | { | ||
| 8 | // do nothing on purpose | ||
| 9 | } | ||
| 10 | |||
| 11 | int | ||
| 12 | main() | ||
| 13 | { | ||
| 14 | for (int i = 0; i < 5; i--) { | ||
| 15 | doNothing(); | ||
| 16 | } | ||
| 17 | |||
| 18 | for (int i = 0; i < 5; --i) { | ||
| 19 | doNothing(); | ||
| 20 | } | ||
| 21 | |||
| 22 | for (int i = 0; i < 5; i++) { | ||
| 23 | doNothing(); | ||
| 24 | } | ||
| 25 | |||
| 26 | for (int i = 0; i < 5; ++i) { | ||
| 27 | doNothing(); | ||
| 28 | } | ||
| 29 | |||
| 30 | std::vector<int> v; | ||
| 31 | typedef std::vector<int> IntVector; | ||
| 32 | |||
| 33 | for (IntVector::const_iterator cit = v.begin(); cit != v.end(); cit++) { | ||
| 34 | doNothing(); | ||
| 35 | } | ||
| 36 | |||
| 37 | for (IntVector::const_iterator cit = v.begin(); cit != v.end(); ++cit) { | ||
| 38 | doNothing(); | ||
| 39 | } | ||
| 40 | |||
| 41 | for (IntVector::const_iterator cit = v.begin(); cit != v.end(); cit--) { | ||
| 42 | doNothing(); | ||
| 43 | } | ||
| 44 | |||
| 45 | for (IntVector::const_iterator cit = v.begin(); cit != v.end(); --cit) { | ||
| 46 | doNothing(); | ||
| 47 | } | ||
| 48 | |||
| 49 | return EXIT_SUCCESS; | ||
| 50 | } | ||
| File test-files/primitive-all.cpp added (mode: 100644) (index 0000000..64cb726) | |||
| 1 | #include <cstdlib> | ||
| 2 | |||
| 3 | inline void | ||
| 4 | doNothing() | ||
| 5 | { | ||
| 6 | // do nothing on purpose | ||
| 7 | } | ||
| 8 | |||
| 9 | int | ||
| 10 | main(void) | ||
| 11 | { | ||
| 12 | for (int i = 0; i < 10; i++) { | ||
| 13 | doNothing(); | ||
| 14 | } | ||
| 15 | |||
| 16 | for (int i = 0; i < 10; ++i) { | ||
| 17 | doNothing(); | ||
| 18 | } | ||
| 19 | |||
| 20 | for (int i = 0; i < 10; i--) { | ||
| 21 | doNothing(); | ||
| 22 | } | ||
| 23 | |||
| 24 | for (int i = 0; i < 10; --i) { | ||
| 25 | doNothing(); | ||
| 26 | } | ||
| 27 | |||
| 28 | return EXIT_SUCCESS; | ||
| 29 | } | ||
| File test-files/primitive-dec.cpp added (mode: 100644) (index 0000000..3ca9f3d) | |||
| 1 | #include <cstdlib> | ||
| 2 | |||
| 3 | inline void | ||
| 4 | doNothing() | ||
| 5 | { | ||
| 6 | // do nothing on purpose | ||
| 7 | } | ||
| 8 | |||
| 9 | int | ||
| 10 | main(void) | ||
| 11 | { | ||
| 12 | for (int i = 0; i < 10; i--) { | ||
| 13 | doNothing(); | ||
| 14 | } | ||
| 15 | |||
| 16 | for (int i = 0; i < 10; --i) { | ||
| 17 | doNothing(); | ||
| 18 | } | ||
| 19 | |||
| 20 | return EXIT_SUCCESS; | ||
| 21 | } | ||
| File test-files/primitive-inc.cpp added (mode: 100644) (index 0000000..adc0cea) | |||
| 1 | #include <cstdlib> | ||
| 2 | |||
| 3 | inline void | ||
| 4 | doNothing() | ||
| 5 | { | ||
| 6 | // do nothing on purpose | ||
| 7 | } | ||
| 8 | |||
| 9 | int | ||
| 10 | main(void) | ||
| 11 | { | ||
| 12 | for (int i = 0; i < 10; i++) { | ||
| 13 | doNothing(); | ||
| 14 | } | ||
| 15 | |||
| 16 | for (int i = 0; i < 10; ++i) { | ||
| 17 | doNothing(); | ||
| 18 | } | ||
| 19 | |||
| 20 | return EXIT_SUCCESS; | ||
| 21 | } | ||
| File test-files/vector-all.cpp added (mode: 100644) (index 0000000..42aa3d3) | |||
| 1 | #include <cstdlib> | ||
| 2 | |||
| 3 | #include <vector> | ||
| 4 | |||
| 5 | inline void | ||
| 6 | doNothing() | ||
| 7 | { | ||
| 8 | // do nothing on purpose | ||
| 9 | } | ||
| 10 | |||
| 11 | int | ||
| 12 | main(void) | ||
| 13 | { | ||
| 14 | std::vector<int> v; | ||
| 15 | typedef std::vector<int> intVector; | ||
| 16 | |||
| 17 | for (intVector::const_iterator cit = v.begin(); cit != v.end(); cit++) { | ||
| 18 | doNothing(); | ||
| 19 | } | ||
| 20 | |||
| 21 | for (intVector::const_iterator cit = v.begin(); cit != v.end(); ++cit) { | ||
| 22 | doNothing(); | ||
| 23 | } | ||
| 24 | |||
| 25 | for (intVector::const_iterator cit = v.begin(); cit != v.end(); cit--) { | ||
| 26 | doNothing(); | ||
| 27 | } | ||
| 28 | |||
| 29 | for (intVector::const_iterator cit = v.begin(); cit != v.end(); --cit) { | ||
| 30 | doNothing(); | ||
| 31 | } | ||
| 32 | |||
| 33 | return EXIT_SUCCESS; | ||
| 34 | } | ||