Skip to content

Instantly share code, notes, and snippets.

@ab5tract
Created January 23, 2024 23:01
Show Gist options
  • Save ab5tract/6fdf18adbc3b659e814835db429f81ba to your computer and use it in GitHub Desktop.
Save ab5tract/6fdf18adbc3b659e814835db429f81ba to your computer and use it in GitHub Desktop.
mixing multi subs defined in separate modules
unit module A;
use Z;
multi sub x(R::M $r) is export { $r }
unit module B;
use Z;
multi sub x(R::N $r) is export { $r }
use A;
use B;
use Z;
dd x(M);
dd x(N);
unit module Z;
enum R is export <M N>;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment