-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Major Improvements 2 #12
Conversation
I hope the generation code could be rewritten such that the files are transformed and emitted using the API instead of printing the statements one by one by text. This way it will be far easier to maintain the code, and the code can even be written such that we need not to repeat the documentations in the |
Do you wish that I commit the VSCode |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you!
This way it will be far easier to maintain the code, and the code can even be written such that we need not to repeat the documentations in the lib files.
Yes that'd be nice, although I haven't come up with a nice way of achieving this 🤕
Do you wish that I commit the VSCode launch.json for debugging?
Yes that's fine 🙂
Thank you, sorry for being late 🤕 |
Don't forget to publish a new release whenever you're free! 😉 |
Sorry for another PR! Unlike the previous (closed) one, this PR should be mergeable without any external actions required.
This PR brings type safety to typed array and extends #7 to the
find
andfindIndex
methods.Introduces a single utility type
CheckNonNullable
, which is unnecessary with the type ofo
being replaced to{}
after TypeScript 4.8 due to microsoft/TypeScript#49119.The first parameter of
{Array, %TypedArray%}.from
are all renamed tosource
because writingiterable: Iterable<T> | ArrayLike<T>
is kind of misleading, and it is also namedsource
in the spec text.This PR does not include tests for methods with only
thisArg
changes, or it will be superfluous.I think some bugs like
this: void
in the original library files should be reported to TypeScript, and I am surprised that the return type of the first parameter of the%TypedArray%.prototype
methods in the originales2020.bigint.d.ts
file are already typedboolean
, in contrast to theArray.prototype
methods ines5.d.ts
.