Skip to content

Different compilation with comments / ** / multiple lines #1293

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

Closed
Baro82 opened this issue Feb 24, 2013 · 1 comment
Closed

Different compilation with comments / ** / multiple lines #1293

Baro82 opened this issue Feb 24, 2013 · 1 comment
Labels
Component: IDE The Arduino IDE

Comments

@Baro82
Copy link

Baro82 commented Feb 24, 2013

Testing the compiling code with the comment // and with the comment // on a single line the result is different than commenting // on multiple lines, eg. :
/*
Do something
*/

The result of the compilation in bytes is different, as if the multi line comment would include the code in the comment. I reported the problem with more details testing on this link of the forum (in Italian): http://arduino.cc/forum/index.php/topic,150320.0.html

Thanks

@wimlangers
Copy link

I noticed a similar issue :
Below code does not run, if I completely remove the commented out section with the includes, then it will run normal ??
#include <Arduino.h>
/*
#include "awl.h"
#include "rdcnet.h"

struct ra_telegram *p;
uint8_t addr = false;
uint8_t ctr = 0;
uint8_t stat = false;
uint32_t millis_old = millis();
*/

void setup() {
pinMode(13,HIGH);
// ra_init(49,5,7,255);
}

void loop() {
digitalWrite(13,!digitalRead(13));
delay(500);

/*
if (!stat) {
if (ra_addressGet()) {
ra_address(50,0);
stat = true;
}
}
if (addr) {
if (((millis() - millis_old) & 0x7FFFFFFF) > 200) {
millis_old = millis();
if (p = ra_transmitGet()) {
p->to = 49;
p->from = 49;
p->command = 't';
p->data[0] = 'b';
p->data[1] = 'c';
p->data[2] = 'd';
p->data[3] = 'e';
ra_transmit();
p = NULL;
if (++ctr > 8) ctr = 0;
}
}
}
if (p = ra_receiveGet()) {
if (p->command == 'Q') addr = true;
if (p->command > 128) addr = false;
digitalWrite(13,!digitalRead(13));
ra_receive();
}
*/
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Component: IDE The Arduino IDE
Projects
None yet
Development

No branches or pull requests

3 participants