You are viewing a plain text version of this content. The canonical link for it is here.
Posted to oak-issues@jackrabbit.apache.org by "Konrad Windszus (Jira)" <ji...@apache.org> on 2022/07/18 11:34:00 UTC
[jira] [Updated] (OAK-9844) Nullness annotations must not be used on primitive types
[ https://issues.apache.org/jira/browse/OAK-9844?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Konrad Windszus updated OAK-9844:
---------------------------------
Description:
Primitive types can never be {{null}} therefore using any nullness annotation on them is invalid. Also to prevent that an array is null the syntax needs to be
{code}
<element type> <nullness annotation> [], e.g. byte @NotNull []
{code}
Something like e.g. {{@NotNull byte []}} is invalid (compare with https://stackoverflow.com/questions/62066166/string-notnull-syntax-causes-notnull-not-applicable-to-type-use-in-in).
was:
Primitive types can never be {{null}} therefore using any nullness annotation on them is invalid. Also to prevent that an array is null the syntax needs to be
{code}
<element type> <nullness annotation> [], e.g. byte @NotNull []
{code}
Something like e.g. @NotNull byte [] is invalid (compare with https://stackoverflow.com/questions/62066166/string-notnull-syntax-causes-notnull-not-applicable-to-type-use-in-in).
> Nullness annotations must not be used on primitive types
> --------------------------------------------------------
>
> Key: OAK-9844
> URL: https://issues.apache.org/jira/browse/OAK-9844
> Project: Jackrabbit Oak
> Issue Type: Improvement
> Components: segment-tar
> Reporter: Konrad Windszus
> Assignee: Konrad Windszus
> Priority: Major
>
> Primitive types can never be {{null}} therefore using any nullness annotation on them is invalid. Also to prevent that an array is null the syntax needs to be
> {code}
> <element type> <nullness annotation> [], e.g. byte @NotNull []
> {code}
> Something like e.g. {{@NotNull byte []}} is invalid (compare with https://stackoverflow.com/questions/62066166/string-notnull-syntax-causes-notnull-not-applicable-to-type-use-in-in).
--
This message was sent by Atlassian Jira
(v8.20.10#820010)