GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — [SQL] Do not generate statics whose values are references by mihaibudiu · Pull Request #7693 · feldera/feldera

Conversation

@mihaibudiu

@mihaibudiu mihaibudiu commented Oct 29, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor

Linked Issue

Fixes #7685

The compiler tries to lift constant expression into StaticLazy expressions. It always tried to lift the maximal possible expression. But this can lead to code like:

static STATIC_a1c14e5b2ab3534d: StaticLazy<(&Tup1<Option<i32>>, )> = StaticLazy::new();
STATIC_a1c14e5b2ab3534d.init(move || (
    &Tup1::new(None::<i32>),
));

which does not compile, because it returns a reference to a temporary.

The fix is to only lift this:

STATIC_8c3ff960f750a222.init(move || Tup1::new(None::<i32>));

Describe Manual Test Plan

Checklist

  • Unit tests added/updated

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@mihaibudiu
[SQL] Do not generate statics whose values are references
be534b5
Signed-off-by: Mihai Budiu <[email protected]>
gz
gz approved these changes Oct 29, 2026
View reviewed changes
@mythical-fred-oss

mythical-fred-oss Bot commented Oct 29, 2026

Copy link
Copy Markdown
Contributor

LGTM, with one fix needed in the description.

bug (medium): The PR body says Fixes #6785, which is an unrelated S3 adapter test-hang issue. The SQL issue this fixes is #7685 (the new test is named issue7685). As written, merging won't close #7685 and points at the wrong issue.

What I ran:

Check Result
./build.sh ✅
ExpressionGCIncrementalTests#issue7685 with the fix ✅
Same test with the ImplementStatics change reverted ❌ E0515: cannot return value referencing temporary value, so the test does reproduce the bug
ExpressionGCIncrementalTests (whole class) ✅ 5/5
Ad-hoc test: two always-NULL group keys (ts + NULL, x * NULL) on a LATENESS table, plus a non-lateness table grouped by BIGINT + NULL and VARCHAR || NULL ✅ compiles and gives correct output (not committed)

The feldera-pr-checks gates pass: the test covers the changed behaviour, there are no flakiness risks, and the change is not user-visible.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@mihaibudiu
mihaibudiu added this pull request to the merge queue Oct 29, 2026
Merged via the queue into main with commit 75a622b Oct 29, 2026
3 checks passed

Uh oh!

There was an error while loading. Please reload this page.

@mihaibudiu
mihaibudiu deleted the issue7685 branch October 29, 2026 11:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@gz gz gz approved these changes

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

[SQL] Query produces uncompilable Rust

Uh oh!

There was an error while loading. Please reload this page.

2 participants

@mihaibudiu @gz
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402520 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.