Python: Rename cursor => Cursor in PEP249

Notice that since this will be part of the same PR as 5cfc433, it is OK
to do this change without keeping `PEP249::cursor` for backwards
compatibility.
This commit is contained in:
Rasmus Wriedt Larsen
2021-06-25 17:30:35 +02:00
parent d8db83d081
commit 1317ae298c
2 changed files with 4 additions and 4 deletions

View File

@@ -28,9 +28,9 @@ deprecated class PEP249ModuleApiNode = PEP249::PEP249ModuleApiNode;
deprecated module Connection = PEP249::Connection;
/**
* DEPRECATED: Use `PEP249::cursor` instead.
* DEPRECATED: Use `PEP249::Cursor` instead.
*/
deprecated module cursor = PEP249::cursor;
deprecated module cursor = PEP249::Cursor;
/**
* DEPRECATED: Use `PEP249::execute` instead.

View File

@@ -78,7 +78,7 @@ module PEP249 {
* These are are returned by the `cursor` method on a database connection.
* See https://www.python.org/dev/peps/pep-0249/#cursor.
*/
module cursor {
module Cursor {
/**
* A source of database cursors (following PEP 249), extend this class to model new instances.
*
@@ -148,7 +148,7 @@ module PEP249 {
*/
private DataFlow::LocalSourceNode execute(DataFlow::TypeTracker t) {
t.startInAttr("execute") and
result in [cursor::instance(), Connection::instance()]
result in [Cursor::instance(), Connection::instance()]
or
exists(DataFlow::TypeTracker t2 | result = execute(t2).track(t2, t))
}