josdejong
  • Joined on 2022-10-05
josdejong created branch feat/reflect-types in glen/math5 2024-10-11 10:15:24 +00:00
josdejong pushed to feat/reflect-types at glen/math5 2024-10-11 10:15:24 +00:00
91ed5fe83a chore: add reflected type information to the .js files in ./build
josdejong pushed to main at glen/math5 2024-10-11 07:34:21 +00:00
8cc6092d51 chore: make the build script work on Windows
josdejong commented on issue glen/typocomath#21 2024-10-07 16:13:00 +00:00
Alternatives for the $reflect macro at the bottom of the files

Thanks! From your comments at glen/math5#1 (comment) I understand that the builder pattern is indeed necessary. So no need to work this idea out…

josdejong closed issue glen/typocomath#21 2024-10-07 16:13:00 +00:00
Alternatives for the $reflect macro at the bottom of the files
josdejong commented on issue glen/math5#1 2024-10-07 16:06:14 +00:00
math5 vs dispatch_refactor approach

Thoughts about a build step to generate types: in the current mathjs there is also a build step in place which generates files. In ./src/entry/ there will appear files named *.generated.js.…

josdejong commented on issue glen/math5#1 2024-10-07 16:01:37 +00:00
math5 vs dispatch_refactor approach

to me by far the most powerful argument is that math5 actually found typing violations in the implementation code that dispatcher_refactor did not.

Agree, you're right, that is a strong…

josdejong opened issue glen/typocomath#21 2024-10-03 13:45:36 +00:00
Alternatives for the $reflect macro at the bottom of the files
josdejong opened issue glen/math5#1 2024-10-03 13:39:54 +00:00
math5 vs dispatch_refactor approach
josdejong commented on issue glen/typocomath#20 2023-10-27 07:13:22 +00:00
Planned minimal path to operable Dispatcher

Thanks Glen for writing out this plan👍

josdejong commented on issue glen/typocomath#19 2023-10-24 08:21:29 +00:00
Change Dispatcher into a builder function that returns a plain object (of lots of function properties)

I feel we need a solution that will automatically allow <T>add(Complex<T>, T) via the automatic conversion

Yes, totally agree!

Options (2/2b) still look feasible, although yes, they…

josdejong commented on issue glen/typocomath#19 2023-10-23 18:41:40 +00:00
Change Dispatcher into a builder function that returns a plain object (of lots of function properties)

Having to specify whether to $reflect generic or not is indeed not ideal but acceptable at least for now. I agree on parking $$typeMetadata! for now, it's not a magic solution.

My idea is…

josdejong commented on issue glen/typocomath#19 2023-10-20 14:25:02 +00:00
Change Dispatcher into a builder function that returns a plain object (of lots of function properties)

Hmm, all these new TS issues suck, we definitely don't want that.

The $$typeMetadata! sounds promising!

In my head, Typocomath is an extension on top of Pocomath. I think the step to…

josdejong commented on issue glen/typocomath#10 2023-10-20 13:56:49 +00:00
Trajectory for Typocomath

Yes, I'm reading all of it right now :)

josdejong commented on issue glen/typocomath#10 2023-10-20 12:22:22 +00:00
Trajectory for Typocomath

Ok I'll look into the .reflectedType issue next week. And indeed it may not be an issue in practice since it's an under the hood thing, I'll keep that in mind.

The lazy approach of the…

josdejong commented on issue glen/typocomath#18 2023-10-18 13:23:45 +00:00
feat: Capture generic parameter of an implementation, if there is one

In 6bfd06cafb I've added code to extract the generic parameter from the reflectedType.

josdejong pushed to main at glen/typocomath 2023-10-18 13:22:28 +00:00
6bfd06cafb feat: extract generic parameter from the reflectedType (see #18)
josdejong commented on issue glen/typocomath#10 2023-10-18 13:13:04 +00:00
Trajectory for Typocomath

That's good news!

I've checked out the latest version of main, and can successfully run pnpm go. There was one typo export type FunctionDef {, I've changed that to `export type…

josdejong pushed to main at glen/typocomath 2023-10-18 13:12:01 +00:00
0cdc9aba78 chore: fix typo in type definition of FunctionDef
josdejong commented on issue glen/typocomath#19 2023-10-18 12:44:51 +00:00
Change Dispatcher into a builder function that returns a plain object (of lots of function properties)

If we implement the Dispatcher as a class, we should not attach functions to itself, then we mix things up.

However, the end user is probably not interested in a verbose `const math = new…