Commit graph

715 commits

Author SHA1 Message Date
Martin
9839cfb889 Experimental varargs fix 2015-02-23 22:52:10 +01:00
David Nadlinger
8436f079c3 Merge pull request #798 from klickverbot/tuple-sarray
Fix initialization of TupleExps with static array members.
2014-12-26 22:54:43 +01:00
kai
024b14cd7f Fix some warnings.
These are easy to solve and reduce the noise in the Travis build.
2014-12-26 15:59:23 +01:00
Alexey Prokhin
b7a361f467 Fix issue #795 — Struct dtor called twice under some circumstances 2014-11-20 16:19:11 +03:00
David Nadlinger
d6e54bef97 Fix initialization of TupleExps with static array members.
Just as for structs, `DVarValue::getRVal()` doesn't dereference the
address for these.

GitHub: Fixes #797.
2014-11-16 21:28:14 +01:00
David Nadlinger
e4aa92deb3 Get rid of more superfluous casts with DMD arrays.
There are still a few more left.
2014-11-16 08:00:17 +01:00
kai
a2748cd2fd Merge current development state of 2.067
First merge of current development stream. Asm blocks are known to be broken.

DMD:      0c9f437bc24015707130ba42dc434d9cd58282fb
druntime: 86d49cfb3670904603df0cfdfe44c6fff565c0fc
Phobos:   a8ca4f7964becac680af0eadbde05aa7d10fc338
2014-11-15 18:53:23 +01:00
Martin
1289ca8664 Win64: don't use DMD x64 implementations of LDC_va_start and LDC_va_copy intrinsics 2014-10-24 18:43:33 +02:00
David Nadlinger
bff766b379 Track member field index in IrTypeAggr, not IrField.
This fixes a regression introduced in caa2f15c8a. The IrDsymbol
metadata is obviously reset in between modules, while IrTypes
are not. Thus, we can never set symbol metadata when resolving
types, as the symbol data will be wrong in all modules following
the one where the type was first resolved.

GitHub: Fixes #739.
2014-10-11 03:28:49 +02:00
David Nadlinger
2071cf4b3d [cleanup] Merge DtoIndex{Struct, Class}. 2014-10-11 03:28:48 +02:00
Andreas Hollandt
afcd0aad41 add a few IR names 2014-10-02 14:36:51 +02:00
Andreas Hollandt
6db62ee8a9 remove all the "tmp" IR names 2014-10-02 14:36:51 +02:00
Andreas Hollandt
cf9b18ed3d fix C2883 in MSVC build 2014-09-30 12:30:02 +02:00
kai
de75dccdfa Move visitor outside of class to fix MSVC compile problem. 2014-09-25 06:50:21 +02:00
Kai Nacke
382ad184d8 Merge branch 'master' into merge-2.066
Conflicts:
	dmd2/builtin.c
	gen/classes.cpp
	gen/functions.cpp
	gen/llvmhelpers.cpp
	gen/statements.cpp
	gen/toir.cpp
	runtime/druntime
	runtime/phobos
2014-09-13 23:11:54 +02:00
Alexey Prokhin
18f33b1815 Make IrDsymbol to be a typesafe union to reduce memory usage 2014-09-12 14:43:49 +04:00
Alexey Prokhin
d9189acbc4 Move toElem/toConstElem to visitors 2014-08-27 16:22:02 +04:00
Alexey Prokhin
08c5d6f82e Shut up compiler warnings about hidden visit() methods 2014-08-24 21:01:45 +04:00
Alexey Prokhin
056f93db7b Bad codegen for logical right shift assign expression
Cast rhs to lhs type, instead of casting both to common type
and then back to the original.
2014-08-24 13:59:19 +04:00
Alexey Prokhin
f25d31332b Trivial error message improvements 2014-08-22 16:26:16 +04:00
Alexey Prokhin
fb95fd60a9 Fix DMD Issue 12153 - Ternary operator on static array lvalues creates copy 2014-08-22 16:01:35 +04:00
Alexey Prokhin
ea2c54d63c DMD Issue 12681 - Rewrite rule prevents unique detection
Do rewriting in glue-layer.
2014-08-22 16:01:35 +04:00
Alexey Prokhin
560bcd78c7 Private methods are always not virtual 2014-08-22 16:01:34 +04:00
Alexey Prokhin
f9bae48c25 AssignExp is always an lvalue in 2.066 2014-08-22 16:01:34 +04:00
Alexey Prokhin
0a3ed6f253 Handle ThisExp without var declaration in ThisExp::toElem() 2014-08-22 16:01:34 +04:00
Alexey Prokhin
76dec46df5 WIP: merge dmdfe 2.066 2014-08-22 16:01:28 +04:00
Andreas Hollandt
8af29baeda fix #667 flags list used as string
enable function and data sections
fix incorrect library search paths
2014-07-17 00:11:08 +02:00
David Nadlinger
0d5f084f6a x86_64 vararg support is not so simple.
This reverts 1e649422 and adds some extra cleanup/comments.
2014-07-12 02:23:32 +02:00
Alexey Prokhin
5c3209a2db Fixed ICE inroduced by 6197938 2014-07-11 18:06:58 +02:00
Alexey Prokhin
a6f358c59b Remove LINKintrisic 2014-07-10 18:10:46 +04:00
kai
45fca1f3b5 Add line number to error message of -nogc switch.
This was suggested by bearophile in the news group.
It also changes all Loc objects to be passed by reference.
2014-07-04 07:15:05 +02:00
kai
e69e435122 Merge branch 'release-0.13.0' 2014-06-28 18:08:31 +02:00
kai
9f8887b07f Fix AtomicCmpXchg for LLVM 3.5
A weak variant was added to LLVM 3.5 and the return type changed to { iN, i1 }.
Just extract the value from this struct.
2014-06-28 17:01:47 +02:00
Alexey Prokhin
61979387fd Fix DMD Issue 11394 - NRVO should work for object field initialization in constructor 2014-06-27 14:47:10 +04:00
Alexey Prokhin
1e649422d6 Simplify vaarg support on X86_64 2014-06-27 11:39:26 +04:00
kai
2b6dbb03f4 Add IF_LOG to more logging statements.
Evaluating arguments which call toChars() or toPrettyChars() are much more expensive then checking Logger::enabled().
2014-06-26 06:54:38 +02:00
kai
b7615f6a28 Merge branch 'master' into merge-2.065
Conflicts:
	dmd2/declaration.h
	dmd2/dsymbol.h
	dmd2/func.c
	gen/functions.cpp
	gen/toir.cpp
	runtime/druntime
2014-06-23 07:57:30 +02:00
kai
7c289fd673 Introduce needsCodegen.
This is a backport of the code from 2.065.
2014-06-19 13:20:28 +02:00
Kai Nacke
78c0c30d6b Merge branch 'merge-2.064' into merge-2.065
Conflicts:
	dmd2/template.h
	runtime/druntime
2014-06-06 06:44:57 +02:00
kai
7fd9e5a06e Merge branch 'master' into merge-2.064
Conflicts:
	runtime/druntime
2014-06-02 07:50:55 +02:00
David Nadlinger
aa06fea59e Reject non-integer atomic load/store during codegen.
This avoids hitting an LLVM assert during codegen.
2014-05-30 20:11:47 +02:00
David Nadlinger
6a5ed89644 Make intrinsic parameter errors in CallExp::toElem() fatal.
Returning null will crash just about any other glue layer code.

Ideally, we'd catch those during semantic analysis (glue layer
errors are always to be avoided due to speculative compilation),
but this at least avoids the segfaults.
2014-05-30 20:11:39 +02:00
Kai Nacke
92c06dede0 Merge branch 'merge-2.064' into merge-2.065
Conflicts:
	runtime/druntime
2014-05-10 21:38:37 +02:00
Kai Nacke
8db10661e7 Merge branch 'fix424' into merge-2.064 2014-04-25 23:09:19 +02:00
Kai Nacke
295212a806 Merge branch 'master' into merge-2.064 2014-04-25 23:09:09 +02:00
Kai Nacke
09a2b9774d Final fix for issue #424 2014-04-25 18:26:59 +02:00
David Nadlinger
ee3a0f29c5 Fix ArrayLiteralExp for boolean arrays.
GitHub: Fixes #602.
2014-04-24 21:13:18 +02:00
Kai Nacke
2218ca83e8 Merge branch 'merge-2.064' into merge-2.065 2014-03-23 19:29:10 +01:00
Kai Nacke
266d7c6d82 Fix destructor calls of temporaries inside an assert.
An assert expression has a slightly different requirement: if the assertion holds then
the expression of the message is not evaluated. A destructor of a temporary variable must
not be called because the object was never constructed.
If the assertion does not hold and an exception is raised, then the destructor must be
called in a finally block.

This fixes a test failure in xtest46.d
2014-03-23 18:22:33 +01:00
kai
f8a53ab3dc Merge branch 'merge-2.064' into merge-2.065
Conflicts:
	runtime/druntime
2014-03-12 18:27:43 +01:00