Compare commits

..

No commits in common. "e84f86b2defb6c4ee9809776a9cb051f393e50ec" and "09367d35a4d131027c83bc8c459d088f36777312" have entirely different histories.

3 changed files with 12 additions and 6 deletions

View File

@ -24,6 +24,9 @@ jobs:
sudo apt-get update
sudo apt-get install -y gcc g++
- name: Set up CMake
uses: jwlawson/actions-setup-cmake@v1.10
- name: Test
run: |
cd include/pybind11/tests
@ -40,6 +43,9 @@ jobs:
- name: Set up MSVC
uses: ilammy/msvc-dev-cmd@v1
- name: Set up CMake
uses: jwlawson/actions-setup-cmake@v1.10
- name: Test
run: |
cd include\pybind11\tests
@ -59,6 +65,9 @@ jobs:
echo 'export PATH="/usr/local/opt/llvm/bin:$PATH"' >> ~/.zshrc
source ~/.zshrc
- name: Set up CMake
uses: jwlawson/actions-setup-cmake@v1.10
- name: Test
run: |
cd include/pybind11/tests

View File

@ -103,7 +103,7 @@ void c11_sbuf__write_quoted(c11_sbuf* self, c11_sv sv, char quote) {
if(i + u8bytes > sv.size) u8bytes = 0; // invalid utf8
if(u8bytes <= 1) {
// not a valid utf8 char, or ascii
if(!isprint((unsigned char)c)) {
if(!isprint(c)) {
unsigned char uc = (unsigned char)c;
c11_sbuf__write_cstrn(self, "\\x", 2);
c11_sbuf__write_char(self, PK_HEX_TABLE[uc >> 4]);

View File

@ -121,11 +121,8 @@ void Frame__gc_mark(py_Frame* self) {
int Frame__lineno(const py_Frame* self) {
int ip = self->ip;
if(ip >= 0)
return c11__getitem(BytecodeEx, &self->co->codes_ex, ip).lineno;
if(!self->is_locals_special)
return self->co->start_line;
return 0;
if(ip < 0) return 0;
return c11__getitem(BytecodeEx, &self->co->codes_ex, ip).lineno;
}
int Frame__iblock(const py_Frame* self) {