Skip to content

Conversation

@nikola-matic
Copy link
Contributor

@nikola-matic nikola-matic commented Oct 6, 2025

Under development, don't review yet.

  • CLI
  • Standard JSON
  • Forbid --experimental with --standard-json
  • Pragmas
  • Docs?
  • Changelog

Partially (for now) implements #16123

@nikola-matic nikola-matic force-pushed the introduce-experimental-flag branch 5 times, most recently from 1beb509 to ba48a91 Compare October 9, 2025 13:17
@nikola-matic nikola-matic force-pushed the introduce-experimental-flag branch 4 times, most recently from fd70f82 to 98cad7c Compare October 21, 2025 09:40
@github-actions github-actions bot added the stale The issue/PR was marked as stale because it has been open for too long. label Nov 4, 2025
@argotorg argotorg deleted a comment from github-actions bot Nov 4, 2025
@nikola-matic nikola-matic removed the stale The issue/PR was marked as stale because it has been open for too long. label Nov 4, 2025
@github-actions github-actions bot added the stale The issue/PR was marked as stale because it has been open for too long. label Nov 19, 2025
@nikola-matic nikola-matic removed the stale The issue/PR was marked as stale because it has been open for too long. label Nov 19, 2025
@argotorg argotorg deleted a comment from github-actions bot Nov 19, 2025
@nikola-matic nikola-matic force-pushed the introduce-experimental-flag branch 3 times, most recently from 5c5a463 to 2518378 Compare November 20, 2025 11:55
@github-actions github-actions bot added the stale The issue/PR was marked as stale because it has been open for too long. label Dec 4, 2025
@nikola-matic nikola-matic removed the stale The issue/PR was marked as stale because it has been open for too long. label Dec 4, 2025
@argotorg argotorg deleted a comment from github-actions bot Dec 4, 2025
@nikola-matic nikola-matic force-pushed the introduce-experimental-flag branch from 2518378 to 83b670d Compare December 8, 2025 09:43
@github-actions github-actions bot added the stale The issue/PR was marked as stale because it has been open for too long. label Dec 22, 2025
@nikola-matic nikola-matic removed the stale The issue/PR was marked as stale because it has been open for too long. label Dec 22, 2025
@argotorg argotorg deleted a comment from github-actions bot Dec 22, 2025
@github-actions
Copy link

github-actions bot commented Jan 6, 2026

This pull request is stale because it has been open for 14 days with no activity.
It will be closed in 7 days unless the stale label is removed.

@github-actions github-actions bot added the stale The issue/PR was marked as stale because it has been open for too long. label Jan 6, 2026
@clonker clonker removed the stale The issue/PR was marked as stale because it has been open for too long. label Jan 6, 2026
@nikola-matic nikola-matic force-pushed the introduce-experimental-flag branch from 83b670d to 17c3e0e Compare January 6, 2026 12:22
@nikola-matic nikola-matic force-pushed the introduce-experimental-flag branch from 6c4e799 to 136bd18 Compare January 15, 2026 16:37
@nikola-matic nikola-matic marked this pull request as ready for review January 15, 2026 16:57
@nikola-matic nikola-matic force-pushed the introduce-experimental-flag branch from 136bd18 to 8f8a1dc Compare January 16, 2026 13:38
@cameel cameel added this to the 0.8.34 milestone Jan 16, 2026
@cameel
Copy link
Collaborator

cameel commented Jan 17, 2026

Note that there is an issue for this: #16123. Please include it in the description and also check if the PR covers everything.


Compiler Features:
* Commandline Interface: Introduce `--experimental` flag required for toggling the experimental mode.
* Standard JSON Interface: Introduce `settings.experimental` setting required for toggling the experimental mode.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder if it wouldn't be a good idea to make a prerelease once we merge this PR.

I imagine that this kind of change could cause some disruption for those who were relying on experimental features but shouldn't have.

Copy link
Collaborator

@cameel cameel Jan 17, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we also mention (as a separate entry) that some features now require the experimental mode (and list those features)? If we do make a prerelease that will be the primary source of information about this.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, we should also notify the solc-tooling group in advance - perhaps even get Lea or whoever has access to our twitter to tweet this out so that tooling is aware.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's do that.

@nikola-matic nikola-matic force-pushed the introduce-experimental-flag branch 4 times, most recently from 5f3fe19 to 422183a Compare January 21, 2026 13:07
/// @use-src 0:\"C\"
object \"C_2\" {
code {
/// @src 0:56:69
Copy link
Collaborator

@cameel cameel Jan 22, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we have a bug in debugInfo option. The @src annotation is supposed to be present only if "location" is on the list and here it's not (you only included "ethdebug").

Comment on lines 1936 to +1940
bool const experimentalMode = !onlySafeExperimentalFeaturesActivated(
_contract.contract->sourceUnit().annotation().experimentalFeatures
);
) || m_experimental;
Copy link
Collaborator

@cameel cameel Jan 22, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can reduce this to just m_experimental and assert the rest. The analysis is supposed to report an error if any experimental feature is used without m_experimental.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note also that we have this weird "safe experimental feature" concept here. Apparently it applies to SMTChecker and ABI coder:

static std::set<ExperimentalFeature> const ExperimentalFeatureWithoutWarning =
{
ExperimentalFeature::ABIEncoderV2,
ExperimentalFeature::SMTChecker,
ExperimentalFeature::TestOnlyAnalysis,
};

Oddly, before #7759 which made ABI coder v2 non-experimental, this was instead a list of "analysis-only experimental features". Then it was renamed.

In any case, those happen to be exactly those problematic pragmas that were holding back this PR. Since we were actually going out of our way not to warn about these features, maybe we should just keep the mechanism and exempt from the --experimental flag? Otherwise the mechanism has no use and I'd remove it completely.

Copy link
Contributor Author

@nikola-matic nikola-matic Jan 26, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can reduce this to just m_experimental and assert the rest. The analysis is supposed to report an error if any experimental feature is used without m_experimental.

Assert in what way - both m_eofVersion.has_value() and !onlySafeExperimentalFeaturesActivated(...) are just subsets of m_experimental? Asserting every single experimental feature would be a bit of an overkill with the entire OR chain of features.

I'd rather just get rid of it completely.

@nikola-matic nikola-matic force-pushed the introduce-experimental-flag branch from 9559fde to 91c51ea Compare January 29, 2026 10:22
@nikola-matic nikola-matic force-pushed the introduce-experimental-flag branch from 81bd190 to 2ffef5a Compare January 29, 2026 11:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants