-
-
Save mooskagh/e112a05a1fc37c67753a219edb4833d1 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| type | |
| DashboardSection = ref object of RootObj | |
| discard | |
| GlobalSection = ref object of DashboardSection | |
| discard | |
| Dashboard = ref object | |
| global: GlobalSection | |
| method Update(section: DashboardSection) {. base .} = | |
| discard | |
| proc Blah(dashboard: Dashboard) = | |
| dashboard.global.Update() | |
| # Run: | |
| # nim check --verbosity:2 x.nim | |
| # Warning: | |
| # x.nim(16, 19) Warning: not GC-safe: 'Update(dashboard.global())' [GcUnsafe] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment