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

Concat bits #1052

Open
davetapley opened this issue Jul 21, 2023 · 0 comments
Open

Concat bits #1052

davetapley opened this issue Jul 21, 2023 · 0 comments

Comments

@davetapley
Copy link

I've got an esoteric format which some bit wrangling.

With help from #435 and #302 (comment) I've got it working here, but I find this ⬇️ a bit 🤢

instances:
  id:
    value: id_0 + (id_1 << 6) + (id_2.to_i << 12)
  value:
    value: val_0 + (val_1 << 5)

I suppose what I'm really doing is bit level concatenation.
Is there a better way without requiring a new method?

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

No branches or pull requests

1 participant