| 1236 | } |
| 1237 | |
| 1238 | static const CBMType *eval_ternary(JavaLSPContext *ctx, TSNode node) { |
| 1239 | TSNode then_n = ts_node_child_by_field_name(node, "consequence", 11); |
| 1240 | TSNode else_n = ts_node_child_by_field_name(node, "alternative", 11); |
| 1241 | const CBMType *t = java_eval_expr_type(ctx, then_n); |
| 1242 | if (t && !cbm_type_is_unknown(t)) |
| 1243 | return t; |
| 1244 | return java_eval_expr_type(ctx, else_n); |
| 1245 | } |
| 1246 | |
| 1247 | static bool is_string_concat(JavaLSPContext *ctx, TSNode node) { |
| 1248 | /* Either operand of type java.lang.String makes the whole expr a String. */ |
no test coverage detected