Bug 15872 – [ndslice] indexing a slice with an array causes an error inside ndslice
Status
RESOLVED
Resolution
FIXED
Severity
minor
Priority
P1
Component
phobos
Product
D
Version
D2
Platform
All
OS
All
Creation time
2016-04-04T16:49:00Z
Last change time
2016-04-11T20:06:53Z
Assigned to
nobody
Creator
ilyayaroshenko
Comments
Comment #0 by ilyayaroshenko — 2016-04-04T16:49:47Z
From Mir: https://github.com/DlangScience/mir/issues/14
------
e.g. mySlice[[1,2,3]] gives
/Users/john/.dub/packages/mir-0.10.2/source/mir/ndslice/slice.d(1556): Error: no property 'i' for type 'int[]'
/Users/john/.dub/packages/mir-0.10.2/source/mir/ndslice/slice.d(1557): Error: no property 'j' for type 'int[]'
/Users/john/.dub/packages/mir-0.10.2/source/mir/ndslice/slice.d(1557): Error: no property 'i' for type 'int[]'
test.d(8): Error: template instance mir.ndslice.slice.Slice!(3LU, ulong*).Slice.opIndex!(int[]) error instantiating
it should either work or should error at the API level, not internally.
Comment #1 by github-bugzilla — 2016-04-11T20:06:52Z