File tree Expand file tree Collapse file tree 2 files changed +9
-3
lines changed
Expand file tree Collapse file tree 2 files changed +9
-3
lines changed Original file line number Diff line number Diff line change 22#include " Python.h"
33
44#include < cstdio>
5+ #include < exception>
56#include < iostream>
67#include < locale>
78
@@ -74,7 +75,7 @@ template <class _CharT> void stdio_filebuf<_CharT>::imbue(const std::locale &__l
7475 __encoding_ = __cv_->encoding ();
7576 __always_noconv_ = __cv_->always_noconv ();
7677 if (__encoding_ > __limit)
77- std::__throw_runtime_error (" unsupported locale for standard io" );
78+ throw std::runtime_error (" unsupported locale for standard io" );
7879}
7980template <class _CharT > typename stdio_filebuf<_CharT>::int_type stdio_filebuf<_CharT>::underflow() { return __getchar (false ); }
8081template <class _CharT > typename stdio_filebuf<_CharT>::int_type stdio_filebuf<_CharT>::uflow() { return __getchar (true ); }
Original file line number Diff line number Diff line change 11#!/usr/bin/env python3
22import os
3+ import platform
34import subprocess
4- from setuptools import setup , find_packages , Extension
5+ from setuptools import setup , Extension
56from setuptools .command .build_py import build_py as _build_py
67
78module_name = "libparse"
89__dir__ = os .path .dirname (os .path .abspath (__file__ ))
910
11+ compiler_opts = ["-std=c++11" , "-DFILTERLIB" ]
12+ if platform .system () == "Windows" :
13+ compiler_opts = ["/DFILTERLIB" ]
14+
1015ext = Extension (
1116 name = "_libparse" ,
1217 swig_opts = ["-c++" ],
1722 include_dirs = [
1823 "libparse" ,
1924 ],
20- extra_compile_args = [ "-std=c++11" , "-DFILTERLIB" ] ,
25+ extra_compile_args = compiler_opts ,
2126)
2227
2328class build_py (_build_py ):
You can’t perform that action at this time.
0 commit comments