comparison gen/toir.cpp @ 1245:465a77c904d4

Fixed all issues preventing Tango 0.99.8 to compile with `sh build-tango.sh --verbose ldc'.
author Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
date Fri, 17 Apr 2009 14:38:29 +0200
parents 212ec2d9d176
children 01909bd1132c
comparison
equal deleted inserted replaced
1244:e1b0c5c74c58 1245:465a77c904d4
2388 DValue* StructLiteralExp::toElem(IRState* p) 2388 DValue* StructLiteralExp::toElem(IRState* p)
2389 { 2389 {
2390 Logger::print("StructLiteralExp::toElem: %s @ %s\n", toChars(), type->toChars()); 2390 Logger::print("StructLiteralExp::toElem: %s @ %s\n", toChars(), type->toChars());
2391 LOG_SCOPE; 2391 LOG_SCOPE;
2392 2392
2393 // make sure the struct is resolved
2394 sd->codegen(Type::sir);
2395
2393 // get inits 2396 // get inits
2394 std::vector<LLValue*> inits(sd->fields.dim, NULL); 2397 std::vector<LLValue*> inits(sd->fields.dim, NULL);
2395 2398
2396 size_t nexprs = elements->dim;; 2399 size_t nexprs = elements->dim;;
2397 Expression** exprs = (Expression**)elements->data; 2400 Expression** exprs = (Expression**)elements->data;
2445 2448
2446 LLConstant* StructLiteralExp::toConstElem(IRState* p) 2449 LLConstant* StructLiteralExp::toConstElem(IRState* p)
2447 { 2450 {
2448 Logger::print("StructLiteralExp::toConstElem: %s @ %s\n", toChars(), type->toChars()); 2451 Logger::print("StructLiteralExp::toConstElem: %s @ %s\n", toChars(), type->toChars());
2449 LOG_SCOPE; 2452 LOG_SCOPE;
2453
2454 // make sure the struct is resolved
2455 sd->codegen(Type::sir);
2450 2456
2451 // get inits 2457 // get inits
2452 std::vector<LLValue*> inits(sd->fields.dim, NULL); 2458 std::vector<LLValue*> inits(sd->fields.dim, NULL);
2453 2459
2454 size_t nexprs = elements->dim;; 2460 size_t nexprs = elements->dim;;