Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > gnu.bash.bug > #16279
| From | Chet Ramey <chet.ramey@case.edu> |
|---|---|
| Newsgroups | gnu.bash.bug |
| Subject | Re: [PATCH] Implement rehashing for associative arrays (Re: speeding up hash_search?) |
| Date | 2020-05-04 16:12 -0400 |
| Organization | ITS, Case Western Reserve University |
| Message-ID | <mailman.2090.1588623164.3066.bug-bash@gnu.org> (permalink) |
| References | (6 earlier) <CAFLRLk_KetD6+-o2HOdP6ueKuynu_7Yn6ARZ_HbC4QC=99-WcA@mail.gmail.com> <CALv3B7YTnS8R8D=dYbbOUFROOvhSQ1gfc_ETT+cikp3onBMR1A@mail.gmail.com> <61c51c64-d17e-6ea0-6ace-0c3365ef2299@case.edu> <CALv3B7Yrg7bDO0eViSTBWad56vw_dGnnXtMRa9ofYysiAiYJbA@mail.gmail.com> <68012573-75b3-9de7-c85c-ba57699295b8@case.edu> |
On 4/20/20 5:12 PM, George Jones wrote: > No real opinion on syntax. > > Using something existing: > > declare -A foo[SIZE] > > seems sensible, especially if there was no semantic meaning (I'm not a fan > of syntax without semantics .... clutter). It's been there forever for ksh88 compatibility, but bash doesn't use it for anything (and I suspect ksh93 doesn't either). > Big thing is that the new stuff for fringe new pathologic use cases (mine) > should not have negative impact (huge buffer preallocation) on the existing > ?30 years? of users/scripts. I don't think there are very many, if any, scripts out there using that syntax. It's never had any semantic meaning. > Some docs on how the SIZE is used (hint for preallocation of hash table > size, not hard limit on number of entries) probably also in order. Sure, if the size argument ever meant something, I would document it. :-) Chet -- ``The lyf so short, the craft so long to lerne.'' - Chaucer ``Ars longa, vita brevis'' - Hippocrates Chet Ramey, UTech, CWRU chet@case.edu http://tiswww.cwru.edu/~chet/
Back to gnu.bash.bug | Previous | Next | Find similar
Re: [PATCH] Implement rehashing for associative arrays (Re: speeding up hash_search?) Chet Ramey <chet.ramey@case.edu> - 2020-05-04 16:12 -0400
csiph-web