Selected changesmerged Oct 31, 2026
Implement `advance_back_by` on `Fuse`Rust · 41 + / 0 −
Introduces 4 new declarations in library/core/src/iter/adapters/fuse.rs.
Adds new language design rather than adjusting what was there. Tests changed with it, with code of their own.
library/core/src/iter/adapters/fuse.rs ↗ · 2 files
@@ -358,6 +366,25 @@ where and_then_or_clear(&mut self.iter, |iter| iter.next_back()) } + #[inline]+ default fn advance_back_by(&mut self, n: usize) -> Result<(), NonZero<usize>>+ where+ I: DoubleEndedIterator,+ {+ let Some(iter) = &mut self.iter else {+ return match NonZero::new(n) {+ Some(n) => Err(n),+ None => Ok(()),+ };+ };++ let res = iter.advance_back_by(n);+ if res.is_err() {+ self.iter = None;+ }+ res+ }+ #[inline] default fn nth_back(&mut self, n: usize) -> Option<<I as Iterator>::Item> where
fix: Protect math from markdown emphasis parsing in Markdown panePython · 58 + / 3 −
Introduces 10 new declarations in panel/pane/markup.py.
Adds new core implementation rather than adjusting what was there. Tests changed with it, with code of their own.
panel/pane/markup.py ↗ · 3 files
@@ -38,6 +38,54 @@ # links, definition lists) or which breaks line offsets (\r). _NON_LOCAL_SYNTAX = re.compile(r'\[\^|\]:|^ {0,3}[:~][ \t]|\r', re.MULTILINE) +def _math_plugin(md: MarkdownIt) -> None:+ """+ Keeps math delimited by $$ verbatim, since the client-side+ MathJax pass runs on the rendered HTML and would otherwise see+ markup generated from characters such as '*' inside the math.+ """+ from mdit_py_plugins.dollarmath import dollarmath_plugin+ from mdit_py_plugins.dollarmath.index import math_inline_dollar++ dollarmath_plugin(md, allow_labels=False, double_inline=True)++ # The client only typesets $$, so single $ must stay ordinary text+ # (e.g. currency) and keep its surrounding emphasis.+ inline_rule = math_inline_dollar(True, True, True)++ def double_only(state, silent):+ if state.src[state.pos:state.pos + 2] != '$$':+ return False+ return inline_rule(state, silent)++ md.inline.ruler.at('math_inline', double_only)++ def raw(delimiter, block=False):+ def render(self, tokens, idx, options, env):+ math = escape(tokens[idx].content, quote=False)+ return f'{delimiter}{math}{delimiter}\n' if block else f'{delimiter}{math}{delimiter}'+ return render++ md.add_render_rule('math_inline_double', raw('$$'))+ md.add_render_rule('math_block', raw('$$', block=True))
Turbopack: resolve per-module data once during module graph constructionRust · 739 + / 252 −
Introduces 36 new declarations in turbopack/crates/turbopack-core/src/module_graph/mod.rs.
Adds new framework internals rather than adjusting what was there. Tests changed with it, with code of their own.
turbopack/crates/turbopack-core/src/module_graph/mod.rs ↗ · 24 files
@@ -1969,17 +2195,168 @@ enum SingleModuleGraphBuilderNode { }, } +// `Hash`/`Eq` are implemented manually over the identity-determining fields only (`module` ++// `is_traced` / `idx`), deliberately excluding `ident`. This node is the `AdjacencyMap` visit dedup+// key; `ident` is fully determined by `module`, so including it would only waste cycles hashing a+// full `AssetIdent` per insert.+impl PartialEq for SingleModuleGraphBuilderNode {+ fn eq(&self, other: &Self) -> bool {+ match (self, other) {+ (+ SingleModuleGraphBuilderNode::Module {+ module: l_module,+ is_traced: l_is_traced,+ ..+ },+ SingleModuleGraphBuilderNode::Module {+ module: r_module,+ is_traced: r_is_traced,+ ..+ },+ ) => l_module == r_module && l_is_traced == r_is_traced,+ (+ SingleModuleGraphBuilderNode::VisitedModule {+ module: l_module,+ idx: l_idx,+ },+ SingleModuleGraphBuilderNode::VisitedModule {+ module: r_module,+ idx: r_idx,+ },+ ) => l_module == r_module && l_idx == r_idx,+ _ => false,
chat : strip the think block in the qwen3-coder with reasoning_format noneC++ · 12 + / 4 −
Reworks 12 lines of existing logic in common/parsers/qwen3-coder.cpp.
Changes how existing runtime behaves. Tests changed with it, with code of their own.
common/parsers/qwen3-coder.cpp ↗ · 2 files
@@ -74,16 +74,24 @@ common_chat_params common_chat_params_init_qwen3_coder(const common_chat_templat data.parser = build_chat_peg_parser([&](common_chat_peg_builder & p) { auto generation_prompt = p.literal(GEN_PREFIX); + // The template strips the newline before </think>, so leave it out of the reasoning+ auto think_body = p.until_one_of({ "\n</think>", "</think>", "<tool_call>" });+ auto think_close = p.literal("\n</think>") | p.literal("</think>") | p.peek(p.literal("<tool_call>"));++ auto reasoning_extracted = p.optional("<think>" + p.space() + p.reasoning(think_body) + think_close);+ auto reasoning_skipped = p.optional("<think>" + p.space() + think_body + think_close);+ auto reasoning = p.eps(); if (supports_reasoning && extract_reasoning) {- // The template strips the newline before </think>, so leave it out of the reasoning- reasoning = p.optional("<think>" + p.space() +- p.reasoning(p.until_one_of({ "\n</think>", "</think>", "<tool_call>" })) +- (p.literal("\n</think>") | p.literal("</think>") | p.peek(p.literal("<tool_call>"))));+ reasoning = reasoning_extracted; } // Response format parser if (has_response_format) {+ // The answer must be bare JSON, so the think block is consumed even when it is not extracted+ if (supports_reasoning && !extract_reasoning) {+ reasoning = reasoning_skipped;+ } return generation_prompt + (reasoning << p.content(p.schema(p.json(), "response-format", inputs.json_schema))); }
[DevTools] Keep unmatched console specifiers literal in single-string formatterJavaScript · 7 + / 5 −
Reworks 10 lines of existing logic in packages/react-devtools-shared/src/backend/utils/index.js.
Changes how existing language design behaves. Tests changed with it, with code of their own.
packages/react-devtools-shared/src/backend/utils/index.js ↗ · 2 files
@@ -211,11 +217,7 @@ export function formatConsoleArgumentsToSingleString( arg = parseFloat(arg).toString(); break; }- if (!escaped) {- return arg;- }- args.unshift(arg);- return match;+ return arg; }); } }