Helgef wrote:obeeb. I do not assume you are a moron, I'm sorry you feel that way, I do not know what you know and don't, you asked me a direct question and I spent my time trying to answer it.
You started with the assumption that I don't know what I'm talking about, this is not a respectful way to treat a fellow human. I'm not going to be coy, I understand were you're coming from, most people who post here are not programmers and do in fact don't know what they are talking about however I happen to be one and I'm not used to be treated in such way. I have done the same thing when I tried to
help someone and it was completely wrong of me.
I came here with the goal of joining this community and help making it and Autohotkey better, this was the third(out of 3) frustrating interaction I had with a prominent member, @just me in this same thread and also masonjar(with him it wasn't even related to Autohotkey he just immediately assumed I'm generally an idiot who can't understand a simple sentence) being the other two. The one with you was marginally better than the other two but because it was the third I responded in the most aggressive way. I don't feel it was aggressive enough to warrant an apology but you're not responsible for other peoples' actions and it was unfair to you.
Helgef wrote:I want to know what my code does, if StrSplit can return an array almost twice as big as the number of elements in it this should be documented.
It seems you already know what the code does. I agree a more detailed documentation on the implementation would be great, but documenting is a tedious task, and the interested user can look in the source code, or ask in the help forum.
I only know because I saw this thread, it would've never occurred to me that
StrSplit returns an array with larger capacity then it needs to. This is not about me personally but about the quality of Autohotkey and it's documentation.
If you look at the original post:
pneumatic wrote:I'm guessing there is some technical reason for this, but it doesn't appear to be documented.
OP is not looking for a solution he's confused by the behavior, I find it terrible for Autohotkey and I don't think it's reasonable to expect people to look at the source code or come here(you can of course have a different opinion).
This can be fixed with one line of text in documentation or changed with one line of code, I will gladly submit a pull request with that line.
My biggest problem with all this and what made me jump in is @just me telling OP that he shouldn't have posted it. Even if the decision is to do nothing discouraging people to submit possible bugs is very bad for Autohotkey.
As to the rest of our disagreement I think we reached an understanding and for Autohotkey scripts I really think it doesn't make any difference what you do(as long as it's documented).
@just me
just me wrote:obeeb wrote:I don't know what you wanted to show with this, ..
I wanted to show you the costs of shrinking an array's capacity to fit the current number of key-value pairs after each change.
I will repeat myself one last time, doing something 100000
is not the same as doing it one time. This is not a good way to calculate the actual cost of the operation but for illustrative purposes let's do it anyway. It took 475 more milliseconds to create a new array 100000 times it means that 1 time took 475 / 100000 = 0.00475. This means
StrSplit will take a whooping 0.004 milliseconds more to complete.
The following was in the first line I wrote in this thread:
obeeb wrote:This provides a reasonable trade-off between simplicity, speed and size.
Using a little bit of deductive reasoning you can understand that I'm perfectly aware of the fact that there is a cost associated with it, why you wanted to show me something that I demonstrated to already know is beyond me.
You keep ignoring what I write and just comment on whatever you want so I will not bother to respond to the rest of your post, feel free to respond with an explanation about regular expressions or maybe
ImageSearch.