Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
B
blender-dev-tools
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
blender
blender-dev-tools
Commits
f4af5ed5
Commit
f4af5ed5
authored
Apr 11, 2022
by
Campbell Barton
Browse files
Options
Downloads
Patches
Plain Diff
check_spelling: restore block check
This should eventually be moved into a separate checking tool.
parent
4c1e01e3
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
check_source/check_spelling.py
+17
-0
17 additions, 0 deletions
check_source/check_spelling.py
with
17 additions
and
0 deletions
check_source/check_spelling.py
+
17
−
0
View file @
f4af5ed5
...
...
@@ -349,6 +349,23 @@ def extract_c_comments(filepath: str) -> Tuple[List[Comment], Set[str]]:
else
:
pass
if
PRINT_NON_ALIGNED
:
for
i
,
i_next
in
comment_ranges
:
# Seek i back to the line start.
i_bol
=
text
.
rfind
(
"
\n
"
,
0
,
i
)
+
1
l_ofs_first
=
i
-
i_bol
star_offsets
=
set
()
block
=
text
[
i_bol
:
i_next
]
for
line_index
,
l
in
enumerate
(
block
.
split
(
"
\n
"
)):
star_offsets
.
add
(
l
.
find
(
"
*
"
,
l_ofs_first
))
l_ofs_first
=
0
if
len
(
star_offsets
)
>
1
:
print
(
"
%s:%d
"
%
(
filepath
,
line_index
+
text
.
count
(
"
\n
"
,
0
,
i
)))
break
if
not
PRINT_SPELLING
:
return
[],
[]
# Collect variables from code, so we can reference variables from code blocks
# without this generating noise from the spell checker.
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment