PsiExpression (@NotNull PsiExpression context, @NotNull PsiManager manager, @NotNull String text) { Map<String, PsiExpression> cache = LITERAL_EXPRESSION_CACHE.get(manager); if (cache == null) { cache = ContainerUtil.createConcurrentSoftValueMap(); cache = manager.putUserDataIfAbsent(LITERAL_EXPRESSION_CACHE, cache); } PsiExpression expression = cache.get(text); if (expression == null) { expression = JavaPsiFacade.getElementFactory(manager.getProject()).createExpressionFromText(text, context); cache.put(text, expression); } return expression; }