Error: undefined identifier 'selector'

Mike McKee via Digitalmars-d-learn digitalmars-d-learn at
Tue Dec 15 00:14:24 PST 2015

I found the fix:

$ sudo brew update
$ sudo brew uninstall --force dmd
$ sudo su
$ cd /Library
$ rm -rfd D
$ exit
$ sudo brew install dmd

This not only takes one from an older dmd to a more current 
version (in my case, from 2.068 to 2.069), but it also fixes a 
bug where /Library/D doesn't get updated. (Besides, the El 
Capitan version of 2.069 now doesn't use /Library/D.)

When I did that, I found I was able to compile like so:

volomike:cpptod4 mike$ dmd -m64 -L-framework -LFoundation test.d
volomike:cpptod4 mike$ ls
test	test.d	test.o
volomike:cpptod4 mike$ ./test
2015-12-15 03:07:52.669 test[7308:116958] Hello World!
volomike:cpptod4 mike$

So, it not only used an Objective C NSString object, but it fed 
it to NSLog and I got console output in NSLog format.

More information about the Digitalmars-d-learn mailing list