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

Reduce *Log b (n * b^f) to *Log b n + f #43

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

rowanG077
Copy link
Member

Fixes #42

I added the same reduction for FLog and CLog. Code is not super pretty since there are quite a bit of conversions between different type representations.

Copy link
Member

@martijnbastiaan martijnbastiaan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Core logic LGTM, mostly style+doc changes requested.

src/GHC/TypeLits/Extra/Solver/Unify.hs Outdated Show resolved Hide resolved
src/GHC/TypeLits/Extra/Solver/Operations.hs Outdated Show resolved Hide resolved
src/GHC/TypeLits/Extra/Solver/Operations.hs Show resolved Hide resolved
tests/Main.hs Outdated Show resolved Hide resolved
src/GHC/TypeLits/Extra/Solver/Operations.hs Outdated Show resolved Hide resolved
src/GHC/TypeLits/Extra/Solver/Operations.hs Outdated Show resolved Hide resolved
src/GHC/TypeLits/Extra/Solver/Operations.hs Outdated Show resolved Hide resolved
@rowanG077 rowanG077 changed the title Reduce *Log b (n * b^f) to *Log b n * f Reduce *Log b (n * b^f) to *Log b n + f Jul 11, 2022
@rowanG077
Copy link
Member Author

rowanG077 commented Jul 11, 2022

I fixed the requested change and also bumped the version to 0.4.4 in the cabal file.

@rowanG077 rowanG077 force-pushed the clog_commute_const branch 3 times, most recently from 3a7a1ba to f36f13f Compare July 12, 2022 01:20
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.

Could not deduce: CLog 2 (n * 2) ~ CLog 2 n + 1
3 participants