Skip to content
This repository has been archived by the owner on Sep 20, 2023. It is now read-only.

Fix #312: Refactor Builder to support possibility of failure. #349

Merged
merged 5 commits into from
Jun 15, 2017

Conversation

jship
Copy link
Member

@jship jship commented Jun 14, 2017

Started during ZuriHac 2017 with @Tiltman. Fixes #312.

@jship jship changed the title Refactor Builder to support possibility of failure. Fix #312: Refactor Builder to support possibility of failure. Jun 14, 2017
)
case runST $ Encoder.convertFromTo enc EncoderUTF8 (Vec.recast bytes) of
-- TODO: Don't swallow up specific error (second element of pair)
-- TODO: Confused why all this recasting is necessary. I "typed hole"-ed my way to get this function to compile. Feels like there should be a cleaner method.
Copy link
Member

Choose a reason for hiding this comment

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

we discussed this, and the original recast was a bad idea in the first place. so we'll sort this out with a overall of the decoder that I outlined in #353

In this case instead of recasting the array, you should downcast the Offset back to Word8 unit, so that you can splice the original array in 2 more efficiently.

@vincenthz
Copy link
Member

looking good guys ! thanks @jship @Tiltman !

I've raised #354 #353 #352 #351 that got uncovered while looking at the issues you raised (specially the recasting), well done !

@vincenthz vincenthz merged commit 13008ee into haskell-foundation:master Jun 15, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants