Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Replace non-breaking space characters in code snippets #2288

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
per1234 merged 1 commit into arduino:main from per1234:fix-stray-errors
Nov 15, 2024

Conversation

Copy link
Contributor

@per1234 per1234 commented Nov 15, 2024

What This PR Changes

Some of the sketch code was littered with random use of the non-breaking space character in place of standard space characters. Although the two characters appear the same to a human, they are not the same to the compiler, and so cause spurious errors when the sketch was compiled:

sketch_nov15a.ino:3:1: error: stray '302円' in program
  // initialize digital pin LEDR as an output.
 ^
sketch_nov15a.ino:3:2: error: stray '240円' in program
  // initialize digital pin LEDR as an output.
 ^
exit status 1
Compilation error: stray '302円' in program

The solution is to replace these invalid characters with standard spaces

Additional Context

Originally reported by @CarlKho-Minerva at arduino-libraries/Arduino_Pro_Tutorials#42

Contribution Guidelines

CarlKho-Minerva reacted with thumbs up emoji
Some of the sketch code was littered with random use of the non-breaking space character in place of standard space characters. Although the two characters appear the same to a human, they are not the same to the compiler, and so cause spurious errors when the sketch was compiled:
```
sketch_nov15a.ino:3:1: error: stray '302円' in program
  // initialize digital pin LEDR as an output.
 ^
sketch_nov15a.ino:3:2: error: stray '240円' in program
  // initialize digital pin LEDR as an output.
 ^
exit status 1
Compilation error: stray '302円' in program
```
The solution is to replace these invalid characters with standard spaces
@per1234 per1234 merged commit ad6f86a into arduino:main Nov 15, 2024
4 checks passed
@per1234 per1234 deleted the fix-stray-errors branch November 15, 2024 10:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Reviewers

@g-castronovo g-castronovo g-castronovo approved these changes

@GDJose GDJose Awaiting requested review from GDJose

@jacobhylen jacobhylen Awaiting requested review from jacobhylen

@TaddyHC TaddyHC Awaiting requested review from TaddyHC

Assignees
No one assigned
Labels
arduino Bugs and fixes added by the Arduino Team bug Something isn't working
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

AltStyle によって変換されたページ (->オリジナル) /