diff options
| author | Neil <nyamatongwe@gmail.com> | 2020-06-11 10:08:29 +1000 |
|---|---|---|
| committer | Neil <nyamatongwe@gmail.com> | 2020-06-11 10:08:29 +1000 |
| commit | 877def4f243e1ef5eb39a6132f3969844e00be95 (patch) | |
| tree | 5041a5f52f7d38c026d594f53d3fabc813205221 /src/EditView.cxx | |
| parent | c8136baf0e923ea16cb5e75d75539ca61129925a (diff) | |
| download | scintilla-mirror-877def4f243e1ef5eb39a6132f3969844e00be95.tar.gz | |
Backport: Use noexcept where safe and maintainable.
Backport of changeset 8300:266c8247814e.
Diffstat (limited to 'src/EditView.cxx')
| -rw-r--r-- | src/EditView.cxx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/EditView.cxx b/src/EditView.cxx index edb1e0a05..b3c577177 100644 --- a/src/EditView.cxx +++ b/src/EditView.cxx @@ -213,14 +213,14 @@ void EditView::ClearAllTabstops() noexcept { ldTabstops.reset(); } -XYPOSITION EditView::NextTabstopPos(Sci::Line line, XYPOSITION x, XYPOSITION tabWidth) const { +XYPOSITION EditView::NextTabstopPos(Sci::Line line, XYPOSITION x, XYPOSITION tabWidth) const noexcept { const int next = GetNextTabstop(line, static_cast<int>(x + tabWidthMinimumPixels)); if (next > 0) return static_cast<XYPOSITION>(next); return (static_cast<int>((x + tabWidthMinimumPixels) / tabWidth) + 1) * tabWidth; } -bool EditView::ClearTabstops(Sci::Line line) { +bool EditView::ClearTabstops(Sci::Line line) noexcept { return ldTabstops && ldTabstops->ClearTabstops(line); } @@ -231,7 +231,7 @@ bool EditView::AddTabstop(Sci::Line line, int x) { return ldTabstops && ldTabstops->AddTabstop(line, x); } -int EditView::GetNextTabstop(Sci::Line line, int x) const { +int EditView::GetNextTabstop(Sci::Line line, int x) const noexcept { if (ldTabstops) { return ldTabstops->GetNextTabstop(line, x); } else { |
