Bug 13375 – Linking failure when importing both std.regex and std.algorithm

Status
RESOLVED
Resolution
FIXED
Severity
regression
Priority
P1
Component
phobos
Product
D
Version
D2
Platform
x86_64
OS
Linux
Creation time
2014-08-25T11:04:00Z
Last change time
2014-09-03T16:40:47Z
Assigned to
nobody
Creator
puneet

Comments

Comment #0 by puneet — 2014-08-25T11:04:18Z
Here is the reduced test case. With the github DMD/Phobos I get... $ rdmd --force foo.d /tmp/.rdmd-1000/rdmd-foo.d-52164644A907860119A1D1FE4E50789F/objs/foo.o:foo.d:function _D3std5range37__T11SortedRangeTAiVAyaa5_61203c2062Z11SortedRange5emptyMFNaNbNdNiNfZb: error: undefined reference to '_D3std5array12__T5emptyTiZ5emptyFNaNbNdNiNfxAiZb' import std.regex; import std.algorithm; void foo(string bar) { split(bar, regex("_")); int[] test ; test.sort(); } void main(){}
Comment #1 by cody.casterline — 2014-08-25T19:42:14Z
Not able to reproduce that on my end: $ cat foo.d import std.regex; import std.algorithm; void foo(string bar) { split(bar, regex("_")); int[] test ; test.sort(); } void main(){} $ rdmd --force foo.d $ rdmd --version rdmd build 20140224 [...] What version are you using?
Comment #2 by puneet — 2014-08-26T00:18:51Z
(In reply to Cody Casterline from comment #1) > $ rdmd --force foo.d > $ rdmd --version > rdmd build 20140224 > [...] > > > > What version are you using? $ rdmd -version rdmd build 20140824 Today I also tried with version 20140826 -- same error. I am on a x86_64 architecture. The error does not show up with released version 2.066.
Comment #3 by bearophile_hugs — 2014-08-30T09:34:29Z
See also Issue 13400
Comment #4 by puneet — 2014-09-03T16:40:47Z
(In reply to bearophile_hugs from comment #3) > See also Issue 13400 Seems to be working with the latest DMD.