helloadhavan/github_issues huggingface dataset:
Repository: vercel/next.js
Pull request: Trace upload: add git and environment info

This adds the following to uploaded trace data:

- Git branch/ref name
- Whether the trace was uploaded from a Vercel environment
- Prefers Vercel git environment variable data over running git

Test Plan: Ran a manual test app with EXPERIMENTAL_FLAGS_DEBUG=1, set the corresponding environment variables and confirmed they were reflected


Changed files:
filename: packages/next/src/trace/trace-uploader.ts
patch: @@ -99,8 +99,10 @@ interface TraceEvent {
 interface TraceMetadata {
   anonymousId: string
   arch: string
+  branch: string
   commit: string
   cpus: number
+  isVercelEnvironment: boolean
   isTurboSession: boolean
   mode: string
   nextVersion: string
@@ -126,14 +128,23 @@ interface TraceMetadata {
   )
   const pkgName = projectPkgJson.name
 
-  const commit = child_process
-    .spawnSync(
-      os.platform() === 'win32' ? 'git.exe' : 'git',
-      ['rev-parse', 'HEAD'],
-      { shell: true }
-    )
-    .stdout.toString()
-    .trimEnd()
+  const git = os.platform() === 'win32' ? 'git.exe' : 'git'
+
+  const isVercelEnvironment = !!process.env.VERCEL
+
+  const commit =
+    process.env.VERCEL_GIT_COMMIT_SHA ||
+    child_process
+      .spawnSync(git, ['rev-parse', 'HEAD'])
+      .stdout.toString()
+      .trimEnd()
+
+  const branch =
+    process.env.VERCEL_GIT_COMMIT_REF ||
+    child_process
+      .spawnSync(git, ['rev-parse', '--abbrev-ref', 'HEAD'])
+      .stdout.toString()
+      .trimEnd()
 
   const readLineInterface = createInterface({
     input: createReadStream(path.join(projectDir, distDir, 'trace')),
@@ -207,8 +218,10 @@ interface TraceMetadata {
     metadata: {
       anonymousId,
       arch: os.arch(),
+      branch,
       commit,
       cpus: os.cpus().length,
+      isVercelEnvironment,
       isTurboSession,
       mode,
       nextVersion,
Repository: facebook/react
Pull request: [DevTools] Batch updates when updating component filters

Stacked on https://github.com/facebook/react/pull/35107

We used to flush operations between unmounting each root and remounting each root. This could lead to focus or selection loss when the focused/selected element was temporarily removed while we were mounting the root again in the backend. Notably when keyboard navigating through the Activity list and focusing on a specific Activity. We'd flush after each root was unmounted leading to an unnmount of the Activity list since no more named Activities existed.

Looks like a leftover from when flushing operations was tied to a root. If this leads to crashes due to operations sent being too large, we should implement some streaming approach where the frontend can decide if it wants to flush between each chunk (operations for one root) or at the end.

Alternatively we could also flush after processing each root when processing unmount+mount  i.e.

```
unmount(1)
mount(1)
flush()

unmount(2)
mount(2)
flush()
```

instead of 
```
unmount(1)
flush()
unmount(2)
flush()

mount(1)
flush()
mount(2)
flush()
```

Changed files:
filename: packages/react-devtools-shared/src/backend/fiber/renderer.js
patch: @@ -1576,7 +1576,6 @@ export function attach(
       currentRoot = rootInstance;
       unmountInstanceRecursively(rootInstance);
       rootToFiberInstanceMap.delete(root);
-      flushPendingEvents();
       currentRoot = (null: any);
     });
 
@@ -1646,7 +1645,6 @@ export function attach(
       currentRoot = newRoot;
       setRootPseudoKey(currentRoot.id, root.current);
       mountFiberRecursively(root.current, false);
-      flushPendingEvents();
       currentRoot = (null: any);
     });
 
@@ -5751,11 +5749,12 @@ export function attach(
 
         mountFiberRecursively(root.current, false);
 
-        flushPendingEvents();
-
-        needsToFlushComponentLogs = false;
         currentRoot = (null: any);
       });
+
+      flushPendingEvents();
+
+      needsToFlushComponentLogs = false;
     }
   }
Repository: electron/electron
Pull request: ci: only run auto close on PRs targeting main branch

#### Description of Change
- Followup to #50348.  That PR unfortunately autoclosed trop initiated backports since those use a simpler PR description.  This PR changes the auto close logic to only target main.
<!--
Thank you for your Pull Request. Please provide a description above and review
the requirements below.

Contributors guide: https://github.com/electron/electron/blob/main/CONTRIBUTING.md

NOTE: PRS submitted without this template will be automatically closed.
-->

#### Checklist
<!-- Remove items that do not apply. For completed items, change [ ] to [x]. -->

- [x] PR description included
- [x] [PR release notes](https://github.com/electron/clerk/blob/main/README.md) describe the change in a way relevant to app developers, and are [capitalized, punctuated, and past tense](https://github.com/electron/clerk/blob/main/README.md#examples).

#### Release Notes

Notes: <!-- Please add a one-line description for app developers to read in the release notes, or 'none' if no notes relevant to app developers. Examples and help on special cases: https://github.com/electron/clerk/blob/main/README.md#examples -->none


Changed files:
filename: .github/workflows/pr-template-check.yml
patch: @@ -3,6 +3,8 @@ name: PR Template Check
 on:
   pull_request_target:
     types: [opened, edited]
+    branches:
+      - main
 
 permissions: {}
Repository: facebook/react
Pull request: [compiler] _exp version of ValidateNoDerivedComputationsInEffects take precedence over stable version when enabled


Summary:
We should only run one version of the validation. I think it makes sense that if the exp version is enable it takes precedence over the stable one

---
[//]: # (BEGIN SAPLING FOOTER)
Stack created with [Sapling](https://sapling-scm.com). Best reviewed with [ReviewStack](https://reviewstack.dev/facebook/react/pull/35099).
* __->__ #35099
* #35100

Changed files:
filename: compiler/packages/babel-plugin-react-compiler/src/Entrypoint/Pipeline.ts
patch: @@ -272,12 +272,10 @@ function runWithEnvironment(
       validateNoSetStateInRender(hir).unwrap();
     }
 
-    if (env.config.validateNoDerivedComputationsInEffects) {
-      validateNoDerivedComputationsInEffects(hir);
-    }
-
     if (env.config.validateNoDerivedComputationsInEffects_exp) {
       env.logErrors(validateNoDerivedComputationsInEffects_exp(hir));
+    } else if (env.config.validateNoDerivedComputationsInEffects) {
+      validateNoDerivedComputationsInEffects(hir);
     }
 
     if (env.config.validateNoSetStateInEffects) {
Repository: rust-lang/rust
Pull request: Normalize rustc path prefix when testing `-Z track-diagnostics`

Fixes https://github.com/rust-lang/rust/issues/154392



Changed files:
filename: tests/rustdoc-ui/track-diagnostics.rs
patch: @@ -3,6 +3,7 @@
 // Normalize the emitted location so this doesn't need
 // updating everytime someone adds or removes a line.
 //@ normalize-stderr: ".rs:\d+:\d+" -> ".rs:LL:CC"
+//@ normalize-stderr: "/rustc(?:-dev)?/[a-z0-9.]+/" -> ""
 
 struct A;
 struct B;
Repository: huggingface/transformers
Pull request: Fix Llava tests for torch too!

I made an oversight in the fix at #43981 - I didn't realize the dim order changed for torch, so the test was still flaky for torch tensors. The fix reduced the flaky frequency a lot so I thought it had been fixed, but actually it's still there, just failing around 0.25% of the time.

I tested this PR with 1000 runs and they all passed, so hopefully this is the end of it! cc @zucchini-nlp 

Changed files:
filename: tests/models/llava/test_image_processing_llava.py
patch: @@ -225,10 +225,12 @@ def pad_to_square_original(
                 np.testing.assert_allclose(padded_image, padded_image_original)
 
             # background color length should match channel length
-            if image_inputs[0].shape[0] == image_inputs[0].shape[1]:
+            # torch shape is (C, H, W), numpy shape is (H, W, C)
+            h_idx, w_idx = (1, 2) if torchify else (0, 1)
+            if image_inputs[0].shape[h_idx] == image_inputs[0].shape[w_idx]:
                 # This avoids a source of test flakiness - if the image is already square
                 # no padding is done and background colour is not checked.
-                return
+                continue
 
             with self.assertRaises(ValueError):
                 padded_image = image_processor.pad_to_square(image_inputs[0], background_color=(122, 104))
Repository: electron/electron
Pull request: fix: ensure WebContents::WasShown runs when window is shown

Backport of #49421

See that PR for details.


Notes: Fixed window freeze when failing to enter/exit fullscreen on macOS.

Changed files:
filename: shell/browser/api/electron_api_browser_window.cc
patch: @@ -280,16 +280,22 @@ v8::Local<v8::Value> BrowserWindow::GetWebContents(v8::Isolate* isolate) {
 }
 
 void BrowserWindow::OnWindowShow() {
+  if (!web_contents_shown_) {
+    web_contents()->WasShown();
+    web_contents_shown_ = true;
+  }
   BaseWindow::OnWindowShow();
 }
 
 void BrowserWindow::OnWindowHide() {
   web_contents()->WasOccluded();
+  web_contents_shown_ = false;
   BaseWindow::OnWindowHide();
 }
 
 void BrowserWindow::Show() {
   web_contents()->WasShown();
+  web_contents_shown_ = true;
   BaseWindow::Show();
 }
 
@@ -298,6 +304,7 @@ void BrowserWindow::ShowInactive() {
   if (IsModal())
     return;
   web_contents()->WasShown();
+  web_contents_shown_ = true;
   BaseWindow::ShowInactive();
 }
 

filename: shell/browser/api/electron_api_browser_window.h
patch: @@ -80,6 +80,7 @@ class BrowserWindow : public BaseWindow,
   // Helpers.
 
   v8::Global<v8::Value> web_contents_;
+  bool web_contents_shown_ = false;
   v8::Global<v8::Value> web_contents_view_;
   base::WeakPtr<api::WebContents> api_web_contents_;
Repository: ollama/ollama
Pull request: Update README.md

Correct Markdown syntax for Swollama GitHub and DocC documentation links

Changed files:
filename: README.md
patch: @@ -555,7 +555,7 @@ See the [API documentation](./docs/api.md) for all endpoints.
 - [Parakeet](https://github.com/parakeet-nest/parakeet) is a GoLang library, made to simplify the development of small generative AI applications with Ollama.
 - [Haverscript](https://github.com/andygill/haverscript) with [examples](https://github.com/andygill/haverscript/tree/main/examples)
 - [Ollama for Swift](https://github.com/mattt/ollama-swift)
-- [Swollama for Swift]([https://github.com/marcusziade/Swollama](https://github.com/guitaripod/Swollama) with [DocC]( https://guitaripod.github.io/Swollama/documentation/swollama)
+- [Swollama for Swift](https://github.com/guitaripod/Swollama) with [DocC](https://guitaripod.github.io/Swollama/documentation/swollama)
 - [GoLamify](https://github.com/prasad89/golamify)
 - [Ollama for Haskell](https://github.com/tusharad/ollama-haskell)
 - [multi-llm-ts](https://github.com/nbonamy/multi-llm-ts) (A Typescript/JavaScript library allowing access to different LLM in a unified API)
Repository: facebook/react
Pull request: [compiler] Prevent local state source variables from depending on other state


Summary:
When a local state is created sometimes it uses a `prop` or even other local state for its initial value.

This value is only relevant on first render so we shouldn't consider it part of our data flow

Test Plan:
Added tests


Changed files:
filename: compiler/packages/babel-plugin-react-compiler/src/Validation/ValidateNoDerivedComputationsInEffects_exp.ts
patch: @@ -358,8 +358,14 @@ function recordInstructionDerivations(
         context.effects.add(effectFunction.loweredFunc.func);
       }
     } else if (isUseStateType(lvalue.identifier) && value.args.length > 0) {
-      isSource = true;
-      typeOfValue = joinValue(typeOfValue, 'fromState');
+      typeOfValue = 'fromState';
+      context.derivationCache.addDerivationEntry(
+        lvalue,
+        new Set(),
+        typeOfValue,
+        true,
+      );
+      return;
     }
   }
 

filename: compiler/packages/babel-plugin-react-compiler/src/__tests__/fixtures/compiler/effect-derived-computations/usestate-derived-from-prop-no-show-in-data-flow-tree.expect.md
patch: @@ -0,0 +1,59 @@
+
+## Input
+
+```javascript
+// @validateNoDerivedComputationsInEffects_exp
+
+function Component({ prop }) {
+  const [s, setS] = useState(prop)
+  const [second, setSecond] = useState(prop)
+
+  useEffect(() => {
+    setS(second)
+  }, [second])
+
+  return <div>{s}</div>
+}
+
+```
+
+## Code
+
+```javascript
+import { c as _c } from "react/compiler-runtime"; // @validateNoDerivedComputationsInEffects_exp
+
+function Component(t0) {
+  const $ = _c(5);
+  const { prop } = t0;
+  const [s, setS] = useState(prop);
+  const [second] = useState(prop);
+  let t1;
+  let t2;
+  if ($[0] !== second) {
+    t1 = () => {
+      setS(second);
+    };
+    t2 = [second];
+    $[0] = second;
+    $[1] = t1;
+    $[2] = t2;
+  } else {
+    t1 = $[1];
+    t2 = $[2];
+  }
+  useEffect(t1, t2);
+  let t3;
+  if ($[3] !== s) {
+    t3 = <div>{s}</div>;
+    $[3] = s;
+    $[4] = t3;
+  } else {
+    t3 = $[4];
+  }
+  return t3;
+}
+
+```
+      
+### Eval output
+(kind: exception) Fixture not implemented
\ No newline at end of file

filename: compiler/packages/babel-plugin-react-compiler/src/__tests__/fixtures/compiler/effect-derived-computations/usestate-derived-from-prop-no-show-in-data-flow-tree.js
patch: @@ -0,0 +1,18 @@
+// @validateNoDerivedComputationsInEffects_exp
+
+function Component({prop}) {
+  const [s, setS] = useState();
+  const [second, setSecond] = useState(prop);
+
+  /*
+   * `second` is a source of state. It will inherit the value of `prop` in
+   * the first render, but after that it will no longer be updated when
+   * `prop` changes. So we shouldn't consider `second` as being derived from
+   * `prop`
+   */
+  useEffect(() => {
+    setS(second);
+  }, [second]);
+
+  return <div>{s}</div>;
+}
Repository: vercel/next.js
Pull request: Exclude partial fallback for deploy mode

This feature isn't rolled out so needs to be disabled. 

Changed files:
filename: test/deploy-tests-manifest.json
patch: @@ -97,6 +97,7 @@
   "rules": {
     "include": ["test/e2e/**/*.test.{t,j}s{,x}"],
     "exclude": [
+      "test/e2e/app-dir/partial-fallback-shell-upgrade/partial-fallback-shell-upgrade.test.ts",
       "test/e2e/cancel-request/stream-cancel.test.ts",
       "test/e2e/new-link-behavior/material-ui.test.ts",
       "test/e2e/react-dnd-compile/react-dnd-compile.test.ts",
Repository: ollama/ollama
Pull request: fix rotary embeddings for ministral 3

`mscale` was already being calculated by GGML's rope operation

Changed files:
filename: model/models/mistral3/model_text.go
patch: @@ -29,24 +29,13 @@ type TextOptions struct {
 func (o TextOptions) applyRotaryPositionEmbeddings(ctx ml.Context, states, positions ml.Tensor) ml.Tensor {
 	var ropeOpts []func(*rope.Options)
 	if o.ropeType == "yarn" {
-		getMscale := func(scale, mscale float64) float64 {
-			if scale <= 1.0 {
-				return 1.0
-			}
-			return 0.1*mscale*math.Log(scale) + 1.0
-		}
-
-		var attnFactor float32
 		if o.ropeMscale != 0 && o.ropeMscaleAllDim != 0 {
-			attnFactor = float32(getMscale(float64(o.ropeScale), float64(o.ropeMscale)) / getMscale(float64(o.ropeScale), float64(o.ropeMscaleAllDim)))
-		} else {
-			attnFactor = float32(getMscale(float64(o.ropeScale), 1))
+			ropeOpts = append(ropeOpts, rope.WithAttentionFactor(1.0/float32(0.1*math.Log(float64(o.ropeScale))+1.0)))
 		}
 
 		ropeOpts = append(ropeOpts,
 			rope.WithOriginalContextLength(o.ropeOrigPosEmbeddings),
 			rope.WithExtrapolationFactor(o.ropeExtrapolation),
-			rope.WithAttentionFactor(attnFactor),
 			rope.WithBetaFast(o.ropeBetaFast),
 			rope.WithBetaSlow(o.ropeBetaSlow),
 		)
Repository: rust-lang/rust
Pull request: Prevent no_threads RwLock's write() impl from setting mode to -1 when it is locked for reading

In my time updating the docs to `std::sync::RwLock` and adding a test verifying that max reader count is reachable in rust-lang/rust#153555, I noticed that the no_threads RwLock's `write()` implementation always sets the `mode` to `-1` (denoting writer locked) even though it could be reader locked. I feel like that's logically incorrect and that it should only be setting the `mode` to `-1` when we know that the mode is unlocked (`0`); `write()` should mirror the code that `read()` and `try_read()` has with `try_write()`.

For reference on read/try_read and write/try_write current implementations:
```rust
    #[inline]
    pub fn read(&self) {
        let m = self.mode.get();
        if m >= 0 {
            self.mode.set(m + 1);
        } else {
            rtabort!("rwlock locked for writing");
        }
    }

    #[inline]
    pub fn try_read(&self) -> bool {
        let m = self.mode.get();
        if m >= 0 {
            self.mode.set(m + 1);
            true
        } else {
            false
        }
    }

    #[inline]
    pub fn write(&self) {
        if self.mode.replace(-1) != 0 { // <-- This behavior logically does something different than what `try_write` does
            rtabort!("rwlock locked for reading")
        }
    }

    #[inline]
    pub fn try_write(&self) -> bool {
        if self.mode.get() == 0 {
            self.mode.set(-1);
            true
        } else {
            false
        }
    }
```

r? @jhpratt 

<!-- homu-ignore:start -->
<!--
If this PR is related to an unstable feature or an otherwise tracked effort,
please link to the relevant tracking issue here. If you don't know of a related
tracking issue or there are none, feel free to ignore this.

This PR will get automatically assigned to a reviewer. In case you would like
a specific user to review your work, you can assign it to them by using

    r? <reviewer name>
-->
<!-- homu-ignore:end -->


Changed files:
filename: library/std/src/sys/sync/rwlock/no_threads.rs
patch: @@ -37,8 +37,10 @@ impl RwLock {
 
     #[inline]
     pub fn write(&self) {
-        if self.mode.replace(-1) != 0 {
-            rtabort!("rwlock locked for reading")
+        if self.mode.get() == 0 {
+            self.mode.set(-1);
+        } else {
+            rtabort!("rwlock locked for reading");
         }
     }
Repository: huggingface/transformers
Pull request: Add Yoni to run-slow workflow

As per title, updated to remove former members as well

cc @yonigozlan @ydshieh 

Changed files:
filename: .github/workflows/self-comment-ci.yml
patch: @@ -27,7 +27,7 @@ env:
 jobs:
   get-pr-number:
     name: Get PR number
-    if: ${{ github.event.issue.state == 'open' && contains(fromJSON('["ydshieh", "ArthurZucker", "zucchini-nlp", "molbap", "gante", "LysandreJik", "Cyrilvallez", "Rocketknight1", "SunMarc", "eustlb", "MekkCyber", "vasqu", "ivarflakstad", "stevhliu", "ebezzam", "remi-or", "itazap", "3outeille", "IlyasMoutawwakil", "tarekziade"]'), github.actor) && (startsWith(github.event.comment.body, 'run-slow') || startsWith(github.event.comment.body, 'run slow') || startsWith(github.event.comment.body, 'run_slow')) }}
+    if: ${{ github.event.issue.state == 'open' && contains(fromJSON('["ydshieh", "ArthurZucker", "zucchini-nlp", "molbap", "LysandreJik", "Cyrilvallez", "Rocketknight1", "SunMarc", "eustlb", "vasqu", "ivarflakstad", "stevhliu", "ebezzam", "remi-or", "itazap", "3outeille", "IlyasMoutawwakil", "tarekziade", "yonigozlan"]'), github.actor) && (startsWith(github.event.comment.body, 'run-slow') || startsWith(github.event.comment.body, 'run slow') || startsWith(github.event.comment.body, 'run_slow')) }}
     uses: ./.github/workflows/get-pr-number.yml
 
   get-pr-info:
Repository: electron/electron
Pull request: fix: ensure WebContents::WasShown runs when window is shown

#### Description of Change

Fixes #49347 (a regression from #47151) by calling `WebContents::WasShown` whenever `OnWindowShow` runs, unless it was previously called by `Show` or `ShowInactive`.

#### Checklist

- [x] PR description included
- [x] `npm test` passes *(except for a few failures that appear to be spurious)*
- [x] [PR release notes](https://github.com/electron/clerk/blob/main/README.md) describe the change in a way relevant to app developers, and are [capitalized, punctuated, and past tense](https://github.com/electron/clerk/blob/main/README.md#examples).

#### Release Notes

Notes: Fixed window freeze when failing to enter/exit fullscreen on macOS.

Changed files:
filename: shell/browser/api/electron_api_browser_window.cc
patch: @@ -276,16 +276,22 @@ v8::Local<v8::Value> BrowserWindow::GetWebContents(v8::Isolate* isolate) {
 }
 
 void BrowserWindow::OnWindowShow() {
+  if (!web_contents_shown_) {
+    web_contents()->WasShown();
+    web_contents_shown_ = true;
+  }
   BaseWindow::OnWindowShow();
 }
 
 void BrowserWindow::OnWindowHide() {
   web_contents()->WasOccluded();
+  web_contents_shown_ = false;
   BaseWindow::OnWindowHide();
 }
 
 void BrowserWindow::Show() {
   web_contents()->WasShown();
+  web_contents_shown_ = true;
   BaseWindow::Show();
 }
 
@@ -294,6 +300,7 @@ void BrowserWindow::ShowInactive() {
   if (IsModal())
     return;
   web_contents()->WasShown();
+  web_contents_shown_ = true;
   BaseWindow::ShowInactive();
 }
 

filename: shell/browser/api/electron_api_browser_window.h
patch: @@ -80,6 +80,7 @@ class BrowserWindow : public BaseWindow,
   // Helpers.
 
   v8::Global<v8::Value> web_contents_;
+  bool web_contents_shown_ = false;
   v8::Global<v8::Value> web_contents_view_;
   base::WeakPtr<api::WebContents> api_web_contents_;
Repository: rust-lang/rust
Pull request: fix: [rustfmt] prevent panic when rewritng associated item delegations

Tracking issue: https://github.com/rust-lang/rust/issues/118212

rustfmt issue: https://github.com/rust-lang/rustfmt/issues/6513

Fixes a rustfmt bug for `#![feature(fn_delegation)]`

<!-- homu-ignore:start -->
<!--
If this PR is related to an unstable feature or an otherwise tracked effort,
please link to the relevant tracking issue here. If you don't know of a related
tracking issue or there are none, feel free to ignore this.

This PR will get automatically assigned to a reviewer. In case you would like
a specific user to review your work, you can assign it to them by using

    r? <reviewer name>
-->
<!-- homu-ignore:end -->


Changed files:
filename: src/tools/rustfmt/src/visitor.rs
patch: @@ -665,11 +665,11 @@ impl<'b, 'a: 'b> FmtVisitor<'a> {
         }
 
         // TODO(calebcartwright): consider enabling box_patterns feature gate
-        match (&ai.kind, visitor_kind) {
-            (ast::AssocItemKind::Const(c), AssocTraitItem) => {
+        match (&ai.kind, assoc_ctxt) {
+            (ast::AssocItemKind::Const(c), visit::AssocCtxt::Trait) => {
                 self.visit_static(&StaticParts::from_trait_item(ai, c.ident))
             }
-            (ast::AssocItemKind::Const(c), AssocImplItem) => {
+            (ast::AssocItemKind::Const(c), visit::AssocCtxt::Impl { .. }) => {
                 self.visit_static(&StaticParts::from_impl_item(ai, c.ident))
             }
             (ast::AssocItemKind::Fn(ref fn_kind), _) => {
@@ -714,7 +714,11 @@ impl<'b, 'a: 'b> FmtVisitor<'a> {
             (ast::AssocItemKind::MacCall(ref mac), _) => {
                 self.visit_mac(mac, MacroPosition::Item);
             }
-            _ => unreachable!(),
+            (ast::AssocItemKind::Delegation(_) | ast::AssocItemKind::DelegationMac(_), _) => {
+                // TODO(ytmimi) #![feature(fn_delegation)]
+                // add formatting for `AssocItemKind::Delegation` and `AssocItemKind::DelegationMac`
+                self.push_rewrite(ai.span, None);
+            }
         }
     }
 

filename: src/tools/rustfmt/tests/target/issue_6513.rs
patch: @@ -0,0 +1,10 @@
+#![feature(fn_delegation)]
+
+struct Ty;
+impl Ty {
+    reuse std::convert::identity;
+}
+
+trait Trait {
+    reuse std::convert::identity;
+}