Skip to content

Commit

Permalink
- remove assignment to inputs
Browse files Browse the repository at this point in the history
git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@17938 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
  • Loading branch information
adrpo committed Oct 30, 2013
1 parent ed7cb57 commit 3531c24
Showing 1 changed file with 18 additions and 9 deletions.
27 changes: 18 additions & 9 deletions Compiler/Util/BaseHashTable.mo
Expand Up @@ -321,17 +321,26 @@ algorithm
end delete;

public function anyKeyInHashTable "Returns true if any of the keys are present in the hashtable. Stops and returns true upon first occurence"
input list<Key> keys;
input HashTable ht;
input list<Key> inKeys;
input HashTable inHt;
output Boolean res;
algorithm
res := matchcontinue(keys,ht)
local Key key;
case({},ht) then false;
case(key::keys,ht) equation
_ = get(key,ht);
then true;
case(_::keys,ht) then anyKeyInHashTable(keys,ht);
res := matchcontinue(inKeys,inHt)
local
Key key;
list<Key> keys;

case({}, _) then false;

case(key::keys, _)
equation
_ = get(key, inHt);
then
true;

case(_::keys, _)
then anyKeyInHashTable(keys, inHt);

end matchcontinue;
end anyKeyInHashTable;

Expand Down

0 comments on commit 3531c24

Please sign in to comment.