Title: Should Stream.iteratorStream be deprecated? · Issue #304 · functionaljava/functionaljava · GitHub
Open Graph Title: Should Stream.iteratorStream be deprecated? · Issue #304 · functionaljava/functionaljava
X Title: Should Stream.iteratorStream be deprecated? · Issue #304 · functionaljava/functionaljava
Description: The following static method in Stream is unsafe. public static Stream iteratorStream(final Iterator it) Due to Stream's use of WeakRef, when you visit the elements of Stream you can get a different result on the 2nd pass. (Inte...
Open Graph Description: The following static method in Stream is unsafe. public static Stream iteratorStream(final Iterator it) Due to Stream's use of WeakRef, when you visit the elements of Stream you can get a...
X Description: The following static method in Stream is unsafe. public static <A> Stream<A> iteratorStream(final Iterator<A> it) Due to Stream's use of WeakRef, when you visit the elements o...
Opengraph URL: https://github.com/functionaljava/functionaljava/issues/304
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Should Stream.iteratorStream be deprecated?","articleBody":"The following static method in Stream is unsafe.\r\n\r\n```public static \u003cA> Stream\u003cA> iteratorStream(final Iterator\u003cA> it)```\r\n\r\nDue to Stream's use of ```WeakRef```, when you visit the elements of ```Stream``` you can get a different result on the 2nd pass. (Internal mutable iterator keeps its state while cache is cleared)\r\n\r\nI think this method should be avoided at all times because its behavior is unpredictable.","author":{"url":"https://github.com/clinuxrulz","@type":"Person","name":"clinuxrulz"},"datePublished":"2016-11-09T01:37:53Z","url":"https://github.com/functionaljava/functionaljava/issues/304"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:b894cc5b-a644-2789-1823-b65f06632e30 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | DA90:3CFBC:A5BDBB:E28EFB:6AFBDB31 |
| html-safe-nonce | f9ee3d261be3110932f16006b6e999ff36656921349b1d327be7e8d3c9f057c1 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEQTkwOjNDRkJDOkE1QkRCQjpFMjhFRkI6NkFGQkRCMzEiLCJ2aXNpdG9yX2lkIjoiMTU0NzkxMzc1Mjk0MDg5NTAyNSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | e2762c9066dc64e87e9db41b5f4774a6c2fb1675839af73bbccccfb615cb9690 |
| hovercard-subject-tag | issue:188149241 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/functionaljava/functionaljava/304/issue_layout |
| twitter:image | https://opengraph.githubassets.com/7056a8838c9da1db32d2b0e825fac54e37da7d678ec7d86d56c7a31b37f20d3e/functionaljava/functionaljava/issues/304 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/7056a8838c9da1db32d2b0e825fac54e37da7d678ec7d86d56c7a31b37f20d3e/functionaljava/functionaljava/issues/304 |
| og:image:alt | The following static method in Stream is unsafe. public static Stream iteratorStream(final Iterator it) Due to Stream's use of WeakRef, when you visit the elements of Stream you can get a... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | clinuxrulz |
| hostname | github.com |
| expected-hostname | github.com |
| None | 18742cb872ec73544356e60359266b67aafece70c4ce008042e06227924cdd07 |
| turbo-cache-control | no-preview |
| go-import | github.com/functionaljava/functionaljava git https://github.com/functionaljava/functionaljava.git |
| octolytics-dimension-user_id | 458836 |
| octolytics-dimension-user_login | functionaljava |
| octolytics-dimension-repository_id | 1033614 |
| octolytics-dimension-repository_nwo | functionaljava/functionaljava |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 1033614 |
| octolytics-dimension-repository_network_root_nwo | functionaljava/functionaljava |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 820be804f18e1ef3940bd74a00d41d73d02e2b91 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width