Skip to content

Commit aba9487

Browse files
author
MALASHKIN Andrei
committed
forbid quering of chars
1 parent c282cb6 commit aba9487

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/JSONVar.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,9 @@ class JSONVar : public Printable {
8989
JSONVar operator[](const String& key);
9090
JSONVar operator[](int index);
9191
JSONVar operator[](const JSONVar& key);
92-
92+
#if __cplusplus >= 201103L || defined(__GXX_EXPERIMENTAL_CXX0X__)
93+
JSONVar operator[](const char) = delete;
94+
#endif
9395
int length() const;
9496
JSONVar keys() const;
9597
bool hasOwnProperty(const char* key) const;

0 commit comments

Comments
 (0)