fix 'ascii' codec can't encode characters

master
Bill 2 years ago
parent 7f8c57735d
commit 9caa1fa82a

@ -29,7 +29,8 @@ def exec(stmts, cxt = None, keep = False):
else: else:
generate(stmts_stmts, cxt) generate(stmts_stmts, cxt)
for q in cxt.queries: for q in cxt.queries:
cxt.print(q.strip()) if not q.startswith('O'):
cxt.print(q.strip())
return cxt return cxt
__all__ = ["initialize", "generate", "exec", "saved_cxt"] __all__ = ["initialize", "generate", "exec", "saved_cxt"]

@ -77,7 +77,7 @@ public:
} }
template<template <typename> class VT, typename T> template<template <typename> class VT, typename T>
void initfrom(VT<T>&& v, const char* name = "") { void initfrom(VT<T>&& v, const char* name = "") {
puts("rref"); // puts("rref");
ty = types::Types<_Ty>::getType(); ty = types::Types<_Ty>::getType();
this->size = v.size; this->size = v.size;
this->capacity = v.capacity; this->capacity = v.capacity;
@ -87,7 +87,7 @@ public:
} }
template<template <typename> class VT, typename T> template<template <typename> class VT, typename T>
void initfrom(VT<T>& v, const char* name = "") { void initfrom(VT<T>& v, const char* name = "") {
puts("lref"); // puts("lref");
ty = types::Types<_Ty>::getType(); ty = types::Types<_Ty>::getType();
this->size = v.size; this->size = v.size;
this->capacity = 0; this->capacity = 0;
@ -97,7 +97,7 @@ public:
} }
template<template <typename> class VT, typename T> template<template <typename> class VT, typename T>
void initfrom(const VT<T>& v, const char* name = "") { void initfrom(const VT<T>& v, const char* name = "") {
puts("constlref"); // puts("constlref");
ty = types::Types<_Ty>::getType(); ty = types::Types<_Ty>::getType();
this->size = v.size; this->size = v.size;
this->capacity = 0; this->capacity = 0;

Loading…
Cancel
Save