Skip to content

Conversation

HosseinYousefi
Copy link
Member

@HosseinYousefi HosseinYousefi commented Aug 25, 2025

  • Make Jni.env internal. We're not even using it in the JNIgen generated bindings. If users want to have a functionality here, they can open an issue. Making this internal heavily discourages use.
  • Remove a degree of flexibility for type class naming, any class named Foo will have two typeclasses: $Foo$NullableType$ and $Foo$Type$ including the classes in package:jni itself.
  • Remove the information about these symbols from jni_symbols.yaml (this will be changed again after jnigen transformation PR lands but wanted to land this first to make that PR a bit smaller)
  • Same change in JNIgen, this fixes [jnigen] Inner class generates $Type class and mixin class with identical names #2493.
  • Remove API leaks reported by the health bot ([jni] Fix the context when using multiple flutter engines #2494 (comment))
  • Rename JObjType to JType and make it not internal. JType used to be the union of both primitive types and non-primitive types, however that is rarely used and internal so renamed that to JTypeBase and renamed the commonly used JObjType to JType.

Copy link

github-actions bot commented Aug 25, 2025

PR Health

Breaking changes ✔️
Package Change Current Version New Version Needed Version Looking good?
jni Breaking 0.14.2 0.15.0-wip 0.15.0 ✔️
Changelog Entry ✔️
Package Changed Files

Changes to files need to be accounted for in their respective changelogs.

API leaks ✔️

The following packages contain symbols visible in the public API, but not exported by the library. Export these symbols or remove them from your publicly visible API.

Package Leaked API symbol Leaking sources
License Headers ✔️
// Copyright (c) 2025, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
Files
no missing headers

All source files should start with a license header.

Unrelated files missing license headers
Files
pkgs/objective_c/lib/src/ns_input_stream.dart

@HosseinYousefi HosseinYousefi marked this pull request as ready for review August 25, 2025 14:47
@HosseinYousefi HosseinYousefi force-pushed the change-typeclass-names branch from 9c7c786 to 6d13bef Compare August 25, 2025 15:06
@HosseinYousefi HosseinYousefi merged commit e77e0fe into main Aug 26, 2025
26 of 28 checks passed
@HosseinYousefi HosseinYousefi deleted the change-typeclass-names branch August 26, 2025 08:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[jnigen] Inner class generates $Type class and mixin class with identical names
2 participants