digitalmars.D.learn - Compiles but does not link
- Paul D Anderson (10/10) Jun 24 2015 The code snippet below compiles but the linker fails with Error
- Paul D Anderson (3/13) Jun 24 2015 Uh, never mind. I got so focused on the delegate I forgot to give
The code snippet below compiles but the linker fails with Error 42: Symbol undefined. What am I doing wrong? void main() { int foo(int a); alias FP = int delegate(int); FP fp = &foo; } Paul
Jun 24 2015
On Thursday, 25 June 2015 at 00:24:23 UTC, Paul D Anderson wrote:The code snippet below compiles but the linker fails with Error 42: Symbol undefined. What am I doing wrong? void main() { int foo(int a); alias FP = int delegate(int); FP fp = &foo; } PaulUh, never mind. I got so focused on the delegate I forgot to give the function a body.
Jun 24 2015