Skip to content

Refer to @NullMarked by name instead of by class literal. - #3258

Merged
copybara-service[bot] merged 0 commit into
masterfrom
test_453690086
Jun 8, 2022
Merged

copybara-service[bot] merged 0 commit into
masterfrom
test_453690086

Conversation

@copybara-service

Copy link
Copy Markdown
Contributor

Refer to @NullMarked by name instead of by class literal.

The open-source Error Prone release does not yet depend on the JSpecify annotations, and there's no reason for us to build in any kind of dependency on the class. (I'm not sure how strong a dependency "NullMarked.class" creates, but we might as well avoid it when we can.)

followup to 51da16e

@copybara-service
copybara-service Bot force-pushed the test_453690086 branch 2 times, most recently from 12c7917 to ec3ccff Compare June 8, 2022 16:19
@copybara-service copybara-service Bot closed this Jun 8, 2022
@copybara-service
copybara-service Bot merged commit d88561f into master Jun 8, 2022
@copybara-service
copybara-service Bot deleted the test_453690086 branch June 8, 2022 16:31
copybara-service Bot pushed a commit that referenced this pull request Apr 11, 2025
I don't think this is currently like [`javax.inject`](#3897), in which the dependency is actually important to have at runtime. But quite possibly it _would_ matter if we were to start to use `NullMarked.class` or something, as we [used to](#3258)? And anyway, I'd normally default to including everything that we can.

The exclusion that I added does appear to be necessary to avoid copying over the `META-INF/versions/9/OSGI-INF/MANIFEST.MF` file from JSpecify:

```
Manifest-Version: 1.0
Import-Package: java.lang,java.lang.annotation
Require-Capability: osgi.ee;filter:="(&(osgi.ee=JavaSE)(version=1.8))"
```
PiperOrigin-RevId: 746459384
copybara-service Bot pushed a commit that referenced this pull request Apr 11, 2025
I don't think this is currently like [`javax.inject`](#3897), in which the dependency is actually important to have at runtime. But quite possibly it _would_ matter if we were to start to use `NullMarked.class` or something, as we [used to](#3258)? And anyway, I'd normally default to including everything that we can.

The exclusion that I added does appear to be necessary to avoid copying over the `META-INF/versions/9/OSGI-INF/MANIFEST.MF` file from JSpecify:

```
Manifest-Version: 1.0
Import-Package: java.lang,java.lang.annotation
Require-Capability: osgi.ee;filter:="(&(osgi.ee=JavaSE)(version=1.8))"
```
PiperOrigin-RevId: 746527152
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants