You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues-all@impala.apache.org by "ASF subversion and git services (Jira)" <ji...@apache.org> on 2021/11/23 05:23:00 UTC

[jira] [Commented] (IMPALA-11031) Listmap.getIndex() name is misleading

    [ https://issues.apache.org/jira/browse/IMPALA-11031?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17447780#comment-17447780 ] 

ASF subversion and git services commented on IMPALA-11031:
----------------------------------------------------------

Commit c3f2ecc95f217ca9b1c475c44f524bb2fbab5545 in impala's branch refs/heads/master from Zoltan Borok-Nagy
[ https://gitbox.apache.org/repos/asf?p=impala.git;h=c3f2ecc ]

IMPALA-11031: Listmap.getIndex() name is misleading

Listmap.getIndex(t) modifies the ListMap object when there is
no mapping for 't'. Hence the name of it is very misleading as
the reader wouldn't expect modifications from simple getters.

This patch renames it to getOrAddIndex().

Change-Id: I689dfb67e1a9104812489d6299ed43446d2fcae8
Reviewed-on: http://gerrit.cloudera.org:8080/18042
Reviewed-by: Impala Public Jenkins <im...@cloudera.com>
Tested-by: Impala Public Jenkins <im...@cloudera.com>


> Listmap.getIndex() name is misleading
> -------------------------------------
>
>                 Key: IMPALA-11031
>                 URL: https://issues.apache.org/jira/browse/IMPALA-11031
>             Project: IMPALA
>          Issue Type: Improvement
>          Components: Frontend
>            Reporter: Zoltán Borók-Nagy
>            Assignee: Zoltán Borók-Nagy
>            Priority: Major
>              Labels: ramp-up
>
> Listmap.getIndex(t) modifies the ListMap object when there is no mapping for 't'.
> Hence the name of it is very misleading as the reader wouldn't expect modifications from simple getters.
> Probably we should just rename it to getOrAddIndex().



--
This message was sent by Atlassian Jira
(v8.20.1#820001)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-all-unsubscribe@impala.apache.org
For additional commands, e-mail: issues-all-help@impala.apache.org