sourcegraph / scip

SCIP Code Intelligence Protocol
Apache License 2.0
231 stars 32 forks source link

Symbol grammar clarifications #255

Closed kritzcreek closed 4 days ago

kritzcreek commented 6 days ago

Unfortunately I can not get the "build process" to work on my local machine.

Test plan

Added checks to the lint command for checking canonical identifiers and that parsing succeeds

varungandhi-src commented 6 days ago

We could add checks to scip lint

Sure, that'd be great.

kritzcreek commented 6 days ago

Sure, that'd be great.

Allright, I think that should work. PTAL

kritzcreek commented 5 days ago

Noticed one more difference between the spec and scip-clang while writing some benchmarks. scip-clang will generate descriptors like my_func()., while the spec does not make the disambiguator in the parenthesis optional.

Spec issue, or scip-clang issue?

varungandhi-src commented 5 days ago

Noticed one more difference between the spec and scip-clang while writing some benchmarks. scip-clang will generate descriptors like my_func()., while the spec does not make the disambiguator in the parenthesis optional.

Hmm, I don't see why the disambiguator should be forced to be non-empty -- the rationale for having the disambiguator is that different disambiguator values can correspond to different method overloads (there is no further sub-structure inside it). An empty string is just another string, which is different from other non-empty strings. Unless someone has a compelling reason otherwise, I think we should allow the disambiguator to be empty.

kritzcreek commented 5 days ago

Unless someone has a compelling reason otherwise, I think we should allow the disambiguator to be empty.

@olafurpg @keynmol Thoughts?

olafurpg commented 4 days ago

+1 to allowing empty disambiguators