C++: Update the other version as well.

This commit is contained in:
Geoffrey White
2021-06-04 16:21:04 +01:00
parent 3c6a1f165b
commit 799e19bdc2

View File

@@ -11,8 +11,8 @@ class Link extends Top {
* Gets the length of the longest line in file `f`.
*/
pragma[nomagic]
private int maxCols(File f) { result = max(Location l | l.getFile() = f | [l.getStartColumn(), l.getEndColumn()]) }
private int maxCols(File f) { result = max(Location l | l.getFile() = f | l.getStartColumn().maximum(l.getEndColumn())) }
/**
* Gets the location of an element that has a link-to-definition (in a similar manner to
* `Location.charLoc`)