mirror of
https://github.com/ThePhD/sol2.git
synced 2024-03-22 13:10:44 +08:00
It has to be a reference, not a value. I mistakenly thought typename Table
was taken by reference... oh well. It's fixed now. I wish VC++ didn't choke so badly on decltype.
This commit is contained in:
parent
9624dd93e7
commit
009a79606a
|
@ -82,13 +82,13 @@ public:
|
|||
}
|
||||
|
||||
template<typename T>
|
||||
proxy<table, T> operator[](T&& key) {
|
||||
return proxy<table, T>(*this, std::forward<T>(key));
|
||||
proxy<table&, T> operator[](T&& key) {
|
||||
return proxy<table&, T>(*this, std::forward<T>(key));
|
||||
}
|
||||
|
||||
template<typename T>
|
||||
proxy<const table, T> operator[](T&& key) const {
|
||||
return proxy<const table, T>(*this, std::forward<T>(key));
|
||||
proxy<const table&, T> operator[](T&& key) const {
|
||||
return proxy<const table&, T>(*this, std::forward<T>(key));
|
||||
}
|
||||
|
||||
size_t size() const {
|
||||
|
|
Loading…
Reference in New Issue
Block a user