Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
gaoqiong
pybind11
Commits
08a89fac
Unverified
Commit
08a89fac
authored
Feb 04, 2023
by
Aaron Gokaslan
Committed by
GitHub
Feb 04, 2023
Browse files
bugfix: delete proper ctors in gil.h (#4490)
parent
3efe9d4c
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
include/pybind11/gil.h
include/pybind11/gil.h
+4
-4
No files found.
include/pybind11/gil.h
View file @
08a89fac
...
@@ -152,8 +152,8 @@ public:
...
@@ -152,8 +152,8 @@ public:
}
}
}
}
gil_scoped_release
(
const
gil_scoped_
acquir
e
&
)
=
delete
;
gil_scoped_release
(
const
gil_scoped_
releas
e
&
)
=
delete
;
gil_scoped_release
&
operator
=
(
const
gil_scoped_
acquir
e
&
)
=
delete
;
gil_scoped_release
&
operator
=
(
const
gil_scoped_
releas
e
&
)
=
delete
;
/// This method will disable the PyThreadState_DeleteCurrent call and the
/// This method will disable the PyThreadState_DeleteCurrent call and the
/// GIL won't be acquired. This method should be used if the interpreter
/// GIL won't be acquired. This method should be used if the interpreter
...
@@ -203,7 +203,7 @@ class gil_scoped_release {
...
@@ -203,7 +203,7 @@ class gil_scoped_release {
public:
public:
gil_scoped_release
()
:
state
{
PyEval_SaveThread
()}
{}
gil_scoped_release
()
:
state
{
PyEval_SaveThread
()}
{}
gil_scoped_release
(
const
gil_scoped_release
&
)
=
delete
;
gil_scoped_release
(
const
gil_scoped_release
&
)
=
delete
;
gil_scoped_release
&
operator
=
(
const
gil_scoped_
acquir
e
&
)
=
delete
;
gil_scoped_release
&
operator
=
(
const
gil_scoped_
releas
e
&
)
=
delete
;
~
gil_scoped_release
()
{
PyEval_RestoreThread
(
state
);
}
~
gil_scoped_release
()
{
PyEval_RestoreThread
(
state
);
}
void
disarm
()
{}
void
disarm
()
{}
};
};
...
@@ -230,7 +230,7 @@ public:
...
@@ -230,7 +230,7 @@ public:
(
void
)
(
this
!=
(
this
+
1
));
(
void
)
(
this
!=
(
this
+
1
));
}
}
gil_scoped_release
(
const
gil_scoped_release
&
)
=
delete
;
gil_scoped_release
(
const
gil_scoped_release
&
)
=
delete
;
gil_scoped_release
&
operator
=
(
const
gil_scoped_
acquir
e
&
)
=
delete
;
gil_scoped_release
&
operator
=
(
const
gil_scoped_
releas
e
&
)
=
delete
;
void
disarm
()
{}
void
disarm
()
{}
};
};
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment