Skip to content

Commit

Permalink
Remove register option
Browse files Browse the repository at this point in the history
  • Loading branch information
mp-se committed Mar 12, 2023
1 parent 3f4fcf5 commit 1cc3474
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions ArduinoLog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -172,12 +172,12 @@ void Logging::printFormat(const char format, va_list *args) {
}
else if (format == 's')
{
register char *s = va_arg(*args, char *);
char *s = va_arg(*args, char *);
_logOutput->print(s);
}
else if (format == 'S')
{
register __FlashStringHelper *s = va_arg(*args, __FlashStringHelper *);
__FlashStringHelper *s = va_arg(*args, __FlashStringHelper *);
_logOutput->print(s);
}
else if (format == 'd' || format == 'i')
Expand All @@ -196,15 +196,15 @@ void Logging::printFormat(const char format, va_list *args) {
{
_logOutput->print("0x");
//_logOutput->print(va_arg(*args, int), HEX);
register uint16_t h = (uint16_t) va_arg( *args, int );
uint16_t h = (uint16_t) va_arg( *args, int );
if (h<0xFFF) _logOutput->print('0');
if (h<0xFF ) _logOutput->print('0');
if (h<0xF ) _logOutput->print('0');
_logOutput->print(h,HEX);
}
else if (format == 'p')
{
register Printable *obj = (Printable *) va_arg(*args, int);
Printable *obj = (Printable *) va_arg(*args, int);
_logOutput->print(*obj);
}
else if (format == 'b')
Expand All @@ -229,7 +229,7 @@ void Logging::printFormat(const char format, va_list *args) {
_logOutput->print((char) va_arg(*args, int));
}
else if( format == 'C' ) {
register char c = (char) va_arg( *args, int );
char c = (char) va_arg( *args, int );
if (c>=0x20 && c<0x7F) {
_logOutput->print(c);
} else {
Expand Down

2 comments on commit 1cc3474

@muanis
Copy link

@muanis muanis commented on 1cc3474 Apr 2, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you pull request this? had to do the same :-/

@mp-se
Copy link
Owner Author

@mp-se mp-se commented on 1cc3474 Apr 2, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, as soon as i have tested it.

Please sign in to comment.