@@ -1386,10 +1386,9 @@ class CppcheckData:
13861386 suppressions List of Suppressions
13871387 files Source files for elements occurred in this configuration
13881388
1389- The configurations property loads all configurations once and keeps them,
1390- which is best when the configurations are iterated more than once.
1391- iterconfigurations() parses the dump file on each call but creates one
1392- configuration at a time, which uses less memory for a single iteration.
1389+ To iterate more than once, use the configurations property: it parses the
1390+ dump file once and keeps all configurations. To iterate once, use
1391+ iterconfigurations(): it parses on each call but uses less memory.
13931392
13941393 To iterate through all configurations use such code:
13951394 @code
@@ -1450,9 +1449,8 @@ def __init__(self, filename):
14501449 def configurations (self ):
14511450 """
14521451 Return the list of all available Configuration objects.
1453- The configurations are loaded on the first access and kept, so later
1454- accesses and iterconfigurations() do not parse the dump file again.
1455- All configurations stay in memory as long as this object exists.
1452+ The list is loaded on first access and kept for later accesses and
1453+ iterconfigurations().
14561454 """
14571455 if self ._configurations is None :
14581456 self ._configurations = list (self .iterconfigurations ())
@@ -1462,10 +1460,8 @@ def iterconfigurations(self):
14621460 """
14631461 Create and return iterator for the available Configuration objects.
14641462 The iterator loops over all Configurations in the dump file tree, in document order.
1465- If the configurations property has been used then the kept configurations
1466- are returned. Otherwise the dump file is parsed and each configuration is
1467- created when the iterator reaches it, so a configuration can be freed when
1468- the caller is done with it. Each call parses the dump file again.
1463+ Uses the kept list if the configurations property has been accessed,
1464+ otherwise parses the dump file one configuration at a time.
14691465 """
14701466 if self ._configurations is not None :
14711467 yield from self ._configurations
0 commit comments