On 01/24/2016 10:37 PM, Enjoys Math wrote:
> class V(T) {
> public:
> this() {}
> V opIndex(size_t i, size_t j) {
> writeln("Hello, foo!");
> return this;
> }
> }
>
> main() {
> auto v = new V!int();
> auto u = v[3..4];// ERROR
> }
>
> Error:
> no [] operato
On Monday, 25 January 2016 at 06:37:13 UTC, Enjoys Math wrote:
class V(T) {
public:
this() {}
V opIndex(size_t i, size_t j) {
writeln("Hello, foo!");
return this;
}
}
main() {
auto v = new V!int();
auto u = v[3..4];// ERROR
}
Error:
no [] operator overload for t
class V(T) {
public:
this() {}
V opIndex(size_t i, size_t j) {
writeln("Hello, foo!");
return this;
}
}
main() {
auto v = new V!int();
auto u = v[3..4];// ERROR
}
Error:
no [] operator overload for type the_module.V!int