Skip to content

Commit c1fc349

Browse files
committed
Disallow coercion in type declarations.
1 parent cdf7870 commit c1fc349

File tree

134 files changed

+134
-156
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

134 files changed

+134
-156
lines changed

bin/mysqli_report.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22

33
// https://core.trac.wordpress.org/ticket/52825
44
mysqli_report( MYSQLI_REPORT_OFF );

classes/Activation.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Plugin activation handler.
44
*

classes/Backtrace.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Function call backtrace container.
44
*

classes/CLI.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Plugin CLI command.
44
*

classes/Collector.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Abstract data collector.
44
*

classes/Collectors.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Container for data collectors.
44
*

classes/Data.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Abstract data transfer object.
44
*/

classes/DataCollector.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Abstract data collector for structured data.
44
*

classes/Dispatcher.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Abstract dispatcher.
44
*

classes/Dispatchers.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Container for dispatchers.
44
*

classes/Hook.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Hook processor.
44
*

classes/Output.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Abstract output handler.
44
*

classes/Plugin.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Abstract plugin wrapper.
44
*

classes/QM.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* A convenience class for wrapping certain user-facing functionality.
44
*

classes/QM_Component.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Class representing a component.
44
*

classes/QM_DB.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Database class used by the database dropin.
44
*

classes/QueryMonitor.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* The main Query Monitor plugin class.
44
*

classes/Timer.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Timer that collects timing and memory usage.
44
*

classes/Util.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* General utilities class.
44
*

classes/debug_bar.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Mock 'Debug Bar' plugin class.
44
*

classes/debug_bar_panel.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Mock 'Debug Bar' panel class.
44
*

collectors/admin.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Admin screen collector.
44
*

collectors/assets.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Enqueued scripts and styles collector.
44
*

collectors/assets_scripts.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Enqueued scripts collector.
44
*

collectors/assets_styles.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Enqueued styles collector.
44
*

collectors/block_editor.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Block editor (née Gutenberg) collector.
44
*

collectors/cache.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Object cache collector.
44
*

collectors/caps.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* User capability check collector.
44
*

collectors/conditionals.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Template conditionals collector.
44
*

collectors/db_callers.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Database query calling function collector.
44
*

collectors/db_components.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Database query calling component collector.
44
*

collectors/db_dupes.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Duplicate database query collector.
44
*

collectors/db_queries.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Database query collector.
44
*

collectors/debug_bar.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Mock 'Debug Bar' data collector.
44
*

collectors/environment.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Environment data collector.
44
*

collectors/hooks.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Hooks and actions collector.
44
*

collectors/http.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* HTTP API request collector.
44
*

collectors/languages.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Language and locale collector.
44
*

collectors/logger.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* PSR-3 compatible logging collector.
44
*

collectors/multisite.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Multisite collector, used for monitoring use of `switch_to_blog()` and `restore_current_blog()`.
44
*

collectors/overview.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* General overview collector.
44
*

collectors/php_errors.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* PHP error collector.
44
*

collectors/raw_request.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22

33
if ( ! defined( 'ABSPATH' ) ) {
44
exit;

collectors/redirects.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* HTTP redirect collector.
44
*

collectors/request.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Request collector.
44
*

collectors/theme.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Template and theme collector.
44
*

collectors/timing.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Timing and profiling collector.
44
*

collectors/transients.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Transient storage collector.
44
*

data/admin.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Admin screen data transfer object.
44
*

data/assets.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Asset data transfer object.
44
*

data/block_editor.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Block editor data transfer object.
44
*

data/cache.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Cache data transfer object.
44
*

data/caps.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Cache data transfer object.
44
*

data/conditionals.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Conditionals data transfer object.
44
*

data/db_callers.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Database query callers data transfer object.
44
*

data/db_components.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Database query components data transfer object.
44
*

data/db_dupes.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Duplicate database queries data transfer object.
44
*

data/db_queries.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Database queries data transfer object.
44
*

data/environment.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Environment data transfer object.
44
*

data/fallback.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Fallback data transfer object for third-pary collectors that don't extend
44
* the new QM_DataCollector class.

data/hooks.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Hooks data transfer object.
44
*

data/http.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* HTTP data transfer object.
44
*

data/languages.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Languages data transfer object.
44
*

data/logger.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Logger data transfer object.
44
*

data/multisite.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Multisite data transfer object.
44
*

data/overview.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php declare(strict_types = 1);
22
/**
33
* Overview data transfer object.
44
*

0 commit comments

Comments
 (0)