comparison gen/functions.cpp @ 329:8c1dc3e705da trunk

[svn r350] Fixed incorrect function types for lazy arguments. looks like lazy arguments have never even worked :o well.. now they should.
author lindquist
date Fri, 11 Jul 2008 01:34:04 +0200
parents 7086a84ab3d6
children 20446d22f832
comparison
equal deleted inserted replaced
328:7086a84ab3d6 329:8c1dc3e705da
137 } 137 }
138 else { 138 else {
139 Logger::println("in param"); 139 Logger::println("in param");
140 } 140 }
141 paramvec.push_back(at); 141 paramvec.push_back(at);
142 }
143
144 // handle lazy args
145 if (arg->storageClass & STClazy)
146 {
147 Logger::cout() << "for lazy got: " << *paramvec.back() << '\n';
148 TypeFunction *ltf = new TypeFunction(NULL, arg->type, 0, LINKd);
149 TypeDelegate *ltd = new TypeDelegate(ltf);
150 at = getPtrToType(DtoType(ltd));
151 Logger::cout() << "lazy updated to: " << *at << '\n';
152 paramvec.back() = at;
142 } 153 }
143 154
144 if (arg->llvmByVal) 155 if (arg->llvmByVal)
145 nbyval++; 156 nbyval++;
146 } 157 }