Bug 14160 – [REG2.066] mutable global data access is wrongly accepted in pure function

Status
RESOLVED
Resolution
FIXED
Severity
regression
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2015-02-10T02:27:00Z
Last change time
2015-02-21T09:11:11Z
Keywords
accepts-invalid, pull
Assigned to
nobody
Creator
k.hara.pg

Comments

Comment #0 by k.hara.pg — 2015-02-10T02:27:29Z
Test case int g; int* f1() pure { return &g; // should be rejected, but doesn't }
Comment #1 by k.hara.pg — 2015-02-10T02:30:44Z
Comment #2 by k.hara.pg — 2015-02-10T03:03:50Z
Comment #3 by github-bugzilla — 2015-02-11T23:55:40Z
Commits pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/b6e8ef68dda3f306c70be659a69efa1db897798f fix Issue 14160 - mutable global data access is wrongly accepted in pure function https://github.com/D-Programming-Language/dmd/commit/abc775b2a8a08e07193d54dcbfc75b1bb34ee16d Merge pull request #4398 from 9rnsr/fix14160 [REG2.066] Issue 14160 - mutable global data access is wrongly accepted in pure function
Comment #4 by github-bugzilla — 2015-02-21T09:11:11Z