Hello,
One last question for today (maybe :):
In the extended notes examples, C.1.5, there is an example of how one
can use a generic function to effectively make a type constructor. Near
the end, there is the line:
y=t(kind(0.0d0)) ((0,1))
which is meant to use the structure constructor, and not the
user-defined generic.
Can someone explain this syntax to me? Why the double parenthesis around
0,1? What if there was a generic with a single default integer
argument? Wouldn't the compiler choke on the t(kind(0.0d0)) then?
Thanks,
Aleksandar
--
__________________________________
Aleksandar Donev
Complex Materials Theory Group (http://cherrypit.princeton.edu/)
Princeton Materials Institute & Program in Applied and Computational Mathematics
@ Princeton University
Address:
419 Bowen Hall, 70 Prospect Avenue
Princeton University
Princeton, NJ 08540-5211
E-mail: [log in to unmask]
WWW: http://atom.princeton.edu/donev
Phone: (609) 258-2775
Fax: (609) 258-6878
__________________________________
|