Skip to content

**Add robust error handling to link_frames macro using syn::LitStr and compile_error!** #34

@S0raWasTaken

Description

@S0raWasTaken

141-170: Add robust error handling to link_frames macro using syn::LitStr and compile_error!
link_frames uses multiple unwrap() calls without input validation, producing opaque proc macro panicked errors when:

  • No argument is provided
  • The argument isn't a string literal
  • File I/O, tar, or zstd operations fail

Replace the current token parsing with syn::LitStr parsing and emit compile_error! with clear diagnostics instead. This requires adding syn to Cargo.toml dependencies. Use parse_macro_input! to convert parse failures to compiler diagnostics automatically, and Error::new_spanned() for runtime failures like missing or invalid files.

This would do good as a new issue for a later PR.

Originally posted by @S0raWasTaken in #33 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions