Skip to content

Proc macros should limit symbol exports #99909

Closed
@bjorn3

Description

@bjorn3

readelf --wide --syms build/x86_64-unknown-linux-gnu/stage0-rustc/release/deps/libproc_macro_hack-cdb4209108fe6fa9.so | grep GLOBAL | grep -v UND | wc -l shows over 5500 exported symbols. It should limit exports to only those that are used, just like for cdylib's. This should decrease the size of proc macros by allowing more effecting garbage collection of dead code.

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-linkageArea: linking into static, shared libraries and binariesA-proc-macrosArea: Procedural macrosI-heavyIssue: Problems and improvements with respect to binary size of generated code.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions