From f61eda58d065bd570dd02e789cb48748bd6f2fce Mon Sep 17 00:00:00 2001 From: eidheim Date: Sun, 28 Jan 2018 18:51:49 +0100 Subject: [PATCH] Language protocol: added go to declaration through control/apple-left mouse click --- src/source_language_protocol.cc | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/source_language_protocol.cc b/src/source_language_protocol.cc index 830411e..3f651b1 100644 --- a/src/source_language_protocol.cc +++ b/src/source_language_protocol.cc @@ -431,6 +431,13 @@ void Source::LanguageProtocolView::setup_navigation_and_refactoring() { Info::get().print("No declaration found"); return offset; }; + get_declaration_or_implementation_locations=[this]() { + std::vector offsets; + auto offset=get_declaration_location(); + if(offset) + offsets.emplace_back(std::move(offset)); + return offsets; + }; } if(capabilities.references) {