Skip to content
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

More reified utilities #95

Merged
merged 21 commits into from
Oct 10, 2024
Merged

More reified utilities #95

merged 21 commits into from
Oct 10, 2024

Conversation

poteat
Copy link
Owner

@poteat poteat commented Oct 10, 2024

The most interesting part of this pull request is an optimization I had to perform for lazyPipe - for some indiscernible reason, this improves performance for pipes of complex operations - my theory is that it's somehow deferring evaluation, or improving what types can be cached.

  • Reify NaturalNumber.Add to a value-level function.
  • Add Kind.JuxtN to juxt kinds with an arity of greater than one.
  • Add NaturalNumber.FromHex to convert a hexadecimal string to a decimal number.
  • Add NaturalNumber.ToHex to convert a decimal number to a hexadecimal string.
  • Reify String.FromList to a value-level function.
  • Add List.PadStart to pad a list to a desired length with a padding value.
  • Add List.PadEnd to pad a list to a desired length with a padding value.
  • Add String.PadStart to pad a string to a desired length with a padding character.
  • Add String.PadEnd to pad a string to a desired length with a padding character.
  • Improve inference efficiency of List.Collate and Kind.LazyPipe.

@poteat poteat merged commit ecefc8c into main Oct 10, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant