Issue 14920 - [REG2.067.0] SList.insertAfter on uninitialized list triggers assertion in _first
Summary: [REG2.067.0] SList.insertAfter on uninitialized list triggers assertion in _f...
Status: RESOLVED FIXED
Alias: None
Product: D
Classification: Unclassified
Component: phobos (show other issues)
Version: D2
Hardware: All All
: P1 regression
Assignee: No Owner
URL:
Keywords: pull
Depends on:
Blocks:
 
Reported: 2015-08-14 10:29 UTC by secondaryAccount
Modified: 2017-07-19 17:43 UTC (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description secondaryAccount 2015-08-14 10:29:39 UTC
see: http://forum.dlang.org/post/mqk2g7$pv8$1@digitalmars.com

import std.container: SList;

void main()
{
    SList!int tmp;

    tmp.insertAfter( tmp[], 3 );
}

triggers assertion in SList._first(), line 57 because the list is not initialized.

I am working on a PR.
Comment 1 ag0aep6g 2015-08-14 14:11:36 UTC
Works with 2.066, fails since 2.067, making this a regression.
Comment 3 github-bugzilla 2015-08-16 10:57:14 UTC
Commits pushed to stable at https://github.com/D-Programming-Language/phobos

https://github.com/D-Programming-Language/phobos/commit/0c28c7717437b10570677994112fc874e196d26a
fix issue 14920

https://github.com/D-Programming-Language/phobos/commit/aac09abf0a8f8624e81bbac4ded38b941cc768d9
Merge pull request #3557 from tosttost/issue_14920

fix issue 14920 - [REG2.067.0] SList.insertAfter on uninitialized list triggers assertion in _first targeting stable branch