this is a first step towards porting the code `constructions.cpp` to Lean: It leaves the construction of the `Declaration` untouched, but moves adding the declarations to the environment, and setting various attributes, to the Lean world. This allows the remaining logic (the construction of the `Declaration`) to be implemented in Lean separately and easily compared to the C++ implementation, before we replace that too. To that end, `Declaraion` gains an `BEq` instance. --------- Co-authored-by: Leonardo de Moura <leomoura@amazon.com> Co-authored-by: Arthur Adjedj <arthur.adjedj@ens-paris-saclay.fr>
47 lines
1 KiB
C++
47 lines
1 KiB
C++
/*
|
|
Copyright (c) 2014 Microsoft Corporation. All rights reserved.
|
|
Released under Apache 2.0 license as described in the file LICENSE.
|
|
|
|
Author: Leonardo de Moura
|
|
*/
|
|
#include "library/constants.h"
|
|
#include "library/class.h"
|
|
#include "library/num.h"
|
|
#include "library/annotation.h"
|
|
#include "library/print.h"
|
|
#include "library/util.h"
|
|
#include "library/profiling.h"
|
|
#include "library/time_task.h"
|
|
#include "library/formatter.h"
|
|
|
|
namespace lean {
|
|
void initialize_library_core_module() {
|
|
initialize_formatter();
|
|
initialize_constants();
|
|
initialize_profiling();
|
|
}
|
|
|
|
void finalize_library_core_module() {
|
|
finalize_profiling();
|
|
finalize_constants();
|
|
finalize_formatter();
|
|
}
|
|
|
|
void initialize_library_module() {
|
|
initialize_print();
|
|
initialize_num();
|
|
initialize_annotation();
|
|
initialize_class();
|
|
initialize_library_util();
|
|
initialize_time_task();
|
|
}
|
|
|
|
void finalize_library_module() {
|
|
finalize_time_task();
|
|
finalize_library_util();
|
|
finalize_class();
|
|
finalize_annotation();
|
|
finalize_num();
|
|
finalize_print();
|
|
}
|
|
}
|