Report a bug
If you spot a problem with this page, click here to create a Bugzilla issue.
Improve this page
Quickly fork, edit online, and submit a pull request for this page. Requires a signed-in GitHub account. This works well for small changes. If you'd like to make larger changes you may want to consider using a local clone.

Change Log: 2.075.0 (upcoming)

previous version: 2.074.0

Download D nightlies
To be released

List of all upcoming bug fixes and enhancements.

Compiler changes

  1. The builtin Ddoc theme has been overhauled.

    Dmd will now use more modern looking theme for generated documentation, also see dmd#6173.

  2. New command line option -mscrtlib=libname for Windows MS-COFF object files.

    If building MS-COFF object files with -m64 or -m32mscoff, this option specifies the reference to the C runtime library libname that is embedded into the object file containing main, DllMain or WinMain for automatic linking. The default is libcmt (release version with static linkage), the other usual alternatives are libcmtd, msvcrt and msvcrtd. If libname is empty, no C runtime library is automatically linked in.

Library changes

  1. Added std.algorithm.searching.minIndex to get the index of the minimum element of a range.

    std.algorithm.searching.minIndex gets the index of the minimum element of a range, according to a specified predicate. The default predicate is "a < b".

    import std.algorithm.searching : minIndex;
    int[] a = [5, 4, 2, 1, 9, 10];
    assert(a.minIndex == 3);
    int[] a;
    assert(a.minIndex == -1);
  2. Added std.meta.staticIsSorted to check if an AliasSeq is sorted according to some template predicate.

    std.meta.staticIsSorted checks whether an AliasSeq is sorted according to some template predicate.

    enum Comp(T1, T2) = T1.sizeof < T2.sizeof;
    import std.meta : staticIsSorted;
    static assert( staticIsSorted!(Comp, byte, uint, double));
    static assert(!staticIsSorted!(Comp, bool, long, dchar));

    Additionally, the compile-time performance of std.meta.staticSort has been greatly improved. Nevertheless, due to compiler limitations it is still an extraordinarily expensive operation to perform on longer sequences; strive to minimize such use.

  3. Added std.algorithm.searching.maxIndex to get the index of the maximum element of a range.

    std.algorithm.searching.maxIndex gets the index of the maximum element of a range, according to a specified predicate. The default predicate is "a > b".

    import std.algorithm.searching : maxIndex;
    int[] a = [5, 4, 2, 1, 9, 10];
    assert(a.minIndex == 5);
    int[] a;
    assert(a.minIndex == -1);
  4. Added std.traits.Promoted to get the result of scalar type promotion in multi-term arithmetic expressions

    std.traits.Promoted gets the type to which a scalar type will be promoted in multi-term arithmetic expressions

    import std.traits : Promoted;
    static assert(is(typeof(ubyte(3) * ubyte(5)) == Promoted!ubyte));
    static assert(is(Promoted!ubyte == int));

    See the D specification on scalar type promotions for more information.

  5. std.traits.hasFunctionAttributes has been added

    It exposes a user-friendly way to query for function attributes:

    import std.traits : hasFunctionAttributes;
    // manually annotated function
    real func(real x) pure nothrow @safe
        return x;
    static assert(hasFunctionAttributes!(func, "@safe", "pure"));
    static assert(!hasFunctionAttributes!(func, "@trusted"));
    // for templated function types are automatically inferred
    bool myFunc(T)(T b)
        return !b;
    static assert(hasFunctionAttributes!(myFunc!bool, "@safe", "pure", "@nogc", "nothrow"));
    static assert(!hasFunctionAttributes!(myFunc!bool, "shared"));
  6. std.experimental.ndslice has been deprecated.

    The synchronization between Phobos and Mir turned out to be a lot of work with litte gain. Users of std.experimental.ndslice are advised to switch to the upstream mir package.

List of all bug fixes and enhancements in D 2.075.0 (upcoming):

