From: Vladimír Vondruš Date: Tue, 27 Aug 2019 20:34:03 +0000 (+0200) Subject: documentation/python: poison entry types that shouldn't go into search. X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~cjwatson/git?a=commitdiff_plain;h=b209586b0c8aef4027b05891bef1e1b267ec9cb7;p=blog.git documentation/python: poison entry types that shouldn't go into search. Spent a while using OVERLOADED_FUNCTION in a few places just to discover it wasn't meant to be used there. --- diff --git a/documentation/python.py b/documentation/python.py index d494e642..235620b5 100755 --- a/documentation/python.py +++ b/documentation/python.py @@ -73,15 +73,16 @@ class EntryType(Enum): ENUM_VALUE = 7 DATA = 8 - # Types not exposed to search are below + # Types not exposed to search are below. Deliberately set to large values + # so their accidental use triggers assertions when building search data. # One of files from special_pages. Doesn't make sense to include in the # search. - SPECIAL = 9 + SPECIAL = 99 # Denotes a potentially overloaded pybind11 function. Has to be here to # be able to distinguish between zero-argument normal and pybind11 # functions. To search it's exposed as FUNCTION. - OVERLOADED_FUNCTION = 10 + OVERLOADED_FUNCTION = 100 # Order must match the EntryType above search_type_map = [