• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

daisytuner / sdfglib / 15588785214

11 Jun 2025 03:14PM UTC coverage: 61.749% (+0.02%) from 61.731%
15588785214

Pull #71

github

web-flow
Merge d66f7c41a into 6eb4aad5d
Pull Request #71: Extract function name from sdfg

7 of 8 new or added lines in 2 files covered. (87.5%)

1 existing line in 1 file now uncovered.

7266 of 11767 relevant lines covered (61.75%)

124.98 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

98.15
/src/element.cpp
1
#include "sdfg/element.h"
2

3
#include <boost/uuid/uuid_io.hpp>
4

5
namespace sdfg {
6

7
boost::uuids::random_generator thread_local Element::UUID_GENERATOR;
8

9
DebugInfo::DebugInfo()
2,687✔
10
    : filename_(),
2,687✔
11
      functionname_(),
2,687✔
12
      start_line_(0),
2,687✔
13
      start_column_(0),
2,687✔
14
      end_line_(0),
2,687✔
15
      end_column_(0),
2,687✔
16
      has_(false) {
2,687✔
17

18
      };
2,687✔
19

20
DebugInfo::DebugInfo(std::string filename, size_t start_line, size_t start_column, size_t end_line,
18✔
21
                     size_t end_column)
22
    : filename_(filename),
9✔
23
      start_line_(start_line),
9✔
24
      start_column_(start_column),
9✔
25
      end_line_(end_line),
9✔
26
      end_column_(end_column),
9✔
27
      has_(true) {
9✔
28

29
      };
9✔
30

31
bool DebugInfo::has() const { return this->has_; };
129✔
32

33
std::string DebugInfo::filename() const { return this->filename_; };
119✔
34

35
size_t DebugInfo::start_line() const { return this->start_line_; };
115✔
36

37
size_t DebugInfo::start_column() const { return this->start_column_; };
115✔
38

39
size_t DebugInfo::end_line() const { return this->end_line_; };
115✔
40

41
size_t DebugInfo::end_column() const { return this->end_column_; };
115✔
42

43
DebugInfo DebugInfo::merge(const DebugInfo& left, const DebugInfo& right) {
10✔
44
    if (!left.has()) {
10✔
45
        return right;
7✔
46
    }
47
    if (!right.has()) {
3✔
48
        return left;
1✔
49
    }
50
    if (left.filename() != right.filename()) {
2✔
UNCOV
51
        throw InvalidSDFGException("DebugInfo: Filenames do not match");
×
52
    }
53

54
    size_t start_line = 0;
2✔
55
    size_t start_column = 0;
2✔
56
    size_t end_line = 0;
2✔
57
    size_t end_column = 0;
2✔
58

59
    if (left.start_line_ < right.start_line_) {
2✔
60
        start_line = left.start_line_;
1✔
61
        start_column = left.start_column_;
1✔
62
    } else {
1✔
63
        start_line = right.start_line_;
1✔
64
        start_column = right.start_column_;
1✔
65
    }
66

67
    if (left.end_line_ > right.end_line_) {
2✔
68
        end_line = left.end_line_;
1✔
69
        end_column = left.end_column_;
1✔
70
    } else {
1✔
71
        end_line = right.end_line_;
1✔
72
        end_column = right.end_column_;
1✔
73
    }
74
    return DebugInfo(left.filename_, start_line, start_column, end_line, end_column);
2✔
75
};
10✔
76

77
Element::Element(const DebugInfo& debug_info) : debug_info_(debug_info) {
3,683✔
78
    boost::uuids::uuid uuid = UUID_GENERATOR();
3,683✔
79
    this->element_id_ = boost::uuids::to_string(uuid);
3,683✔
80
};
3,683✔
81

82
std::string Element::element_id() const { return this->element_id_; };
2,430✔
83

84
const DebugInfo& Element::debug_info() const { return this->debug_info_; };
198✔
85

86
}  // namespace sdfg
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc