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

Function used as a type but is in fact a term #95

Open
NeuralCoder3 opened this issue Oct 4, 2022 · 2 comments
Open

Function used as a type but is in fact a term #95

NeuralCoder3 opened this issue Oct 4, 2022 · 2 comments
Labels
enhancement New feature or request

Comments

@NeuralCoder3
Copy link
Collaborator

Observed in lit/direct/ds2cps_ax_cps2ds_dependent_short.thorin
Command line: ./build/bin/thorin -d direct -d tool ./lit/direct/ds2cps_ax_cps2ds_dependent_short.thorin --output-thorin -

Issue:

:4294967295: error: 'Π n_167425: .Nat → .infer (<nullptr>)' used as a type but is in fact a term 

High-level description:
We constructed a wrapper around .Idx

Suspected problem:
Idx has problems with the duality of fundamental integer and being applied as a function.

@NeuralCoder3 NeuralCoder3 mentioned this issue Oct 4, 2022
13 tasks
@leissa
Copy link
Member

leissa commented Oct 12, 2022

Suffers also from #106.

  • changing the literal to 0:.Idx n and
  • adding a return type to lam_idx fixes the test case.

see also #103:

Work is underway to add type inference.

@leissa leissa added the enhancement New feature or request label Oct 12, 2022
@leissa
Copy link
Member

leissa commented Oct 12, 2022

Marked as enhancement as the only remaining real problem is the type inference that is not yet properly implemented.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants