[apex] Decimal LiteralExpression - add TODO

Refs https://github.com/google/summit-ast/pull/47
This commit is contained in:
Andreas Dangel
2024-02-13 18:44:53 +01:00
parent 204232c238
commit f12beff7c9

View File

@ -40,6 +40,7 @@ public final class ASTLiteralExpression extends AbstractApexNode.Single<LiteralE
} else if (node instanceof LiteralExpression.IntegerVal) {
return LiteralType.INTEGER;
} else if (node instanceof LiteralExpression.DoubleVal) {
// TODO Replace this workaround with LiteralExpression.DecimalVal, see below and https://github.com/google/summit-ast/pull/47
Chars source = getTextDocument().getText().slice(getTextRegion());
if (source.indexOf('d') > -1 || source.indexOf('D') > -1) {
return LiteralType.DOUBLE;