Skip to content
  • Milian Wolff's avatar
    kdev-clang: Offer all include paths for code completion · 015141e3
    Milian Wolff authored
    We used to only offer code completion of project paths for local
    code completion in `#include "..."` contexts. And for vice versa,
    we only offered system paths for global code completion in
    `#include <...>` contexts. This is wrong, as the include style
    only changes the order in which a compiler iterates through these
    paths to find an include file. For code completion purposes, this
    is not important.
    
    Now we offer code completion in both path lists always. To show the
    user the right file/dir being included, we don't sort and unify the
    search path list anymore as that potentially changes the final result.
    Rather, we use a hash set to ensure we don't encounter paths multiple
    times and iterate over the search path lists in their original order.
    
    BUG: 386421
    015141e3