Fix for OpenMP C++ standalone: if the number of synapses was not divisible by the number of threads, not all synapses where always included in the last thread

(cherry picked from commit 66a462cc4bde6e9dda020fbdc294527c5706df06)
New option optimisation_flags pref for cpp_standalone and moved
openmp_threads pref to devices

(cherry picked from commit a1ebd29db509b23531c2a7c7439b00e9e74ea78e)
Store the variable_indices in `CodeObject` instead of discarding them after code generation
Get rid of `indexing_class`, classes that don't want to use the standard indexing should set the `_indexing` attribute in their `__init__` function directly.
Simplify indexing interface, make `Indexing` class callable instead of using a `calc_indices` method
First step towards a more general indexing system where objects (e.g. subgroups) can be used directly as an argument where indices are expected.
Fix a bug in standalone introduced by the previous commit
Rename `._indexing` to `._indices`
Allow using `Morphology.indices[...]` in the same way as for groups. Extend the scope of `Morphology.__getitem__` and improve the error checking. Remove `Morphology.compartments` and `Morphology.compartment`.
Update compartmental examples to use the new indexing syntax
Allow using subgroups for indexing state variables
Allow the use of synaptic "subgroups" for specifying what to record/extract from a `StateMonitor`
Examples are nicer
Update docs for `Morphology`
[ci skip]
Remove accidentally duplicated lines.
Raise a warning for potentially ambiguous string expressions combined with groups used for indexing