DMD Compiler regressions

  1. Bugzilla 16408: [REG2.065] left-to-right order of evaluation of function arguments not consistently followed
  2. Bugzilla 17275: [REG 2.072.0] AssertError@declaration.d(2121): Assertion failure
  3. Bugzilla 17293: "Using C++ Classes From D" example no longer works
  4. Bugzilla 17338: [Reg 2.075] link failure unsupported symbol section 0xff01
  5. Bugzilla 17356: [Reg 2.075] __simd_sto no longer executed
  6. Bugzilla 17399: [REG2.071] core.checkedint.addu cannot inline function
  7. Bugzilla 17407: [REG2.067] __traits(compiles) triggers assertion failure
  8. Bugzilla 17451: ICE in ddmd/declaration.d(2179)
  9. Bugzilla 17505: [REG2.075] @safe constructor requires the deconstructor to be safe as well
  10. Bugzilla 17506: [REG2.075] @disable constructor requires members to be initialized
  11. Bugzilla 17522: win64.mak broken
  12. Bugzilla 17582: [REG2.059] Applying const to struct declaration should make the struct type const

DMD Compiler bugs

  1. Bugzilla 4014: CodeView debug type info not linked in from library
  2. Bugzilla 7016: local import does not create -deps dependency
  3. Bugzilla 11881: -betterC switch suffers from bit rot
  4. Bugzilla 13331: naked asm functions are broken when compiling with -profile
  5. Bugzilla 13512: Allow non-UTF-8 encoding in shebang line
  6. Bugzilla 14246: RAII - proper destruction of partially constructed objects/structs
  7. Bugzilla 15896: private ignored when import bindings are used
  8. Bugzilla 15945: sizeof on an invalid type seems to compile.
  9. Bugzilla 16244: compiler ICE on complex typeof() for method arg type
  10. Bugzilla 16566: hasLength should enforce that length has type size_t
  11. Bugzilla 16640: void fun(string file=__FILE_FULL_PATH__) returns relative path
  12. Bugzilla 17289: With Xcode 8.3 linker, warnings of "pointer not aligned"
  13. Bugzilla 17335: Function calls in conjunctions do not short circuit when evaluated during compilation
  14. Bugzilla 17337: SIGILL for AVX vector initialization
  15. Bugzilla 17339: ambiguous mangling with const alias argument
  16. Bugzilla 17344: ICE with assignment of post inc-/decremented integral vector
  17. Bugzilla 17349: Covariant overrides should be allowed
  18. Bugzilla 17367: CodeView/MSCOFF: bad debug information for enumerators
  19. Bugzilla 17391: SECURITY: XSS through DDOC comments
  20. Bugzilla 17422: [scope] class reference not initialized as scope variable
  21. Bugzilla 17432: [DIP1000] scope delegates change type, but not mangling
  22. Bugzilla 17450: escaping delegate context pointer not detected for member functions
  23. Bugzilla 17468: Internal assertion fails during CTFE
  24. Bugzilla 17489: ICE in ddmd/argtypes.d
  25. Bugzilla 17491: Compiles on invalid: *&s.init.var is not an lvalue
  26. Bugzilla 17495: __traits(getParameterStorageClasses) doesn't work with tuples as parameters
  27. Bugzilla 17551: VC build: bad mangling of real template argument

DMD Compiler enhancements

  1. Bugzilla 6227: Comparison of different enums
  2. Bugzilla 16197: Constructors/postblits and destructors don't match up for array initialisation
  3. Bugzilla 16540: Attributes do not propagate correctly in lazy params
  4. Bugzilla 16600: Wrong error message for ambiguous mutable/immutable constructor
  5. Bugzilla 17396: Add colorized syntax highlighting to error messages emitted by dmd
  6. Bugzilla 17419: add __traits(getLinkage, s) to the the linkage of symbol s
  7. Bugzilla 17425: add __traits(getParameterStorageClasses, f, i)
  8. Bugzilla 17429: [scope] each scope class references adds another delete call
  9. Bugzilla 17457: Named Return Value Optimization (NRVO) not done with return of constructor call
  10. Bugzilla 17494: Do not execute scope(...) if an Error exception has been thrown
  11. Bugzilla 17499: with -betterC switch, call C's assert failure function rather than druntime's
  12. Bugzilla 17521: -betterC programs should not link in Phobos runtime library by default

