1 --- a/shedskin/lib/builtin.hpp 2 +++ b/shedskin/lib/builtin.hpp 3 @@ -1203,10 +1203,10 @@ 4 #include "builtin/list.hpp" 5 #include "builtin/tuple.hpp" 6 #include "builtin/str.hpp" 7 +#include "builtin/math.hpp" 8 #include "builtin/dict.hpp" 9 #include "builtin/set.hpp" 10 #include "builtin/file.hpp" 11 -#include "builtin/math.hpp" 12 #include "builtin/format.hpp" 13 #include "builtin/function.hpp" 14 #include "builtin/complex.hpp" 15 --- a/shedskin/lib/collections.hpp 16 +++ b/shedskin/lib/collections.hpp 17 @@ -237,7 +237,7 @@ 18 V __getitem__(K key) { 19 register long hash = hasher<K>(key); 20 register dictentry<K, V> *entry; 21 - entry = lookup(key, hash); 22 + entry = this->lookup(key, hash); 23 if (entry->use != active) 24 return __missing__(key); 25 return entry->value; 26 @@ -255,10 +255,10 @@ 27 void *__addtoitem__(K key, V value) { /* XXX */ 28 register long hash = hasher<K>(key); 29 register dictentry<K, V> *entry; 30 - entry = lookup(key, hash); 31 + entry = this->lookup(key, hash); 32 if (entry->use != active) { 33 if(func) 34 - __setitem__(key, __add(func(), value)); 35 + this->__setitem__(key, __add(func(), value)); 36 else 37 throw new KeyError(repr(key)); 38 } else 39 @@ -281,7 +281,7 @@ 40 PyObject *iter = PyObject_GetIter(p); 41 while(key = PyIter_Next(iter)) { 42 value = PyDict_GetItem(p, key); 43 - __setitem__(__to_ss<K>(key), __to_ss<V>(value)); 44 + this->__setitem__(__to_ss<K>(key), __to_ss<V>(value)); 45 Py_DECREF(key); 46 } 47 Py_DECREF(iter); 48 --- a/shedskin/lib/os/__init__.cpp 49 +++ b/shedskin/lib/os/__init__.cpp 50 @@ -23,9 +23,7 @@ 51 #include <sysexits.h> 52 #endif 53 54 -namespace std { 55 #include <unistd.h> 56 -} 57 58 #ifdef WIN32 59 #include <windows.h> 60 --- a/shedskin/lib/socket.cpp 61 +++ b/shedskin/lib/socket.cpp 62 @@ -13,6 +13,7 @@ 63 #include "socket.hpp" 64 #include <climits> 65 #include <fcntl.h> 66 +#include <unistd.h> 67 68 #ifdef WIN32 69