Skip to content

Commit 09d47bc

Browse files
fix(ci): macOS Sci_Position ambiguity + codespell fixes
- Cast Sci_Position to qsizetype for QByteArray indexing (macOS long ambiguity between int and qsizetype overloads) - Add SEH to codespell ignore list (valid Windows term) - Fix re-uses → reuses, re-using → reusing Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent 380db4e commit 09d47bc

4 files changed

Lines changed: 6 additions & 6 deletions

File tree

.github/workflows/codespell.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,4 @@ jobs:
2121
check_filenames: true
2222
path: ./src
2323
skip: "*.lua,*.ui"
24-
ignore_words_list: "doubleclick,msdos"
24+
ignore_words_list: "doubleclick,msdos,seh"

src/git/ChangesPanel.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -255,7 +255,7 @@ void ChangesPanel::onTreeClicked(const QModelIndex &index)
255255

256256
// Host (GitTabWidget) knows the repo root; we pass the relative path
257257
// via the entry's relPath. For absolute paths we still need the repo;
258-
// delegate that resolution to the host by re-using the existing
258+
// delegate that resolution to the host by reusing the existing
259259
// GitStatusEntry / GitTabWidget contract.
260260
GitStatusEntry entry;
261261
entry.relPath = rel;

src/git/GitCommitFetcher.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ class GitWatcher;
3939
// and full message body.
4040
// 2. `git -c color.ui=never show --numstat -z --format= <sha>` for the
4141
// file list with binary detection (numstat uses `-\t-\t<path>` for
42-
// binaries — re-uses GitNumstatParser).
42+
// binaries — reuses GitNumstatParser).
4343
// 3. `git -c color.ui=never show --first-parent --no-color -p
4444
// --format= <sha>` for the actual unified diff bytes.
4545
//

src/git/GitDiffSyntaxMapper.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ class LexerDocument final : public Scintilla::IDocument
7171
{
7272
if (line < 0) return 0;
7373
const Sci_Position next = lineStartFor(line + 1);
74-
if (next > 0 && next <= m_content.size() && m_content[next - 1] == '\n')
74+
if (next > 0 && next <= m_content.size() && m_content[static_cast<qsizetype>(next - 1)] == '\n')
7575
return next - 1;
7676
return next;
7777
}
@@ -95,7 +95,7 @@ class LexerDocument final : public Scintilla::IDocument
9595
char SCI_METHOD StyleAt(Sci_Position position) const override
9696
{
9797
if (position < 0 || position >= m_styles.size()) return 0;
98-
return m_styles[position];
98+
return m_styles[static_cast<qsizetype>(position)];
9999
}
100100
Sci_Position SCI_METHOD LineFromPosition(Sci_Position position) const override
101101
{
@@ -163,7 +163,7 @@ class LexerDocument final : public Scintilla::IDocument
163163
{
164164
if (pWidth) *pWidth = 1;
165165
if (position < 0 || position >= m_content.size()) return 0;
166-
return static_cast<unsigned char>(m_content[position]);
166+
return static_cast<unsigned char>(m_content[static_cast<qsizetype>(position)]);
167167
}
168168

169169
private:

0 commit comments

Comments
 (0)