Class StandardTags.WriteVariableTag
java.lang.Object
com.oracle.truffle.api.instrumentation.Tag
com.oracle.truffle.api.instrumentation.StandardTags.WriteVariableTag
- Enclosing class:
StandardTags
Marks program locations to be considered as writes of variables of the languages.
Use case descriptions:
- Language Server Protocol: Marks every write of a variable to support the documentHighlight, hover, definition and references requests.
StandardTags.WriteVariableTag
also provides a node
object
that has NAME
property. The value of that property is
either:
- a String name of the variable (in that case the node's
source section
is considered as the variable's source section), - an object that provides name and
SourceSection
viaInteropLibrary.asString(Object)
andInteropLibrary.getSourceLocation(Object)
respectively, - an array of objects when multiple variables are being read, where each array element
provides name and
SourceSection
as specified above.
StandardTags.WriteVariableTag
have to provide a
source section
.- Since:
- 20.0.0
-
Nested Class Summary
Nested classes/interfaces inherited from class com.oracle.truffle.api.instrumentation.Tag
Tag.Identifier
-
Field Summary
-
Method Summary
Methods inherited from class com.oracle.truffle.api.instrumentation.Tag
findProvidedTag, getIdentifier
-
Field Details
-
NAME
Property of the node object that contains name of the variable.- Since:
- 20.0.0
- See Also:
-