Skip to content

make #[pg_guard] less internally confusing #1723

Open
@workingjubilee

Description

@workingjubilee

I had a talk with @eeeebbbbrrrr about FFI stuff in the context of #1661.

During that conversation, we made mistakes/were confused on which of the two major functions (pg_guard_ffi_boundary and pgrx_extern_c_guard) are used for which case (decorating an extern "C" fn rust_callable_by_c(Args) -> Ret { expr } and decorating an extern "C" { fn c_callable_by_rust(c_type) -> c_type; } binding declaration) like three times in that conversation. The reason it was only three was that I was talking slowly because I was confused and still only halfway through my second coffee.

We need to make sure which-is-which is eye-bleedingly clear to ourselves. At minimum, via documentation (which could also cover #1406).

Metadata

Metadata

Assignees

No one assigned

    Labels

    docsImprovements or additions to documentationrefactorChanges would be considered a refactor of existing functionality.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions