google-research / google-research/dex-lang
Add a way to (de)serialize Dex values
- Dominant language
- Haskell
- Stars
- 1.7k
- Forks
- 116
- PR merge metrics
- No merged PRs in 30d
Description
Trying out the dxbo as a way to get parameters into dex but it seems broken (or maybe just incomplete).
Any other ideas how to get parameters in? Load dxo works but is really slow.
```haskell
dat : (Fin 2 => Float & Float) = ([10.0, 20.0], 10.0)
dump dxbo "examples/bin-tmp.dxbo" dat
> Compiler bug!
> Please report this at github.com/google-research/dex-lang/issues
>
> Prelude.undefined
> CallStack (from HasCallStack):
> error, called at libraries/base/GHC/Err.hs:78:14 in base:GHC.Err
> undefined, called at src/lib/Serialize.hs:238:16 in dex-0.1.0.0-31vc1WNSYI0CcnFyEWUMxN:Serialize
```
Contributor guide
Research direction
Read src/lib/Serialize.hs around line 238 and compare the existing dxbo and dxo paths; reproduce the reported dump failure with the example value. Done means providing a supported way to serialize and deserialize Dex values, including the reported tuple/function value, while preserving the existing loading behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- haskell
- Domain
- compilers
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100