summaryrefslogtreecommitdiff
path: root/thirdparty/libtheora/encapiwrapper.c
diff options
context:
space:
mode:
authorreduz <reduzio@gmail.com>2021-07-08 12:31:19 -0300
committerreduz <reduzio@gmail.com>2021-07-08 23:27:27 -0300
commita9c943bef9c800cea483558a7be7704ba76f2e8a (patch)
treef9f96c7c73774d099b3d176d10232c284b81c748 /thirdparty/libtheora/encapiwrapper.c
parent5db1f8b1abab2d6b8720afeb0bd346e8428e099f (diff)
Implement Range Iterators
This PR implements range iterators in the base containers (Vector, Map, List, Pair Set). Given several of these data structures will be replaced by more efficient versions, having a common iterator API will make this simpler. Iterating can be done as follows (examples): ```C++ //Vector<String> for(const String& I: vector) { } //List<String> for(const String& I: list) { } //Map<String,int> for(const KeyValue<String,int>&I : map) { print_line("key: "+I.key+" value: "+itos(I.value)); } //if intending to write the elements, reference can be used //Map<String,int> for(KeyValue<String,int>& I: map) { I.value = 25; //this will fail because key is always const //I.key = "hello" } ``` The containers are (for now) not STL compatible, since this would mean changing how they work internally (STL uses a special head/tail allocation for end(), while Godot Map/Set/List do not). The idea is to change the Godot versions to be more compatible with STL, but this will happen after conversion to new iterators have taken place.
Diffstat (limited to 'thirdparty/libtheora/encapiwrapper.c')
0 files changed, 0 insertions, 0 deletions