Skip to content

Migrate examples to the new compiler - #258

Merged
lukewilliamboswell merged 23 commits into
roc-lang:mainfrom
ageron:migrate-to-new-roc
Aug 9, 2026
Merged

Migrate examples to the new compiler#258
lukewilliamboswell merged 23 commits into
roc-lang:mainfrom
ageron:migrate-to-new-roc

Conversation

@ageron

@ageron ageron commented Jul 31, 2026

Copy link
Copy Markdown
Contributor

This PR aims to migrate all examples to the new compiler, starting with the examples that can run on the echo platform, without any library dependency:

  • AllSyntax
  • BasicDict
  • CommandLineArgs
  • CustomInspect
  • ErrorHandlingBasic
  • FizzBuzz
  • GraphTraversal
  • HelloWorld
  • ImportFromDirectory
  • IngestFiles
  • Json
  • LeastSquares
  • MultiLineComments (no change required)
  • MultipleRocFiles
  • PatternMatching
  • SafeMath
  • TowersOfHanoi
  • TryOperatorDesugaring
  • Tuples

Edit: also migrated the following examples which depend on the basic-cli platform and a few libraries:

  • CommandLineArgsFile
  • Commands
  • ErrorHandlingRealWorld
  • ImportPackageFromModule (uses the unicode library)
  • LoopEffect
  • Parser (uses the parser library)
  • RandomNumbers (uses the rand library)
  • Snake

The following examples were dropped (possibly temporarily):

  • DotNetPlatform
  • GoPlatform
  • Scripting

@Anton-4 Anton-4 self-assigned this Aug 5, 2026

@Anton-4 Anton-4 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Thanks a lot @ageron!
I just fixed some minor issues and I have some (minor) rabbit holes saved in a txt file on my desktop. I can continue my review on Friday.

If there is desire to push this through quicker I think only the nix files need to be torn out and CI should only run using a Roc release build and no debug build because it hits a stack overflow.

@Anton-4

Anton-4 commented Aug 7, 2026

Copy link
Copy Markdown
Collaborator

I can continue my review on Friday.

I am not going to make it, lots of tangents today. Hopefully better tomorrow.

@ageron
ageron marked this pull request as ready for review August 7, 2026 21:57

@Anton-4 Anton-4 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Thanks @ageron ❤️

@ageron

ageron commented Aug 9, 2026

Copy link
Copy Markdown
Contributor Author

Thanks for reviewing, @Anton-4. Note that I can't merge the PR (the message says "New changes require approval from someone other than Anton-4 because they were the last pusher.")

@lukewilliamboswell
lukewilliamboswell merged commit 475418f into roc-lang:main Aug 9, 2026
4 checks passed
@ageron
ageron deleted the migrate-to-new-roc branch August 9, 2026 05:41
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.

3 participants