Skip to content
This repository was archived by the owner on Oct 22, 2021. It is now read-only.

Some syntax are not identified and marked as Problem #244

Closed
mishracodes opened this issue May 6, 2020 · 4 comments
Closed

Some syntax are not identified and marked as Problem #244

mishracodes opened this issue May 6, 2020 · 4 comments
Labels
type: imperfection Something isn't working

Comments

@mishracodes
Copy link

Describe the bug
Some of the Syntax and identifiers are not recognized by editor and red underline comes under it. Like in pinMode(2,OUTPUT); here OUTPUT is not recognized and says "Use of undeclared identifier 'OUTPUT'clang(undeclared_var_use)"
There are many more like
Serial in Serial.begin();
A0 port number
delay in delay(1000);
LED_BUILTIN
LOW in digitalWrite(2,LOW);
HIGH in digitalWrite(2,HIGH);
digitalRead but not digitalWrite and many more
The code is verified successfully and uploading also but only showing underline in editor and also in the Problem panel.

Also I added Simple DHT Library and on declaring DHT object it is showing red underline but the code is working perfectly and giving reading on the serial monitor.

Expected behavior
It should not display error and problems in the system defined functions and constants and also in other functions, constants and objects if its library is included.

Screenshots
https://drive.google.com/open?id=1DaicDwp4aAcbiV7KlOBb-qTKdS2Z69fs

Desktop (please complete the following information):

  • OS: [Windows]
  • Version [10]
@mishracodes mishracodes added the type: imperfection Something isn't working label May 6, 2020
@ThinCode2020
Copy link

ThinCode2020 commented Sep 27, 2020

As of 09-26-2020 still having a lot of under line error:
pinMode(buttonPin, INPUT); Use of undeclared identifier 'INPUT' clang(undeclared_var_use)
pinMode(ledPin, OUTPUT); Use of undeclared identifier 'OUTPUT' clang(undeclared_var_use)
Serial.begin(9600); Use of undeclared identifier 'Serial' clang(undeclared_var_use)
buttonState = digitalRead(buttonPin); Use of undeclared identifier.....
if (buttonState == HIGH) Use of undeclared identifier.....
delay(50); Use of undeclared identifier.....
digitalWrite(ledPin, HIGH); Use of undeclared identifier.....
and more.

Please fix

OS: Win 10

@ubidefeo
Copy link

hi @ThinCode2020
The language server is undergoing an extensive rework, hence we'll keep having this kind of issues for a bit longer.
Please bear with us, we'll do it right asap 🙏

@ThinCode2020
Copy link

ThinCode2020 commented Sep 27, 2020 via email

@per1234
Copy link
Contributor

per1234 commented Feb 17, 2021

Hi @mishracodes. Thanks so much for taking the time to report this!

This should now be working in the new 0.1.4 release of Arduino Pro IDE.

If you try it out and find that the problem is still occurring, feel free to comment here and we'll investigate.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
type: imperfection Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants