summary refs log tree commit diff stats
path: root/lib/system/repr_v2.nim
diff options
context:
space:
mode:
authorflywind <xzsflywind@gmail.com>2021-04-22 14:08:56 +0800
committerGitHub <noreply@github.com>2021-04-22 08:08:56 +0200
commit53c898de4105049c767804d0d2c520f31a86b874 (patch)
tree4303c3f00dc522dcbcc33dafaff7737b07f5d8f1 /lib/system/repr_v2.nim
parentfb32fff8dcf2b15a469e5cce07b10d88aa6352ee (diff)
downloadNim-53c898de4105049c767804d0d2c520f31a86b874.tar.gz
fix #17812 (repr fails to compile with ARC/ORC) (#17816)
Diffstat (limited to 'lib/system/repr_v2.nim')
-rw-r--r--lib/system/repr_v2.nim2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/system/repr_v2.nim b/lib/system/repr_v2.nim
index d456f4454..618cc2b40 100644
--- a/lib/system/repr_v2.nim
+++ b/lib/system/repr_v2.nim
@@ -84,7 +84,7 @@ proc repr*(p: pointer): string =
 
 proc repr*(p: proc): string =
   ## repr of a proc as its address
-  repr(cast[pointer](p))
+  repr(cast[ptr pointer](unsafeAddr p)[])
 
 template repr*(x: distinct): string =
   repr(distinctBase(typeof(x))(x))