Phobos regressions

  1. Bugzilla 17264: [REG2.073] uniq fails with const elements
  2. Bugzilla 17330: [REG 2.072] BigInt's constructor used to be pure
  3. Bugzilla 17340: [REG 2.074.0] isNumeric!bool should not be true
  4. Bugzilla 17452: Undefined references in std.container.array
  5. Bugzilla 17472: [Reg 2.075] typeof(stdin) is no longer a File

Phobos bugs

  1. Bugzilla 12866: Append to std.container.Array of fixed size arrays
  2. Bugzilla 15517: std.experimental.logger: using 'sharedLog' to change to file logging for default logger does not work
  3. Bugzilla 15534: [std.experimental.logger.core] Documentation mismatch
  4. Bugzilla 15720: iota(long.max, long.min, step) does not work properly
  5. Bugzilla 15763: std.math.approxEqual is not symmetric
  6. Bugzilla 16232: std.experimental.logger.core.sharedLog isn't thread-safe
  7. Bugzilla 16246: cannot call iota with 3 [u]bytes or 3 [u]shorts
  8. Bugzilla 16256: std.experimental.logger cant log a dstring properly
  9. Bugzilla 16326: filter is not lazy enough & has weird save behavior
  10. Bugzilla 17251: Appender.put errors out with const input range elements
  11. Bugzilla 17270: std.experimental.Final fails on pointers
  12. Bugzilla 17283: std.experimental.typecons uses private module members
  13. Bugzilla 17288: formattedWrite error when width/precision provided and no value to format
  14. Bugzilla 17314: BinaryHeap crashes upon insertion if heapified with an array of length 1
  15. Bugzilla 17328: std.experimental.logger: wrong hex formatting for zeros
  16. Bugzilla 17389: std.traits.hasNested fails for class with member of same type
  17. Bugzilla 17519: RedBlackTree doesn't like const/immutable elements
  18. Bugzilla 17562: Tangent function returns NaN for abs(input) >= 2^63
  19. Bugzilla 17574: Range violation in std.getopt:getopt AA parsing

Phobos enhancements

  1. Bugzilla 6621: Superimposition amount for std.range.chunks
  2. Bugzilla 7102: std.numeric.gcd with BigInts too
  3. Bugzilla 10001: string formatting with underscores
  4. Bugzilla 16108: to!string fails on struct with disabled postblit
  5. Bugzilla 16615: std.process is missing functionality for child processes
  6. Bugzilla 17286: A function for comparing two digests securely
  7. Bugzilla 17327: std.getopt: repeated options unrecognised
  8. Bugzilla 17394: std.file.mkdirRecurse isn't @safe

Druntime bugs

  1. Bugzilla 9275: [GC] removeRoot hits assert(0) instead of being a no-op (as documented)
  2. Bugzilla 12233: Attempting to use TypeInfo.init results in a compiler error due to lack of 'this'.
  3. Bugzilla 13186: core/sys/posix/sys/uio.d is not linked into the standard lib bugs

  1. Bugzilla 8107: Float literals are not specified as they are implemented
  2. Bugzilla 17224: Foreach documentation still refers to TypeTuples, rather than AliasSequences
  3. Bugzilla 17303: type error in the href url under the link Systems Programming
  4. Bugzilla 17305: [SPEC] ABI page still has references to D1 Phobos
  5. Bugzilla 17469: View source code
  6. Bugzilla 17501: Runnable unittest problem with AST rewrite
  7. Bugzilla 17509: [typo] "refered to" ("referred to")
  8. Bugzilla 17510: How could 509 be a byte value?
  9. Bugzilla 17513: [english] "a enum" -> "an enum" enhancements

  1. Bugzilla 17262: Better docs for rdmd
  2. Bugzilla 17322: Add Magikcraft to organizations using D
  3. Bugzilla 17524: [The C Preprocessor vs D] "need to worry about"?
  4. Bugzilla 17560: Enhancement: view and copy full code example for offline compile/play
previous version: 2.074.0