oxidecomputer / oxidecomputer/usdt

Support pointers to non-integer, non-Path types?

Open
#507 0 comments 0 reactions 1 assignee View on GitHub

@iximeow is already working on this.

Since Dec 5, 2025.

Dominant language
Rust
Stars
145
Forks
15
Avg merge
14m
Merged PRs (30d)
6

Description

I tried writing this probe today:

fn nvme_interrupt_completion_single(cq: *const CompQueue) {}

and got told Only pointers to integer types are supported because of my devious *const CompQueue. I assume the motivation here is that because repr(Rust) types have unstable layout and may change, it's really a bad idea to write a probe that depends on anything behind that pointer. But I really just want to distinguish the pointer arguments here, not read through them.

I've made the argument a usize for the time being, which is.. functionally enough. If I correctly understand why we don't support pointers to other types, maybe we could loosen that to allow any type that has #[repr(C)]? Then the error could suggest this, too. In this context it'd be totally fine to make CompQueue also repr(C) in support of debuggability, too, so that would probably be a net improvement!

(preemptively assigning myself mostly because I think the change would be small, but I don't plan on posting a PR quickly. If discussion gets settled and someone wants to Do The Thing, I heartily encourage stealing this from me :) )

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.