AndrewMascolo / CountUpDownTimer

MIT License
28 stars 20 forks source link

expected unqualified-id before numeric constant #33

Open negativ72rus opened 3 years ago

negativ72rus commented 3 years ago

Hey! VS Code swears at the library when compiling a project:

lib\CountUpDownTimer/CountUpDownTimer.h: In member function 'void CountUpDownTimer::SetTimer(long unsigned int, long unsigned int, long unsigned int, long unsigned int)': lib\CountUpDownTimer/CountUpDownTimer.h:116:16: error: expected unqualified-id before numeric constant unsigned int _S = (seconds / 60), _M = (minutes / 60); ^ In file included from src\main.cpp:7:0: lib\CountUpDownTimer/CountUpDownTimer.h:118:6: error: '_M' was not declared in this scope if(_M > 0) hours += _M;

AndrewMascolo commented 3 years ago

Hmm, sorry about that, I’ll fix it.

Sent from my iPhone

Sent from my iPhone

On Sep 9, 2021, at 8:18 AM, negativ72rus @.***> wrote:  Hey! VS Code swears at the library when compiling a project:

lib\CountUpDownTimer/CountUpDownTimer.h: In member function 'void CountUpDownTimer::SetTimer(long unsigned int, long unsigned int, long unsigned int, long unsigned int)': lib\CountUpDownTimer/CountUpDownTimer.h:116:16: error: expected unqualified-id before numeric constant unsigned int _S = (seconds / 60), _M = (minutes / 60); ^ In file included from src\main.cpp:7:0: lib\CountUpDownTimer/CountUpDownTimer.h:118:6: error: '_M' was not declared in this scope if(_M > 0) hours += _M;

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or unsubscribe. Triage notifications on the go with GitHub Mobile for iOS or Android.

AndrewMascolo commented 3 years ago

Please pull it again, if you are still getting this error, then I will just make it int instead of unsigned int. You may also change the library if you so wish on your end.