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

New option to record renamings in a .h file #357

Merged
merged 4 commits into from
Nov 2, 2023
Merged

Commits on Jun 26, 2023

  1. New option to record renamings in a .h file

    This simplifies name handling in the situation where a library and a
    client are both verified projects, extracting separately, and linking
    together.
    
    Consider Library.A.Base1.fst and Library.A.Base2.fst, extracted with:
    
    -bundle Library.A.Base1+Library.A.Base2=[rename=Library_A,rename-prefix]
    
    The client, in order to use the library, passes `-library Library.*`,
    but without any further options, must also replicate the bundle above in
    order to generate code that references Library_A_foobar instead of
    Library_A_Base1_foobar; note that the latter would be a linking error.
    
    This is onerous: the library must export its bundle options in a format
    consumable by the client; furthermore, the client is bound by the bundle
    choices of the library and has no way of grouping, say, in Library.h all
    of the `extern` declarations pertaining to Library while also at the
    same time respecting the renamings enabled by rename-prefix.
    
    This PR offers an alternate route: the library records in a
    krmlrenamings.h file all of the name changes that deviate from the
    default, e.g.
    
    ```
    ```
    
    This allows the client to replace a litany of bundle/rename options with
    a mere `-add-include '"library/clients/krmlrenamings.h"'`
    msprotz committed Jun 26, 2023
    Configuration menu
    Copy the full SHA
    abc21c3 View commit details
    Browse the repository at this point in the history
  2. Fixup handling of macro names

    msprotz committed Jun 26, 2023
    Configuration menu
    Copy the full SHA
    6c848cd View commit details
    Browse the repository at this point in the history

Commits on Jun 29, 2023

  1. Another simplification

    msprotz committed Jun 29, 2023
    Configuration menu
    Copy the full SHA
    ea99c83 View commit details
    Browse the repository at this point in the history

Commits on Oct 26, 2023

  1. Configuration menu
    Copy the full SHA
    af4acdb View commit details
    Browse the repository at this point in the history