Change record status: 
Project: 
Introduced in branch: 
11.2.x
Introduced in version: 
11.2.0
Description: 

Before

Calling \Drupal\Core\Cache\RefinableCacheableDependencyTrait::addCacheableDependency with an object that did not implement \Drupal\Core\Cache\CacheableDependencyInterface would result in the page being uncacheable (max-age 0).

This is rarely what the developer intended. There are other ways to mark a page as uncacheable (e.g setting max-age to 0 explicitly)

After

In 12.0.0, the method \Drupal\Core\Cache\RefinableCacheableDependencyTrait::addCacheableDependency will be have a type hint of \Drupal\Core\Cache\CacheableDependencyInterface for the argument.
public function addCacheableDependency(CacheableDependencyInterface $other_object) {

Impacts: 
Module developers