MLIR
19.0.0git
|
#include "mlir/Tools/lsp-server-support/Protocol.h"
Public Member Functions | |
LogicalResult | applyTo (std::string &contents) const |
Try to apply this change to the given contents string. More... | |
Static Public Member Functions | |
static LogicalResult | applyTo (ArrayRef< TextDocumentContentChangeEvent > changes, std::string &contents) |
Try to apply a set of changes to the given contents string. More... | |
Public Attributes | |
std::optional< Range > | range |
The range of the document that changed. More... | |
std::optional< int > | rangeLength |
The length of the range that got replaced. More... | |
std::string | text |
The new text of the range/document. More... | |
Definition at line 483 of file Protocol.h.
|
static |
Try to apply a set of changes to the given contents string.
Definition at line 536 of file Protocol.cpp.
References mlir::failed(), mlir::failure(), and mlir::success().
LogicalResult TextDocumentContentChangeEvent::applyTo | ( | std::string & | contents | ) | const |
Try to apply this change to the given contents string.
Definition at line 515 of file Protocol.cpp.
References mlir::failure(), range, mlir::success(), and text.
std::optional<Range> mlir::lsp::TextDocumentContentChangeEvent::range |
The range of the document that changed.
Definition at line 491 of file Protocol.h.
Referenced by applyTo(), and mlir::lsp::fromJSON().
std::optional<int> mlir::lsp::TextDocumentContentChangeEvent::rangeLength |
The length of the range that got replaced.
Definition at line 494 of file Protocol.h.
Referenced by mlir::lsp::fromJSON().
std::string mlir::lsp::TextDocumentContentChangeEvent::text |
The new text of the range/document.
Definition at line 497 of file Protocol.h.
Referenced by applyTo(), and mlir::lsp::fromJSON().