Fix defect where constructor fields not show for Value constructors. (#7080)

The `IdExecutionService` now uses `getName` not `getDisplayName` for atomConstructor.
`getDisplayName` adjusts the name if the name is `Value` or `Error`, which meant no parameters in IDE.

Before:
![image](https://github.com/enso-org/enso/assets/4699705/ddc564fe-3213-46ec-9684-ab718f8bb0bb)

Now:
![image](https://github.com/enso-org/enso/assets/4699705/59d3ece4-1148-44bb-8a13-7bc3db8dfca2)
This commit is contained in:
James Dunkerley 2023-06-20 13:47:16 +01:00 committed by GitHub
parent d26b826a77
commit 90df5adfb0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -20,7 +20,7 @@ import org.enso.logger.masking.MaskedString;
import org.enso.pkg.QualifiedName;
public interface IdExecutionService {
public static final String INSTRUMENT_ID = "id-value-extractor";
String INSTRUMENT_ID = "id-value-extractor";
/**
* Attach a new event node factory to observe identified nodes within given function.
@ -222,7 +222,7 @@ public interface IdExecutionService {
AtomConstructor atomConstructor = qualifiedAccessor.getAtomConstructor();
moduleName = atomConstructor.getDefinitionScope().getModule().getName();
typeName = atomConstructor.getType().getQualifiedName();
functionName = atomConstructor.getDisplayName();
functionName = atomConstructor.getName();
}
case EnsoRootNode ensoRootNode -> {
moduleName = ensoRootNode.getModuleScope().getModule().getName();