mirror of
https://github.com/Z3Prover/z3
synced 2025-04-30 04:15:51 +00:00
Z3 sources
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
This commit is contained in:
parent
3f9edad676
commit
e9eab22e5c
1186 changed files with 381859 additions and 0 deletions
37
lib/pop_scopes.h
Normal file
37
lib/pop_scopes.h
Normal file
|
@ -0,0 +1,37 @@
|
|||
/*++
|
||||
Copyright (c) 2006 Microsoft Corporation
|
||||
|
||||
Module Name:
|
||||
|
||||
pop_scopes.h
|
||||
|
||||
Abstract:
|
||||
|
||||
<abstract>
|
||||
|
||||
Author:
|
||||
|
||||
Leonardo de Moura (leonardo) 2008-06-02.
|
||||
|
||||
Revision History:
|
||||
|
||||
--*/
|
||||
#ifndef _POP_SCOPES_H_
|
||||
#define _POP_SCOPES_H_
|
||||
|
||||
#define POP_SCOPES(_num_scopes, _lim, _trail, _action) \
|
||||
if (_num_scopes > 0) \
|
||||
{ \
|
||||
unsigned scope_lvl = _lim.size(); \
|
||||
unsigned new_lvl = scope_lvl - _num_scopes; \
|
||||
unsigned curr_size = _trail.size(); \
|
||||
unsigned old_size = _lim[new_lvl]; \
|
||||
for (unsigned i = curr_size-1; i >= old_size && i != static_cast<unsigned>(-1); --i) { \
|
||||
_action; \
|
||||
} \
|
||||
_trail.shrink(old_size); \
|
||||
_lim.shrink(new_lvl); \
|
||||
}
|
||||
|
||||
#endif /* _POP_SCOPES_H_ */
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue