Skip to content

Conversation

@christoph-dfinity
Copy link
Contributor

No description provided.

Base automatically changed from claudio/stable-functions-merge to luc/stable-functions July 25, 2025 07:06
@@ -0,0 +1,14 @@
//ENHANCED-ORTHOGONAL-PERSISTENCE-ONLY
//SKIP ic-ref-run
import Clamper "Clamper";
Copy link
Contributor

Choose a reason for hiding this comment

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

Is this file missing from the PR?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This was a leftover file. I removed it in favor of brittle-stable-functions.drun

persistent actor {
class Clamper(l : Nat, h : Nat) {
public func clamp(x : Nat) : Nat {
// When trying to evolve this class to hardcode the upper limit,

This comment was marked as outdated.

@@ -0,0 +1,15 @@
persistent actor {
class Clamper(low : Nat, high : Nat) {
Copy link
Contributor

Choose a reason for hiding this comment

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

I can't tell from the log if the upgrade from Initial to Renamed works or not. I suspect it should from the PR description, but does it fail?

The closures of stable functions are represented in a portable format with the following clearly defined binding of captured variables:

Local variables are captured by name.
Parameters are captured by position (also considering nested functions).

I guess some printfs might help

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.

2 participants