Skip to content

Commit b15d0aa

Browse files
authored
Fix compilation with GCC <= 10 (asmaloney#241)
Remove unnecessary semicolons after function definitions Fixes the following warning treated as an error when compiling with GCC <= 10: error: extra ‘;’ [-Werror=pedantic]
1 parent d154ca6 commit b15d0aa

File tree

3 files changed

+19
-19
lines changed

3 files changed

+19
-19
lines changed

src/E57SimpleReader.cpp

+11-11
Original file line numberDiff line numberDiff line change
@@ -44,27 +44,27 @@ namespace e57
4444
bool Reader::IsOpen() const
4545
{
4646
return impl_->IsOpen();
47-
};
47+
}
4848

4949
bool Reader::Close()
5050
{
5151
return impl_->Close();
52-
};
52+
}
5353

5454
bool Reader::GetE57Root( E57Root &fileHeader ) const
5555
{
5656
return impl_->GetE57Root( fileHeader );
57-
};
57+
}
5858

5959
int64_t Reader::GetImage2DCount() const
6060
{
6161
return impl_->GetImage2DCount();
62-
};
62+
}
6363

6464
bool Reader::ReadImage2D( int64_t imageIndex, Image2D &image2DHeader ) const
6565
{
6666
return impl_->ReadImage2D( imageIndex, image2DHeader );
67-
};
67+
}
6868

6969
bool Reader::GetImage2DSizes( int64_t imageIndex, Image2DProjection &imageProjection,
7070
Image2DType &imageType, int64_t &imageWidth, int64_t &imageHeight,
@@ -73,7 +73,7 @@ namespace e57
7373
{
7474
return impl_->GetImage2DSizes( imageIndex, imageProjection, imageType, imageWidth,
7575
imageHeight, imageSize, imageMaskType, imageVisualType );
76-
};
76+
}
7777

7878
int64_t Reader::ReadImage2DData( int64_t imageIndex, Image2DProjection imageProjection,
7979
Image2DType imageType, void *pBuffer, int64_t start,
@@ -86,12 +86,12 @@ namespace e57
8686
impl_->ReadImage2DData( imageIndex, imageProjection, imageType, buffer, start, size );
8787

8888
return static_cast<int64_t>( read );
89-
};
89+
}
9090

9191
int64_t Reader::GetData3DCount() const
9292
{
9393
return impl_->GetData3DCount();
94-
};
94+
}
9595

9696
ImageFile Reader::GetRawIMF() const
9797
{
@@ -101,17 +101,17 @@ namespace e57
101101
StructureNode Reader::GetRawE57Root() const
102102
{
103103
return impl_->GetRawE57Root();
104-
};
104+
}
105105

106106
VectorNode Reader::GetRawData3D() const
107107
{
108108
return impl_->GetRawData3D();
109-
};
109+
}
110110

111111
VectorNode Reader::GetRawImages2D() const
112112
{
113113
return impl_->GetRawImages2D();
114-
};
114+
}
115115

116116
bool Reader::ReadData3D( int64_t dataIndex, Data3D &data3DHeader ) const
117117
{

src/E57SimpleWriter.cpp

+7-7
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,7 @@ namespace e57
180180
bool Writer::IsOpen() const
181181
{
182182
return impl_->IsOpen();
183-
};
183+
}
184184

185185
bool Writer::Close()
186186
{
@@ -200,12 +200,12 @@ namespace e57
200200
buffer, startPos, sizeInBytes );
201201

202202
return static_cast<int64_t>( written );
203-
};
203+
}
204204

205205
int64_t Writer::NewImage2D( Image2D &image2DHeader )
206206
{
207207
return impl_->NewImage2D( image2DHeader );
208-
};
208+
}
209209

210210
int64_t Writer::WriteImage2DData( int64_t imageIndex, Image2DType imageType,
211211
Image2DProjection imageProjection, void *pBuffer,
@@ -253,7 +253,7 @@ namespace e57
253253
int64_t Writer::NewData3D( Data3D &data3DHeader )
254254
{
255255
return impl_->NewData3D( data3DHeader );
256-
};
256+
}
257257

258258
CompressedVectorWriter Writer::SetUpData3DPointsData( int64_t dataIndex, size_t pointCount,
259259
const Data3DPointsFloat &buffers )
@@ -283,15 +283,15 @@ namespace e57
283283
StructureNode Writer::GetRawE57Root()
284284
{
285285
return impl_->GetRawE57Root();
286-
};
286+
}
287287

288288
VectorNode Writer::GetRawData3D()
289289
{
290290
return impl_->GetRawData3D();
291-
};
291+
}
292292

293293
VectorNode Writer::GetRawImages2D()
294294
{
295295
return impl_->GetRawImages2D();
296-
};
296+
}
297297
} // end namespace e57

src/NodeImpl.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ bool NodeImpl::isRoot() const
5858
checkImageFileOpen( __FILE__, __LINE__, static_cast<const char *>( __FUNCTION__ ) );
5959

6060
return parent_.expired();
61-
};
61+
}
6262

6363
NodeImplSharedPtr NodeImpl::parent()
6464
{

0 commit comments

Comments
 (0)