Timeline for Native function name w/o parens -- expected behavior?
Current License: CC BY-SA 3.0
14 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Oct 28, 2016 at 13:03 | vote | accept | Jim Mack | ||
Oct 28, 2016 at 9:13 | answer | added | Nick Gammon♦ | timeline score: 2 | |
Oct 28, 2016 at 9:01 | comment | added | Nick Gammon♦ | Yes it will. And I can try that exact IDE. I compiled under 1.6.9 but I expect 1.6.12 will be the same. Wait, that's odd! Under 1.6.12 I only get one warning and no errors! Hmmm - turn warnings up a bit in the preferences. Mine are at "default" | |
Oct 28, 2016 at 3:41 | comment | added | Jim Mack | @NickGammon What can I say? Are we using different versions of the IDE (1.6.12 here)? Are there compile options I'm not seeing? I guarantee that it acts exactly as I describe it and not at all as you describe it, in my setup, which is stock out of the box. The program is short enough that I can post the entire thing if you think that will help. | |
Oct 28, 2016 at 1:41 | comment | added | Nick Gammon♦ |
And on if (millis >= gateStopTime) I get the error: error: ISO C++ forbids comparison between pointer and integer
|
|
Oct 28, 2016 at 1:40 | comment | added | Nick Gammon♦ |
I can't reproduce what you say is happening. For example on your posted line (removing the brackets) gateStopTime = millis + GATE_CLOSE_TIMER; I get the error: error: invalid conversion from 'long unsigned int (*)()' to 'long unsigned int'
|
|
Oct 28, 2016 at 1:21 | comment | added | Chris Stratton | Many compilers will actually produce a warning for this. | |
Oct 28, 2016 at 1:13 | history | edited | Jim Mack | CC BY-SA 3.0 |
added 792 characters in body
|
Oct 28, 2016 at 0:58 | comment | added | Nick Gammon♦ |
Don't just post the line, post enough code to reproduce it (ie. that compiles without errors). For example, what type is future ?
|
|
Oct 28, 2016 at 0:57 | comment | added | Nick Gammon♦ |
Edit the question and put the code there, please using the code formatting markdown (four leading spaces). For help see Markdown help. You should be able to do this by selecting the code and pressing Ctrl+K to have your browser do this for you. That if statement doesn't look valid anyway.
|
|
Oct 28, 2016 at 0:51 | comment | added | Jim Mack |
Not sure how to format code in a comment, but.. basically the use is future = millis() + delay followed later by if millis >= future
|
|
Oct 28, 2016 at 0:47 | comment | added | Nick Gammon♦ |
When you say you "used" millis - can you post the code? A line like this generates a compiler error: int foo = millis; The error is invalid conversion from 'long unsigned int (*)()' to 'long unsigned int'
|
|
Oct 27, 2016 at 22:43 | answer | added | Dat Ha | timeline score: 0 | |
Oct 27, 2016 at 22:06 | history | asked | Jim Mack | CC BY-SA 3.0 |