Skip to content

Commit 8a7016c

Browse files
committed
update parse example for optional<double>
1 parent 34cb672 commit 8a7016c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/examples/IfcParseExamples.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -71,8 +71,8 @@ int main(int argc, char** argv) {
7171

7272
const IfcSchema::IfcWindow* window;
7373
if ((window = element->as<IfcSchema::IfcWindow>()) != 0) {
74-
if (window->hasOverallWidth() && window->hasOverallHeight()) {
75-
const double area = window->OverallWidth()*window->OverallHeight();
74+
if (window->OverallWidth() && window->OverallHeight()) {
75+
const double area = *window->OverallWidth() * *window->OverallHeight();
7676
std::cout << "The area of this window is " << area << std::endl;
7777
}
7878
}

0 commit comments

Comments
 (0)