[cfe-dev] no autocomplete

Anton Smirnov dev at antonsmirnov.name
Mon Dec 9 03:53:08 PST 2013


Hello,

I've found strange behaviour of autocomplete - proper autocomplete for my
test class
and no autocomplete for a list of inclusions.

header:
----------
#ifndef Test_h
#define Test_h

class TestClass
{
  public:
    int test_method(int a) {
      return a * 2;
    }
};

extern TestClass TestVar;

#endif

source:
-----------
#include <test_header.h>\n\
int main() {\n\
  TestVar. ;\n\
  return 0;\n\
}

autocomplete for the position after dot is ok - it suggests test_method(),
ctor and dtor

For the more complex case it suggests nothing:
headers:
------------
HardwareSerial.h  -  class HardwareSerial : public Stream
Stream.h - class Stream : public Print
Print.g - class Print

source:
-----------
#include <Arduino.h>\n\
#include <Client.h>\n\
#include <HardwareSerial.h>\n\
#include <IPAddress.h>\n\
#include <Platform.h>\n\
#include <Print.h>\n\
#include <Printable.h>\n\
#include <Server.h>\n\
#include <Stream.h>\n\
#include <USBAPI.h>\n\
#include <USBCore.h>\n\
#include <USBDesc.h>\n\
#include <Udp.h>\n\
#include <WCharacter.h>\n\
#include <WString.h>\n\
#include <binary.h>\n\
#include <new.h>\n\
#include <wiring_private.h>\n\
\n\
int main() {\n\
  Serial.  ;\n\
  return 0;\n\
}"


execution is done with -L arguments where headers are located. Headers and
according files are ok, since it's Arduino 1.0.5 distribution.

So autocomplete for dot position (next column to be more detailed) returns
nothing, but Serial class methods classes are expected to be listed.

I have some parse warning and 1 parse error, but autocomplete for previous
column returns a whole list of suggestions including classes from header
files, so i believe includes are working.

How can i understand what's wrong? Is it a bug or i'm doing smth wrong?

Regards, Anton.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20131209/a35ada59/attachment.html>


More information about the cfe-dev mailing list