-
-
Notifications
You must be signed in to change notification settings - Fork 7k
#define E 2.718281828459045235360287471352 #1792
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
Comments
Can the name be a little longer? Like EULER or E_EULER? I would like to avoid issues like #1735 |
#1735: Agree, replacing all E's with 2.7... would be nasty. I have found EULER as M_E in - http://www.nongnu.org/avr-libc/user-manual/group__avr__math.html - For Arduino.h EULER is a good name, no need to include math.h for the beginners. |
I don't want to be the bad guy but I think it should be instead of |
Thank you for being a bad guy. Shame on me. Fixed. |
#define Jantje right |
blush |
A bunch of functions have parameters they do not use, but which cannot be removed for API compatibility. In syscalls_sam3.c, there are a lot of these, so this adds an "UNUSED" macro which adds the "unused" variable attribute if supported (GCC specific), or is just a noop on other compilers. In CDC.cpp, there's only three of these variables, so this commit just forces a dummy evaluation of them to suppress the warnings. This helps towards arduino#1792.
len is an unsigned variable, so it will never be less than 0. This helps towards arduino#1792.
This makes the declaration of sprintf available, so the function is not implicitely declared, which triggers two compiler warnings. This helps towards arduino#1792
This helps towards arduino#1792
Members of this array are later passed to functions that accept non-const pointers. These functions probably don't modify their arguments, so a better solution would be to update those functions to accept const pointers. However, they look like third-party code, so that would require changing the code again on every update. Removing const here fixes at least the compiler warning for now. This helps towards arduino#1792.
A bunch of functions have parameters they do not use, but which cannot be removed for API compatibility. In syscalls_sam3.c, there are a lot of these, so this adds an "UNUSED" macro which adds the "unused" variable attribute if supported (GCC specific), or is just a noop on other compilers. In CDC.cpp, there's only three of these variables, so this commit just forces a dummy evaluation of them to suppress the warnings. This helps towards arduino#1792.
len is an unsigned variable, so it will never be less than 0. This helps towards arduino#1792.
This makes the declaration of sprintf available, so the function is not implicitely declared, which triggers two compiler warnings. This helps towards arduino#1792
This helps towards arduino#1792
Members of this array are later passed to functions that accept non-const pointers. These functions probably don't modify their arguments, so a better solution would be to update those functions to accept const pointers. However, they look like third-party code, so that would require changing the code again on every update. Removing const here fixes at least the compiler warning for now. This helps towards arduino#1792.
Can e be added to Arduino.h ?
define E = 2.718281828459045235360287471352
source - http://www.miniwebtool.com/first-n-digits-of-e/?number=30
I needed it today for a test and it was not supported where PI is
(ok lowest prio)
The text was updated successfully, but these errors were encountered: