Skip to content
This repository was archived by the owner on May 1, 2020. It is now read-only.
This repository was archived by the owner on May 1, 2020. It is now read-only.

Specify nullability type with package-info.java files #242

@squall2022

Description

@squall2022

Using j2objc and Swift 3 generate a lot of warnings because of nullability not specified, like explained here : https://groups.google.com/forum/#!topic/j2objc-discuss/zNt2eMcLvlY

Addind package-info.java files to squidb would be very helpful, see Tom Ball suggestion :

For your project's Java sources, you can define the correct nullability annotations and j2objc will translate them into Objective C annotations (be sure and include jsr305.jar to the j2objc classpath). This has the advantage of reducing the amount of casting that needs to be done when accessing Java classes in Swift. The Guava team recently did this, and simplified that effort by putting the default annotations in each package's package-info.java files (creating them, in many cases). That way, separate nullability annotations only needed to be added to individual source files when their API deviated from those defaults.

Thanks

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions