chore(stage0, runtime): update stage0 and remove old String API

This commit is contained in:
Leonardo de Moura 2019-03-26 15:51:13 -07:00
parent b29fb57fcf
commit 4b83585103
21 changed files with 3519 additions and 3566 deletions

View file

@ -1697,12 +1697,6 @@ obj_res string_utf8_set(obj_arg s, b_obj_arg i0, uint32 c) {
return mk_string(new_s);
}
uint32 string_utf8_get_old(b_obj_arg s, usize i) { return string_utf8_get(s, box(i)); }
usize string_utf8_next_old(b_obj_arg s, usize i) { return unbox(string_utf8_next(s, box(i))); }
usize string_utf8_prev_old(b_obj_arg s, usize i) { return unbox(string_utf8_prev(s, box(i))); }
obj_res string_utf8_set_old(obj_arg s, usize i, uint32 c) { return string_utf8_set(s, box(i), c); }
obj_res string_utf8_extract_old(b_obj_arg s, usize b, usize e) { return string_utf8_extract(s, box(b), box(e)); }
// =======================================
// array functions for generated code

View file

@ -1196,14 +1196,6 @@ inline uint8 string_utf8_at_end(b_obj_arg s, b_obj_arg i) { return !is_scalar(i)
obj_res string_utf8_extract(b_obj_arg s, b_obj_arg b, b_obj_arg e);
inline obj_res string_utf8_byte_size(b_obj_arg s) { return mk_nat_obj(string_size(s) - 1); }
uint32 string_utf8_get_old(b_obj_arg s, usize i);
usize string_utf8_next_old(b_obj_arg s, usize i);
usize string_utf8_prev_old(b_obj_arg s, usize i);
obj_res string_utf8_set_old(obj_arg s, usize i, uint32 c);
inline uint8 string_utf8_at_end_old(b_obj_arg s, usize i) { return i >= string_size(s) - 1; }
obj_res string_utf8_extract_old(b_obj_arg s, usize b, usize e);
inline usize string_utf8_byte_size_old(b_obj_arg s) { return string_size(s) - 1; }
inline bool string_eq(b_obj_arg s1, b_obj_arg s2) { return s1 == s2 || (string_size(s1) == string_size(s2) && std::memcmp(string_cstr(s1), string_cstr(s2), string_size(s1)) == 0); }
bool string_eq(b_obj_arg s1, char const * s2);
inline bool string_ne(b_obj_arg s1, b_obj_arg s2) { return !string_eq(s1, s2); }

View file

@ -14,9 +14,9 @@ typedef lean::uint32 uint32; typedef lean::uint64 uint64;
#pragma GCC diagnostic ignored "-Wunused-label"
#pragma GCC diagnostic ignored "-Wunused-but-set-variable"
#endif
extern usize l_String_toSubstring___closed__1;
obj* l_String_Hashable;
usize l_Nat_hash(obj*);
obj* l_mixHash___closed__1___boxed;
usize l_String_hash(obj*);
obj* l_String_hash___boxed(obj*);
obj* l_Nat_Hashable;
@ -26,14 +26,33 @@ namespace lean {
usize usize_of_nat(obj*);
}
obj* l_Nat_hash___boxed(obj*);
usize l_mixHash___closed__1;
usize _init_l_mixHash___closed__1() {
_start:
{
obj* x_0; usize x_1;
x_0 = lean::mk_nat_obj(0ul);
x_1 = lean::usize_of_nat(x_0);
return x_1;
}
}
usize l_mixHash(usize x_0, usize x_1) {
_start:
{
usize x_2;
x_2 = l_String_toSubstring___closed__1;
x_2 = l_mixHash___closed__1;
return x_2;
}
}
obj* _init_l_mixHash___closed__1___boxed() {
_start:
{
usize x_0; obj* x_1;
x_0 = l_mixHash___closed__1;
x_1 = lean::box_size_t(x_0);
return x_1;
}
}
obj* l_mixHash___boxed(obj* x_0, obj* x_1) {
_start:
{
@ -49,7 +68,7 @@ usize l_String_hash(obj* x_0) {
_start:
{
usize x_1;
x_1 = l_String_toSubstring___closed__1;
x_1 = l_mixHash___closed__1;
return x_1;
}
}
@ -107,6 +126,9 @@ if (io_result_is_error(w)) return w;
w = initialize_init_data_uint(w);
if (io_result_is_error(w)) return w;
w = initialize_init_data_string_default(w);
l_mixHash___closed__1 = _init_l_mixHash___closed__1();
l_mixHash___closed__1___boxed = _init_l_mixHash___closed__1___boxed();
lean::mark_persistent(l_mixHash___closed__1___boxed);
l_String_Hashable = _init_l_String_Hashable();
lean::mark_persistent(l_String_Hashable);
l_Nat_Hashable = _init_l_Nat_Hashable();

View file

@ -29,7 +29,6 @@ obj* nat2int(obj*);
namespace lean {
obj* int_sub(obj*, obj*);
}
extern usize l_String_toSubstring___closed__1;
obj* l_Int_HasDiv;
namespace lean {
obj* int_neg_succ_of_nat(obj*);
@ -60,7 +59,7 @@ obj* l_Int_HasZero;
obj* l_Int_HasOne;
obj* l_Nat_repr(obj*);
obj* l_Int_HasMod;
usize l_String_toInt___closed__1;
obj* l_String_toInt___closed__1;
namespace lean {
obj* string_append(obj*, obj*);
}
@ -83,10 +82,9 @@ obj* l_Int_HasSub;
obj* l_Int_sign___main(obj*);
uint8 l_String_isInt___closed__1;
namespace lean {
uint32 string_utf8_get_old(obj*, usize);
uint32 string_utf8_get(obj*, obj*);
}
obj* l_String_isInt___closed__1___boxed;
obj* l_String_toInt___closed__2;
obj* l_Int_decLt___boxed(obj*, obj*);
obj* l_Int_repr___main___closed__1;
obj* l_Int_HasNeg;
@ -107,13 +105,13 @@ namespace lean {
obj* nat_abs(obj*);
}
namespace lean {
usize usize_of_nat(obj*);
uint8 nat_dec_le(obj*, obj*);
}
obj* l_Int_subNatNat___boxed(obj*, obj*);
obj* l_Int_negOfNat(obj*);
obj* l_Int_sign___main___closed__1;
namespace lean {
usize string_utf8_byte_size_old(obj*);
obj* string_utf8_byte_size(obj*);
}
obj* l_Int_decEq___boxed(obj*, obj*);
obj* l_Int_repr___main___boxed(obj*);
@ -126,7 +124,6 @@ namespace lean {
uint8 int_dec_le(obj*, obj*);
}
obj* l_Int_natMod___boxed(obj*, obj*);
obj* l_String_toInt___closed__1___boxed;
obj* l_Int_sub___boxed(obj*, obj*);
namespace lean {
uint8 int_dec_lt(obj*, obj*);
@ -674,46 +671,30 @@ lean::dec(x_1);
return x_2;
}
}
usize _init_l_String_toInt___closed__1() {
obj* _init_l_String_toInt___closed__1() {
_start:
{
obj* x_0; usize x_1; obj* x_2; usize x_3; usize x_4;
x_0 = lean::mk_nat_obj(0ul);
x_1 = lean::usize_of_nat(x_0);
x_2 = lean::mk_nat_obj(1ul);
x_3 = lean::usize_of_nat(x_2);
x_4 = x_1 + x_3;
return x_4;
}
}
obj* _init_l_String_toInt___closed__2() {
_start:
{
obj* x_0; usize x_1; obj* x_2; usize x_3; obj* x_4; obj* x_5; obj* x_6; obj* x_7; obj* x_9; obj* x_10;
x_0 = lean::mk_nat_obj(0ul);
x_1 = lean::usize_of_nat(x_0);
x_2 = lean::mk_string("");
x_3 = lean::string_utf8_byte_size_old(x_2);
x_4 = lean::alloc_cnstr(0, 1, sizeof(size_t)*2);
lean::cnstr_set(x_4, 0, x_2);
lean::cnstr_set_scalar(x_4, sizeof(void*)*1, x_1);
x_5 = x_4;
lean::cnstr_set_scalar(x_5, sizeof(void*)*2, x_3);
x_6 = x_5;
x_7 = l_Substring_toNat(x_6);
lean::dec(x_6);
x_9 = lean::nat2int(x_7);
x_10 = lean::int_neg(x_9);
lean::dec(x_9);
return x_10;
obj* x_0; obj* x_1; obj* x_2; obj* x_3; obj* x_4; obj* x_5; obj* x_6;
x_0 = lean::mk_string("");
x_1 = lean::string_utf8_byte_size(x_0);
x_2 = lean::mk_nat_obj(0ul);
x_3 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_3, 0, x_0);
lean::cnstr_set(x_3, 1, x_2);
lean::cnstr_set(x_3, 2, x_1);
x_4 = l_Substring_toNat(x_3);
x_5 = lean::nat2int(x_4);
x_6 = lean::int_neg(x_5);
lean::dec(x_5);
return x_6;
}
}
obj* l_String_toInt(obj* x_0) {
_start:
{
usize x_1; uint32 x_2; uint32 x_3; uint8 x_4;
x_1 = l_String_toSubstring___closed__1;
x_2 = lean::string_utf8_get_old(x_0, x_1);
obj* x_1; uint32 x_2; uint32 x_3; uint8 x_4;
x_1 = lean::mk_nat_obj(0ul);
x_2 = lean::string_utf8_get(x_0, x_1);
x_3 = 45;
x_4 = x_2 == x_3;
if (x_4 == 0)
@ -726,70 +707,55 @@ return x_7;
}
else
{
usize x_8; usize x_9; uint8 x_10;
x_8 = lean::string_utf8_byte_size_old(x_0);
x_9 = l_String_toInt___closed__1;
x_10 = x_8 <= x_9;
obj* x_8; obj* x_9; uint8 x_10;
x_8 = lean::string_utf8_byte_size(x_0);
x_9 = lean::mk_nat_obj(1ul);
x_10 = lean::nat_dec_le(x_8, x_9);
if (x_10 == 0)
{
obj* x_11; obj* x_12; obj* x_13; obj* x_14; obj* x_16; obj* x_17;
x_11 = lean::alloc_cnstr(0, 1, sizeof(size_t)*2);
obj* x_11; obj* x_12; obj* x_13; obj* x_14;
x_11 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_11, 0, x_0);
lean::cnstr_set_scalar(x_11, sizeof(void*)*1, x_9);
x_12 = x_11;
lean::cnstr_set_scalar(x_12, sizeof(void*)*2, x_8);
x_13 = x_12;
x_14 = l_Substring_toNat(x_13);
lean::cnstr_set(x_11, 1, x_9);
lean::cnstr_set(x_11, 2, x_8);
x_12 = l_Substring_toNat(x_11);
x_13 = lean::nat2int(x_12);
x_14 = lean::int_neg(x_13);
lean::dec(x_13);
x_16 = lean::nat2int(x_14);
x_17 = lean::int_neg(x_16);
lean::dec(x_16);
return x_17;
return x_14;
}
else
{
obj* x_20;
obj* x_18;
lean::dec(x_0);
x_20 = l_String_toInt___closed__2;
return x_20;
lean::dec(x_8);
x_18 = l_String_toInt___closed__1;
return x_18;
}
}
}
}
obj* _init_l_String_toInt___closed__1___boxed() {
_start:
{
usize x_0; obj* x_1;
x_0 = l_String_toInt___closed__1;
x_1 = lean::box_size_t(x_0);
return x_1;
}
}
uint8 _init_l_String_isInt___closed__1() {
_start:
{
obj* x_0; usize x_1; obj* x_2; usize x_3; obj* x_4; obj* x_5; obj* x_6; uint8 x_7;
x_0 = lean::mk_nat_obj(0ul);
x_1 = lean::usize_of_nat(x_0);
x_2 = lean::mk_string("");
x_3 = lean::string_utf8_byte_size_old(x_2);
x_4 = lean::alloc_cnstr(0, 1, sizeof(size_t)*2);
lean::cnstr_set(x_4, 0, x_2);
lean::cnstr_set_scalar(x_4, sizeof(void*)*1, x_1);
x_5 = x_4;
lean::cnstr_set_scalar(x_5, sizeof(void*)*2, x_3);
x_6 = x_5;
x_7 = l_Substring_isNat(x_6);
lean::dec(x_6);
return x_7;
obj* x_0; obj* x_1; obj* x_2; obj* x_3; uint8 x_4;
x_0 = lean::mk_string("");
x_1 = lean::string_utf8_byte_size(x_0);
x_2 = lean::mk_nat_obj(0ul);
x_3 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_3, 0, x_0);
lean::cnstr_set(x_3, 1, x_2);
lean::cnstr_set(x_3, 2, x_1);
x_4 = l_Substring_isNat(x_3);
return x_4;
}
}
uint8 l_String_isInt(obj* x_0) {
_start:
{
usize x_1; uint32 x_2; uint32 x_3; uint8 x_4;
x_1 = l_String_toSubstring___closed__1;
x_2 = lean::string_utf8_get_old(x_0, x_1);
obj* x_1; uint32 x_2; uint32 x_3; uint8 x_4;
x_1 = lean::mk_nat_obj(0ul);
x_2 = lean::string_utf8_get(x_0, x_1);
x_3 = 45;
x_4 = x_2 == x_3;
if (x_4 == 0)
@ -801,29 +767,27 @@ return x_5;
}
else
{
usize x_7; usize x_8; uint8 x_9;
x_7 = lean::string_utf8_byte_size_old(x_0);
x_8 = l_String_toInt___closed__1;
x_9 = x_7 <= x_8;
obj* x_7; obj* x_8; uint8 x_9;
x_7 = lean::string_utf8_byte_size(x_0);
x_8 = lean::mk_nat_obj(1ul);
x_9 = lean::nat_dec_le(x_7, x_8);
if (x_9 == 0)
{
obj* x_10; obj* x_11; obj* x_12; uint8 x_13;
x_10 = lean::alloc_cnstr(0, 1, sizeof(size_t)*2);
obj* x_10; uint8 x_11;
x_10 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_10, 0, x_0);
lean::cnstr_set_scalar(x_10, sizeof(void*)*1, x_8);
x_11 = x_10;
lean::cnstr_set_scalar(x_11, sizeof(void*)*2, x_7);
x_12 = x_11;
x_13 = l_Substring_isNat(x_12);
lean::dec(x_12);
return x_13;
lean::cnstr_set(x_10, 1, x_8);
lean::cnstr_set(x_10, 2, x_7);
x_11 = l_Substring_isNat(x_10);
return x_11;
}
else
{
uint8 x_16;
uint8 x_14;
lean::dec(x_7);
lean::dec(x_0);
x_16 = l_String_isInt___closed__1;
return x_16;
x_14 = l_String_isInt___closed__1;
return x_14;
}
}
}
@ -902,10 +866,7 @@ lean::mark_persistent(l_Int_HasDiv);
l_Int_HasMod = _init_l_Int_HasMod();
lean::mark_persistent(l_Int_HasMod);
l_String_toInt___closed__1 = _init_l_String_toInt___closed__1();
l_String_toInt___closed__2 = _init_l_String_toInt___closed__2();
lean::mark_persistent(l_String_toInt___closed__2);
l_String_toInt___closed__1___boxed = _init_l_String_toInt___closed__1___boxed();
lean::mark_persistent(l_String_toInt___closed__1___boxed);
lean::mark_persistent(l_String_toInt___closed__1);
l_String_isInt___closed__1 = _init_l_String_isInt___closed__1();
l_String_isInt___closed__1___boxed = _init_l_String_isInt___closed__1___boxed();
lean::mark_persistent(l_String_isInt___closed__1___boxed);

View file

@ -137,7 +137,7 @@ namespace lean {
uint8 nat_dec_le(obj*, obj*);
}
namespace lean {
obj* string_utf8_extract_old(obj*, usize, usize);
obj* string_utf8_extract(obj*, obj*, obj*);
}
namespace lean {
obj* string_mk(obj*);
@ -1477,11 +1477,11 @@ return x_0;
obj* l_Substring_HasRepr(obj* x_0) {
_start:
{
obj* x_1; usize x_2; usize x_3; obj* x_4; obj* x_5; obj* x_6; obj* x_7;
obj* x_1; obj* x_2; obj* x_3; obj* x_4; obj* x_5; obj* x_6; obj* x_7;
x_1 = lean::cnstr_get(x_0, 0);
x_2 = lean::cnstr_get_scalar<usize>(x_0, sizeof(void*)*1);
x_3 = lean::cnstr_get_scalar<usize>(x_0, sizeof(void*)*2);
x_4 = lean::string_utf8_extract_old(x_1, x_2, x_3);
x_2 = lean::cnstr_get(x_0, 1);
x_3 = lean::cnstr_get(x_0, 2);
x_4 = lean::string_utf8_extract(x_1, x_2, x_3);
x_5 = l_String_quote(x_4);
x_6 = l_Substring_HasRepr___closed__1;
x_7 = lean::string_append(x_5, x_6);

File diff suppressed because it is too large Load diff

View file

@ -97,7 +97,7 @@ obj* l_Fin_HasToString___boxed(obj*);
obj* l_String_HasToString(obj*);
obj* l_Decidable_HasToString___rarg___boxed(obj*);
namespace lean {
obj* string_utf8_extract_old(obj*, usize, usize);
obj* string_utf8_extract(obj*, obj*, obj*);
}
obj* l_List_toStringAux___boxed(obj*);
obj* l_id_HasToString___rarg___boxed(obj*);
@ -174,11 +174,11 @@ return x_1;
obj* l_Substring_HasToString(obj* x_0) {
_start:
{
obj* x_1; usize x_2; usize x_3; obj* x_4;
obj* x_1; obj* x_2; obj* x_3; obj* x_4;
x_1 = lean::cnstr_get(x_0, 0);
x_2 = lean::cnstr_get_scalar<usize>(x_0, sizeof(void*)*1);
x_3 = lean::cnstr_get_scalar<usize>(x_0, sizeof(void*)*2);
x_4 = lean::string_utf8_extract_old(x_1, x_2, x_3);
x_2 = lean::cnstr_get(x_0, 1);
x_3 = lean::cnstr_get(x_0, 2);
x_4 = lean::string_utf8_extract(x_1, x_2, x_3);
return x_4;
}
}

View file

@ -32,7 +32,6 @@ obj* mk_adhoc_ext_entry_core(obj*);
namespace lean {
obj* mk_foreign_ext_entry_core(obj*, obj*);
}
extern usize l_String_toSubstring___closed__1;
obj* l_List_intersperse___main___rarg(obj*, obj*);
obj* l_Lean_expandExternEntry(obj*, obj*);
obj* l_Lean_getExternEntryForAux___main___closed__1;
@ -333,16 +332,15 @@ namespace lean {
obj* expand_extern_pattern_core(obj* x_0, obj* x_1) {
_start:
{
obj* x_2; usize x_3; obj* x_4; obj* x_5; obj* x_6; obj* x_7;
obj* x_2; obj* x_3; obj* x_4; obj* x_5; obj* x_6;
x_2 = lean::string_length(x_0);
x_3 = l_String_toSubstring___closed__1;
x_4 = lean::alloc_cnstr(0, 1, sizeof(size_t)*1);
x_3 = lean::mk_nat_obj(0ul);
x_4 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_4, 0, x_0);
lean::cnstr_set_scalar(x_4, sizeof(void*)*1, x_3);
x_5 = x_4;
x_6 = l_String_splitAux___main___closed__1;
x_7 = l_Lean_expandExternPatternAux___main(x_1, x_2, x_5, x_6);
return x_7;
lean::cnstr_set(x_4, 1, x_3);
x_5 = l_String_splitAux___main___closed__1;
x_6 = l_Lean_expandExternPatternAux___main(x_1, x_2, x_4, x_5);
return x_6;
}
}
}

View file

@ -33,7 +33,6 @@ uint8 l_String_isEmpty(obj*);
obj* l_Lean_Parser_parseHexDigit___at___private_init_lean_name__mangling_2__parseMangledStringAux___main___spec__2(obj*);
extern obj* l_Lean_Parser_parseHexDigit___rarg___lambda__3___closed__1;
obj* l_Lean_Parser_MonadParsec_ch___at___private_init_lean_name__mangling_5__parseMangledNameAux___main___spec__1(uint32, obj*);
extern usize l_String_toSubstring___closed__1;
obj* l_Lean_Name_mangle___boxed(obj*, obj*);
extern obj* l_Lean_Parser_MonadParsec_eoi___rarg___lambda__1___closed__1;
extern obj* l_mjoin___rarg___closed__1;
@ -307,16 +306,15 @@ return x_3;
obj* l_Lean_String_mangle(obj* x_0) {
_start:
{
obj* x_1; usize x_2; obj* x_3; obj* x_4; obj* x_5; obj* x_6;
obj* x_1; obj* x_2; obj* x_3; obj* x_4; obj* x_5;
x_1 = lean::string_length(x_0);
x_2 = l_String_toSubstring___closed__1;
x_3 = lean::alloc_cnstr(0, 1, sizeof(size_t)*1);
x_2 = lean::mk_nat_obj(0ul);
x_3 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_3, 0, x_0);
lean::cnstr_set_scalar(x_3, sizeof(void*)*1, x_2);
x_4 = x_3;
x_5 = l_String_splitAux___main___closed__1;
x_6 = l___private_init_lean_name__mangling_1__String_mangleAux___main(x_1, x_4, x_5);
return x_6;
lean::cnstr_set(x_3, 1, x_2);
x_4 = l_String_splitAux___main___closed__1;
x_5 = l___private_init_lean_name__mangling_1__String_mangleAux___main(x_1, x_3, x_4);
return x_5;
}
}
obj* l_Lean_Parser_MonadParsec_strCore___at___private_init_lean_name__mangling_2__parseMangledStringAux___main___spec__1(obj* x_0, obj* x_1, obj* x_2) {
@ -326,64 +324,62 @@ uint8 x_3;
x_3 = l_String_isEmpty(x_0);
if (x_3 == 0)
{
obj* x_4; obj* x_5; usize x_6; obj* x_8; obj* x_9; obj* x_11;
obj* x_4; obj* x_5; obj* x_7; obj* x_9;
x_4 = lean::string_length(x_0);
x_5 = lean::mk_nat_obj(0ul);
x_6 = l_String_toSubstring___closed__1;
lean::inc(x_0);
x_8 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
lean::cnstr_set(x_8, 0, x_0);
lean::cnstr_set(x_8, 1, x_5);
lean::cnstr_set_scalar(x_8, sizeof(void*)*2, x_6);
x_9 = x_8;
x_7 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_7, 0, x_0);
lean::cnstr_set(x_7, 1, x_5);
lean::cnstr_set(x_7, 2, x_5);
lean::inc(x_2);
x_11 = l___private_init_lean_parser_parsec_2__strAux___main(x_4, x_9, x_2);
if (lean::obj_tag(x_11) == 0)
x_9 = l___private_init_lean_parser_parsec_2__strAux___main(x_4, x_7, x_2);
if (lean::obj_tag(x_9) == 0)
{
obj* x_13; obj* x_14; obj* x_15; uint8 x_16; obj* x_17; obj* x_18;
obj* x_11; obj* x_12; obj* x_13; uint8 x_14; obj* x_15; obj* x_16;
lean::dec(x_0);
x_13 = lean::box(0);
x_14 = l_String_splitAux___main___closed__1;
x_15 = lean::alloc_cnstr(0, 4, 0);
lean::cnstr_set(x_15, 0, x_2);
lean::cnstr_set(x_15, 1, x_14);
lean::cnstr_set(x_15, 2, x_1);
lean::cnstr_set(x_15, 3, x_13);
x_16 = 0;
x_17 = lean::alloc_cnstr(1, 1, 1);
lean::cnstr_set(x_17, 0, x_15);
lean::cnstr_set_scalar(x_17, sizeof(void*)*1, x_16);
x_18 = x_17;
return x_18;
x_11 = lean::box(0);
x_12 = l_String_splitAux___main___closed__1;
x_13 = lean::alloc_cnstr(0, 4, 0);
lean::cnstr_set(x_13, 0, x_2);
lean::cnstr_set(x_13, 1, x_12);
lean::cnstr_set(x_13, 2, x_1);
lean::cnstr_set(x_13, 3, x_11);
x_14 = 0;
x_15 = lean::alloc_cnstr(1, 1, 1);
lean::cnstr_set(x_15, 0, x_13);
lean::cnstr_set_scalar(x_15, sizeof(void*)*1, x_14);
x_16 = x_15;
return x_16;
}
else
{
obj* x_21; obj* x_24; obj* x_25;
obj* x_19; obj* x_22; obj* x_23;
lean::dec(x_1);
lean::dec(x_2);
x_21 = lean::cnstr_get(x_11, 0);
lean::inc(x_21);
lean::dec(x_11);
x_24 = lean::box(0);
x_25 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_25, 0, x_0);
lean::cnstr_set(x_25, 1, x_21);
lean::cnstr_set(x_25, 2, x_24);
return x_25;
x_19 = lean::cnstr_get(x_9, 0);
lean::inc(x_19);
lean::dec(x_9);
x_22 = lean::box(0);
x_23 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_23, 0, x_0);
lean::cnstr_set(x_23, 1, x_19);
lean::cnstr_set(x_23, 2, x_22);
return x_23;
}
}
else
{
obj* x_28; obj* x_29; obj* x_30;
obj* x_26; obj* x_27; obj* x_28;
lean::dec(x_1);
lean::dec(x_0);
x_28 = l_String_splitAux___main___closed__1;
x_29 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
x_30 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_30, 0, x_28);
lean::cnstr_set(x_30, 1, x_2);
lean::cnstr_set(x_30, 2, x_29);
return x_30;
x_26 = l_String_splitAux___main___closed__1;
x_27 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
x_28 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_28, 0, x_26);
lean::cnstr_set(x_28, 1, x_2);
lean::cnstr_set(x_28, 2, x_27);
return x_28;
}
}
}

View file

@ -38,7 +38,6 @@ extern obj* l_Lean_Parser_Trie_mk___closed__1;
obj* l_Lean_Parser_messageOfParsecMessage(obj*);
obj* l_Lean_Parser_MonadRec_trans___rarg___boxed(obj*, obj*, obj*, obj*);
obj* l_Lean_Parser_ParserT_Lean_Parser_MonadParsec___rarg(obj*);
extern usize l_String_toSubstring___closed__1;
obj* l_Lean_Parser_logMessage___rarg(obj*, obj*, obj*, obj*, obj*);
obj* l_Lean_Parser_TokenMap_ofList___rarg(obj*);
obj* l_Lean_Parser_ParserT_Alternative___rarg(obj*);
@ -1038,21 +1037,19 @@ return x_33;
obj* l_Lean_Parser_ParsecT_run___at_Lean_Parser_run___spec__1___rarg(obj* x_0, obj* x_1, obj* x_2, obj* x_3, obj* x_4, obj* x_5, obj* x_6) {
_start:
{
obj* x_7; usize x_8; obj* x_9; obj* x_10; obj* x_11; obj* x_13; obj* x_14; obj* x_15;
obj* x_7; obj* x_8; obj* x_9; obj* x_11; obj* x_12; obj* x_13;
x_7 = lean::mk_nat_obj(0ul);
x_8 = l_String_toSubstring___closed__1;
x_9 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
lean::cnstr_set(x_9, 0, x_4);
lean::cnstr_set(x_9, 1, x_7);
lean::cnstr_set_scalar(x_9, sizeof(void*)*2, x_8);
x_10 = x_9;
x_11 = lean::cnstr_get(x_0, 1);
lean::inc(x_11);
x_13 = lean::apply_2(x_3, x_10, x_6);
x_14 = lean::alloc_closure(reinterpret_cast<void*>(l_Lean_Parser_ParsecT_run___at_Lean_Parser_run___spec__1___rarg___lambda__1), 2, 1);
lean::closure_set(x_14, 0, x_0);
x_15 = lean::apply_4(x_11, lean::box(0), lean::box(0), x_13, x_14);
return x_15;
x_8 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_8, 0, x_4);
lean::cnstr_set(x_8, 1, x_7);
lean::cnstr_set(x_8, 2, x_7);
x_9 = lean::cnstr_get(x_0, 1);
lean::inc(x_9);
x_11 = lean::apply_2(x_3, x_8, x_6);
x_12 = lean::alloc_closure(reinterpret_cast<void*>(l_Lean_Parser_ParsecT_run___at_Lean_Parser_run___spec__1___rarg___lambda__1), 2, 1);
lean::closure_set(x_12, 0, x_0);
x_13 = lean::apply_4(x_9, lean::box(0), lean::box(0), x_11, x_12);
return x_13;
}
}
obj* l_Lean_Parser_ParsecT_run___at_Lean_Parser_run___spec__1(obj* x_0) {

View file

@ -78,7 +78,6 @@ obj* l_Lean_Parser_command_univParams_HasView_x_27___lambda__1___closed__1;
extern obj* l_Lean_Parser_Combinators_choiceAux___main___rarg___closed__1;
obj* l_Lean_Parser_command_extends_HasView_x_27___lambda__1___closed__3;
obj* l_Lean_Parser_command_axiom_HasView_x_27;
extern usize l_String_toSubstring___closed__1;
obj* l_Lean_Parser_command_declAttributes_HasView_x_27___lambda__1___closed__2;
obj* l_List_mfoldl___main___at_Lean_Parser_command_docComment_Parser___spec__5(obj*, obj*, obj*, obj*, obj*, obj*, obj*);
obj* l_Lean_Parser_command_oldUnivParams_Parser_Lean_Parser_HasView;
@ -1445,73 +1444,71 @@ uint8 x_6;
x_6 = l_String_isEmpty(x_0);
if (x_6 == 0)
{
obj* x_7; obj* x_8; usize x_9; obj* x_11; obj* x_12; obj* x_14;
obj* x_7; obj* x_8; obj* x_10; obj* x_12;
x_7 = lean::string_length(x_0);
x_8 = lean::mk_nat_obj(0ul);
x_9 = l_String_toSubstring___closed__1;
lean::inc(x_0);
x_11 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
lean::cnstr_set(x_11, 0, x_0);
lean::cnstr_set(x_11, 1, x_8);
lean::cnstr_set_scalar(x_11, sizeof(void*)*2, x_9);
x_12 = x_11;
x_10 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_10, 0, x_0);
lean::cnstr_set(x_10, 1, x_8);
lean::cnstr_set(x_10, 2, x_8);
lean::inc(x_4);
x_14 = l___private_init_lean_parser_parsec_2__strAux___main(x_7, x_12, x_4);
if (lean::obj_tag(x_14) == 0)
x_12 = l___private_init_lean_parser_parsec_2__strAux___main(x_7, x_10, x_4);
if (lean::obj_tag(x_12) == 0)
{
obj* x_16; obj* x_17; obj* x_18; uint8 x_19; obj* x_20; obj* x_21; obj* x_22;
obj* x_14; obj* x_15; obj* x_16; uint8 x_17; obj* x_18; obj* x_19; obj* x_20;
lean::dec(x_0);
x_16 = lean::box(0);
x_17 = l_String_splitAux___main___closed__1;
x_18 = lean::alloc_cnstr(0, 4, 0);
lean::cnstr_set(x_18, 0, x_4);
lean::cnstr_set(x_18, 1, x_17);
lean::cnstr_set(x_18, 2, x_1);
lean::cnstr_set(x_18, 3, x_16);
x_19 = 0;
x_20 = lean::alloc_cnstr(1, 1, 1);
lean::cnstr_set(x_20, 0, x_18);
lean::cnstr_set_scalar(x_20, sizeof(void*)*1, x_19);
x_21 = x_20;
x_22 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_22, 0, x_21);
lean::cnstr_set(x_22, 1, x_5);
return x_22;
x_14 = lean::box(0);
x_15 = l_String_splitAux___main___closed__1;
x_16 = lean::alloc_cnstr(0, 4, 0);
lean::cnstr_set(x_16, 0, x_4);
lean::cnstr_set(x_16, 1, x_15);
lean::cnstr_set(x_16, 2, x_1);
lean::cnstr_set(x_16, 3, x_14);
x_17 = 0;
x_18 = lean::alloc_cnstr(1, 1, 1);
lean::cnstr_set(x_18, 0, x_16);
lean::cnstr_set_scalar(x_18, sizeof(void*)*1, x_17);
x_19 = x_18;
x_20 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_20, 0, x_19);
lean::cnstr_set(x_20, 1, x_5);
return x_20;
}
else
{
obj* x_25; obj* x_28; obj* x_29; obj* x_30;
obj* x_23; obj* x_26; obj* x_27; obj* x_28;
lean::dec(x_4);
lean::dec(x_1);
x_25 = lean::cnstr_get(x_14, 0);
lean::inc(x_25);
lean::dec(x_14);
x_28 = lean::box(0);
x_29 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_29, 0, x_0);
lean::cnstr_set(x_29, 1, x_25);
lean::cnstr_set(x_29, 2, x_28);
x_30 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_30, 0, x_29);
lean::cnstr_set(x_30, 1, x_5);
return x_30;
x_23 = lean::cnstr_get(x_12, 0);
lean::inc(x_23);
lean::dec(x_12);
x_26 = lean::box(0);
x_27 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_27, 0, x_0);
lean::cnstr_set(x_27, 1, x_23);
lean::cnstr_set(x_27, 2, x_26);
x_28 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_28, 0, x_27);
lean::cnstr_set(x_28, 1, x_5);
return x_28;
}
}
else
{
obj* x_33; obj* x_34; obj* x_35; obj* x_36;
obj* x_31; obj* x_32; obj* x_33; obj* x_34;
lean::dec(x_1);
lean::dec(x_0);
x_33 = l_String_splitAux___main___closed__1;
x_34 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
x_35 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_35, 0, x_33);
lean::cnstr_set(x_35, 1, x_4);
lean::cnstr_set(x_35, 2, x_34);
x_36 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_36, 0, x_35);
lean::cnstr_set(x_36, 1, x_5);
return x_36;
x_31 = l_String_splitAux___main___closed__1;
x_32 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
x_33 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_33, 0, x_31);
lean::cnstr_set(x_33, 1, x_4);
lean::cnstr_set(x_33, 2, x_32);
x_34 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_34, 0, x_33);
lean::cnstr_set(x_34, 1, x_5);
return x_34;
}
}
}

View file

@ -38,7 +38,6 @@ obj* l_Lean_Parser_Combinators_node___at_Lean_Parser_Level_paren_Parser___spec__
obj* l_Lean_Parser_Level_Parser_Lean_Parser_HasTokens___closed__1;
extern obj* l_Lean_Parser_Combinators_choiceAux___main___rarg___closed__1;
obj* l_Lean_Parser_MonadRec_trans___rarg___boxed(obj*, obj*, obj*, obj*);
extern usize l_String_toSubstring___closed__1;
obj* l_Lean_Parser_Level_trailing_HasView;
obj* l_Lean_Parser_Level_leading_HasView_x_27___lambda__1___closed__5;
extern obj* l_mjoin___rarg___closed__1;
@ -5889,7 +5888,7 @@ lean::dec(x_9);
switch (lean::obj_tag(x_26)) {
case 0:
{
obj* x_29; obj* x_32; obj* x_35; obj* x_37; obj* x_39; obj* x_40; obj* x_43; obj* x_45; usize x_46; obj* x_47; obj* x_48; obj* x_49;
obj* x_29; obj* x_32; obj* x_35; obj* x_37; obj* x_39; obj* x_40; obj* x_43; obj* x_45; obj* x_46; obj* x_47;
x_29 = lean::cnstr_get(x_26, 0);
lean::inc(x_29);
lean::dec(x_26);
@ -5915,330 +5914,328 @@ lean::dec(x_29);
x_43 = lean::cnstr_get(x_1, 1);
lean::inc(x_43);
x_45 = lean::mk_nat_obj(0ul);
x_46 = l_String_toSubstring___closed__1;
x_47 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
lean::cnstr_set(x_47, 0, x_40);
lean::cnstr_set(x_47, 1, x_45);
lean::cnstr_set_scalar(x_47, sizeof(void*)*2, x_46);
x_48 = x_47;
x_49 = l_Lean_Parser_Trie_matchPrefix___rarg(x_43, x_48);
if (lean::obj_tag(x_49) == 0)
x_46 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_46, 0, x_40);
lean::cnstr_set(x_46, 1, x_45);
lean::cnstr_set(x_46, 2, x_45);
x_47 = l_Lean_Parser_Trie_matchPrefix___rarg(x_43, x_46);
if (lean::obj_tag(x_47) == 0)
{
obj* x_51; obj* x_52; obj* x_53; obj* x_54; obj* x_57; obj* x_59; obj* x_61; obj* x_62; obj* x_63; obj* x_64; obj* x_65; obj* x_66;
obj* x_49; obj* x_50; obj* x_51; obj* x_52; obj* x_55; obj* x_57; obj* x_59; obj* x_60; obj* x_61; obj* x_62; obj* x_63; obj* x_64;
lean::dec(x_39);
x_51 = lean::box(0);
x_52 = l_Lean_Parser_currLbp___rarg___lambda__1___closed__1;
x_53 = l_mjoin___rarg___closed__1;
x_54 = l_Lean_Parser_MonadParsec_error___at_Lean_Parser_levelParser_run___spec__3___rarg(x_52, x_53, x_51, x_51, x_0, x_1, x_35, x_32);
x_49 = lean::box(0);
x_50 = l_Lean_Parser_currLbp___rarg___lambda__1___closed__1;
x_51 = l_mjoin___rarg___closed__1;
x_52 = l_Lean_Parser_MonadParsec_error___at_Lean_Parser_levelParser_run___spec__3___rarg(x_50, x_51, x_49, x_49, x_0, x_1, x_35, x_32);
lean::dec(x_35);
lean::dec(x_1);
x_57 = lean::cnstr_get(x_54, 0);
x_59 = lean::cnstr_get(x_54, 1);
if (lean::is_exclusive(x_54)) {
x_61 = x_54;
x_55 = lean::cnstr_get(x_52, 0);
x_57 = lean::cnstr_get(x_52, 1);
if (lean::is_exclusive(x_52)) {
x_59 = x_52;
} else {
lean::inc(x_55);
lean::inc(x_57);
lean::inc(x_59);
lean::dec(x_54);
x_61 = lean::box(0);
lean::dec(x_52);
x_59 = lean::box(0);
}
x_62 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
x_63 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_62, x_57);
x_64 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_62, x_63);
x_65 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_37, x_64);
if (lean::is_scalar(x_61)) {
x_66 = lean::alloc_cnstr(0, 2, 0);
x_60 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
x_61 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_60, x_55);
x_62 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_60, x_61);
x_63 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_37, x_62);
if (lean::is_scalar(x_59)) {
x_64 = lean::alloc_cnstr(0, 2, 0);
} else {
x_66 = x_61;
x_64 = x_59;
}
lean::cnstr_set(x_66, 0, x_65);
lean::cnstr_set(x_66, 1, x_59);
return x_66;
lean::cnstr_set(x_64, 0, x_63);
lean::cnstr_set(x_64, 1, x_57);
return x_64;
}
else
{
obj* x_68; obj* x_71; obj* x_73; obj* x_74; obj* x_77; obj* x_78; obj* x_79; obj* x_80;
obj* x_66; obj* x_69; obj* x_71; obj* x_72; obj* x_75; obj* x_76; obj* x_77; obj* x_78;
lean::dec(x_1);
x_68 = lean::cnstr_get(x_49, 0);
lean::inc(x_68);
lean::dec(x_49);
x_71 = lean::cnstr_get(x_68, 1);
if (lean::is_exclusive(x_68)) {
lean::cnstr_release(x_68, 0);
x_73 = x_68;
x_66 = lean::cnstr_get(x_47, 0);
lean::inc(x_66);
lean::dec(x_47);
x_69 = lean::cnstr_get(x_66, 1);
if (lean::is_exclusive(x_66)) {
lean::cnstr_release(x_66, 0);
x_71 = x_66;
} else {
lean::inc(x_71);
lean::dec(x_68);
x_73 = lean::box(0);
lean::inc(x_69);
lean::dec(x_66);
x_71 = lean::box(0);
}
x_74 = lean::cnstr_get(x_71, 1);
lean::inc(x_74);
lean::dec(x_71);
x_77 = l_Lean_Parser_matchToken___closed__1;
x_72 = lean::cnstr_get(x_69, 1);
lean::inc(x_72);
lean::dec(x_69);
x_75 = l_Lean_Parser_matchToken___closed__1;
if (lean::is_scalar(x_39)) {
x_78 = lean::alloc_cnstr(0, 3, 0);
x_76 = lean::alloc_cnstr(0, 3, 0);
} else {
x_78 = x_39;
x_76 = x_39;
}
lean::cnstr_set(x_78, 0, x_74);
lean::cnstr_set(x_78, 1, x_35);
lean::cnstr_set(x_78, 2, x_77);
x_79 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_37, x_78);
if (lean::is_scalar(x_73)) {
x_80 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_76, 0, x_72);
lean::cnstr_set(x_76, 1, x_35);
lean::cnstr_set(x_76, 2, x_75);
x_77 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_37, x_76);
if (lean::is_scalar(x_71)) {
x_78 = lean::alloc_cnstr(0, 2, 0);
} else {
x_80 = x_73;
x_78 = x_71;
}
lean::cnstr_set(x_80, 0, x_79);
lean::cnstr_set(x_80, 1, x_32);
return x_80;
lean::cnstr_set(x_78, 0, x_77);
lean::cnstr_set(x_78, 1, x_32);
return x_78;
}
}
case 1:
{
obj* x_83; obj* x_85; obj* x_86; obj* x_88; obj* x_90; obj* x_91; obj* x_92; obj* x_93; obj* x_94; obj* x_95;
obj* x_81; obj* x_83; obj* x_84; obj* x_86; obj* x_88; obj* x_89; obj* x_90; obj* x_91; obj* x_92; obj* x_93;
lean::dec(x_1);
lean::dec(x_26);
x_83 = lean::cnstr_get(x_6, 1);
x_81 = lean::cnstr_get(x_6, 1);
if (lean::is_exclusive(x_6)) {
lean::cnstr_release(x_6, 0);
x_85 = x_6;
x_83 = x_6;
} else {
lean::inc(x_83);
lean::inc(x_81);
lean::dec(x_6);
x_85 = lean::box(0);
x_83 = lean::box(0);
}
x_86 = lean::cnstr_get(x_7, 1);
x_88 = lean::cnstr_get(x_7, 2);
x_84 = lean::cnstr_get(x_7, 1);
x_86 = lean::cnstr_get(x_7, 2);
if (lean::is_exclusive(x_7)) {
lean::cnstr_release(x_7, 0);
x_90 = x_7;
x_88 = x_7;
} else {
lean::inc(x_84);
lean::inc(x_86);
lean::inc(x_88);
lean::dec(x_7);
x_90 = lean::box(0);
x_88 = lean::box(0);
}
x_91 = l_Lean_Parser_maxPrec;
x_92 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
if (lean::is_scalar(x_90)) {
x_93 = lean::alloc_cnstr(0, 3, 0);
x_89 = l_Lean_Parser_maxPrec;
x_90 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
if (lean::is_scalar(x_88)) {
x_91 = lean::alloc_cnstr(0, 3, 0);
} else {
x_93 = x_90;
x_91 = x_88;
}
lean::cnstr_set(x_93, 0, x_91);
lean::cnstr_set(x_93, 1, x_86);
lean::cnstr_set(x_93, 2, x_92);
x_94 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_88, x_93);
if (lean::is_scalar(x_85)) {
x_95 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_91, 0, x_89);
lean::cnstr_set(x_91, 1, x_84);
lean::cnstr_set(x_91, 2, x_90);
x_92 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_86, x_91);
if (lean::is_scalar(x_83)) {
x_93 = lean::alloc_cnstr(0, 2, 0);
} else {
x_95 = x_85;
x_93 = x_83;
}
lean::cnstr_set(x_95, 0, x_94);
lean::cnstr_set(x_95, 1, x_83);
return x_95;
lean::cnstr_set(x_93, 0, x_92);
lean::cnstr_set(x_93, 1, x_81);
return x_93;
}
case 2:
{
obj* x_96; obj* x_99; obj* x_101; obj* x_102; obj* x_104; obj* x_106; obj* x_107; obj* x_110; uint8 x_111;
x_96 = lean::cnstr_get(x_26, 0);
lean::inc(x_96);
obj* x_94; obj* x_97; obj* x_99; obj* x_100; obj* x_102; obj* x_104; obj* x_105; obj* x_108; uint8 x_109;
x_94 = lean::cnstr_get(x_26, 0);
lean::inc(x_94);
lean::dec(x_26);
x_99 = lean::cnstr_get(x_6, 1);
x_97 = lean::cnstr_get(x_6, 1);
if (lean::is_exclusive(x_6)) {
lean::cnstr_release(x_6, 0);
lean::cnstr_set(x_6, 1, lean::box(0));
x_101 = x_6;
x_99 = x_6;
} else {
lean::inc(x_99);
lean::inc(x_97);
lean::dec(x_6);
x_101 = lean::box(0);
x_99 = lean::box(0);
}
x_102 = lean::cnstr_get(x_7, 1);
x_104 = lean::cnstr_get(x_7, 2);
x_100 = lean::cnstr_get(x_7, 1);
x_102 = lean::cnstr_get(x_7, 2);
if (lean::is_exclusive(x_7)) {
lean::cnstr_release(x_7, 0);
lean::cnstr_set(x_7, 1, lean::box(0));
lean::cnstr_set(x_7, 2, lean::box(0));
x_106 = x_7;
x_104 = x_7;
} else {
lean::inc(x_100);
lean::inc(x_102);
lean::inc(x_104);
lean::dec(x_7);
x_106 = lean::box(0);
x_104 = lean::box(0);
}
x_107 = lean::cnstr_get(x_96, 0);
lean::inc(x_107);
lean::dec(x_96);
x_110 = l_Lean_Parser_number_HasView_x_27___lambda__1___closed__6;
x_111 = lean_name_dec_eq(x_107, x_110);
x_105 = lean::cnstr_get(x_94, 0);
lean::inc(x_105);
lean::dec(x_94);
x_108 = l_Lean_Parser_number_HasView_x_27___lambda__1___closed__6;
x_109 = lean_name_dec_eq(x_105, x_108);
if (x_109 == 0)
{
obj* x_110; uint8 x_111;
x_110 = l_Lean_Parser_currLbp___rarg___lambda__3___closed__1;
x_111 = lean_name_dec_eq(x_105, x_110);
lean::dec(x_105);
if (x_111 == 0)
{
obj* x_112; uint8 x_113;
x_112 = l_Lean_Parser_currLbp___rarg___lambda__3___closed__1;
x_113 = lean_name_dec_eq(x_107, x_112);
lean::dec(x_107);
if (x_113 == 0)
{
obj* x_117; obj* x_118; obj* x_119; obj* x_120; obj* x_123; obj* x_125; obj* x_127; obj* x_128; obj* x_129;
lean::dec(x_101);
lean::dec(x_106);
x_117 = lean::box(0);
x_118 = l_Lean_Parser_currLbp___rarg___lambda__3___closed__2;
x_119 = l_mjoin___rarg___closed__1;
x_120 = l_Lean_Parser_MonadParsec_error___at_Lean_Parser_levelParser_run___spec__3___rarg(x_118, x_119, x_117, x_117, x_0, x_1, x_102, x_99);
lean::dec(x_102);
obj* x_115; obj* x_116; obj* x_117; obj* x_118; obj* x_121; obj* x_123; obj* x_125; obj* x_126; obj* x_127;
lean::dec(x_104);
lean::dec(x_99);
x_115 = lean::box(0);
x_116 = l_Lean_Parser_currLbp___rarg___lambda__3___closed__2;
x_117 = l_mjoin___rarg___closed__1;
x_118 = l_Lean_Parser_MonadParsec_error___at_Lean_Parser_levelParser_run___spec__3___rarg(x_116, x_117, x_115, x_115, x_0, x_1, x_100, x_97);
lean::dec(x_100);
lean::dec(x_1);
x_123 = lean::cnstr_get(x_120, 0);
x_125 = lean::cnstr_get(x_120, 1);
if (lean::is_exclusive(x_120)) {
x_127 = x_120;
x_121 = lean::cnstr_get(x_118, 0);
x_123 = lean::cnstr_get(x_118, 1);
if (lean::is_exclusive(x_118)) {
x_125 = x_118;
} else {
lean::inc(x_121);
lean::inc(x_123);
lean::inc(x_125);
lean::dec(x_120);
x_127 = lean::box(0);
lean::dec(x_118);
x_125 = lean::box(0);
}
x_128 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_104, x_123);
if (lean::is_scalar(x_127)) {
x_129 = lean::alloc_cnstr(0, 2, 0);
x_126 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_102, x_121);
if (lean::is_scalar(x_125)) {
x_127 = lean::alloc_cnstr(0, 2, 0);
} else {
x_129 = x_127;
x_127 = x_125;
}
lean::cnstr_set(x_129, 0, x_128);
lean::cnstr_set(x_129, 1, x_125);
return x_129;
lean::cnstr_set(x_127, 0, x_126);
lean::cnstr_set(x_127, 1, x_123);
return x_127;
}
else
{
obj* x_131; obj* x_132; obj* x_133; obj* x_134; obj* x_135;
obj* x_129; obj* x_130; obj* x_131; obj* x_132; obj* x_133;
lean::dec(x_1);
x_131 = l_Lean_Parser_maxPrec;
x_132 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
if (lean::is_scalar(x_106)) {
x_133 = lean::alloc_cnstr(0, 3, 0);
x_129 = l_Lean_Parser_maxPrec;
x_130 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
if (lean::is_scalar(x_104)) {
x_131 = lean::alloc_cnstr(0, 3, 0);
} else {
x_133 = x_106;
x_131 = x_104;
}
lean::cnstr_set(x_133, 0, x_131);
lean::cnstr_set(x_133, 1, x_102);
lean::cnstr_set(x_133, 2, x_132);
x_134 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_104, x_133);
if (lean::is_scalar(x_101)) {
x_135 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_131, 0, x_129);
lean::cnstr_set(x_131, 1, x_100);
lean::cnstr_set(x_131, 2, x_130);
x_132 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_102, x_131);
if (lean::is_scalar(x_99)) {
x_133 = lean::alloc_cnstr(0, 2, 0);
} else {
x_135 = x_101;
x_133 = x_99;
}
lean::cnstr_set(x_135, 0, x_134);
lean::cnstr_set(x_135, 1, x_99);
return x_135;
lean::cnstr_set(x_133, 0, x_132);
lean::cnstr_set(x_133, 1, x_97);
return x_133;
}
}
else
{
obj* x_138; obj* x_139; obj* x_140; obj* x_141; obj* x_142;
obj* x_136; obj* x_137; obj* x_138; obj* x_139; obj* x_140;
lean::dec(x_1);
lean::dec(x_107);
x_138 = l_Lean_Parser_maxPrec;
x_139 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
if (lean::is_scalar(x_106)) {
x_140 = lean::alloc_cnstr(0, 3, 0);
lean::dec(x_105);
x_136 = l_Lean_Parser_maxPrec;
x_137 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
if (lean::is_scalar(x_104)) {
x_138 = lean::alloc_cnstr(0, 3, 0);
} else {
x_140 = x_106;
x_138 = x_104;
}
lean::cnstr_set(x_140, 0, x_138);
lean::cnstr_set(x_140, 1, x_102);
lean::cnstr_set(x_140, 2, x_139);
x_141 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_104, x_140);
if (lean::is_scalar(x_101)) {
x_142 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_138, 0, x_136);
lean::cnstr_set(x_138, 1, x_100);
lean::cnstr_set(x_138, 2, x_137);
x_139 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_102, x_138);
if (lean::is_scalar(x_99)) {
x_140 = lean::alloc_cnstr(0, 2, 0);
} else {
x_142 = x_101;
x_140 = x_99;
}
lean::cnstr_set(x_142, 0, x_141);
lean::cnstr_set(x_142, 1, x_99);
return x_142;
lean::cnstr_set(x_140, 0, x_139);
lean::cnstr_set(x_140, 1, x_97);
return x_140;
}
}
default:
{
obj* x_143; obj* x_146; obj* x_148; obj* x_151; obj* x_152; obj* x_153; obj* x_154; obj* x_157; obj* x_159; obj* x_161; obj* x_162; obj* x_163;
x_143 = lean::cnstr_get(x_6, 1);
lean::inc(x_143);
obj* x_141; obj* x_144; obj* x_146; obj* x_149; obj* x_150; obj* x_151; obj* x_152; obj* x_155; obj* x_157; obj* x_159; obj* x_160; obj* x_161;
x_141 = lean::cnstr_get(x_6, 1);
lean::inc(x_141);
lean::dec(x_6);
x_146 = lean::cnstr_get(x_7, 1);
x_144 = lean::cnstr_get(x_7, 1);
lean::inc(x_144);
x_146 = lean::cnstr_get(x_7, 2);
lean::inc(x_146);
x_148 = lean::cnstr_get(x_7, 2);
lean::inc(x_148);
lean::dec(x_7);
x_151 = lean::box(0);
x_152 = l_Lean_Parser_currLbp___rarg___lambda__3___closed__2;
x_153 = l_mjoin___rarg___closed__1;
x_154 = l_Lean_Parser_MonadParsec_error___at_Lean_Parser_levelParser_run___spec__3___rarg(x_152, x_153, x_151, x_151, x_0, x_1, x_146, x_143);
lean::dec(x_146);
x_149 = lean::box(0);
x_150 = l_Lean_Parser_currLbp___rarg___lambda__3___closed__2;
x_151 = l_mjoin___rarg___closed__1;
x_152 = l_Lean_Parser_MonadParsec_error___at_Lean_Parser_levelParser_run___spec__3___rarg(x_150, x_151, x_149, x_149, x_0, x_1, x_144, x_141);
lean::dec(x_144);
lean::dec(x_1);
x_157 = lean::cnstr_get(x_154, 0);
x_159 = lean::cnstr_get(x_154, 1);
if (lean::is_exclusive(x_154)) {
x_161 = x_154;
x_155 = lean::cnstr_get(x_152, 0);
x_157 = lean::cnstr_get(x_152, 1);
if (lean::is_exclusive(x_152)) {
x_159 = x_152;
} else {
lean::inc(x_155);
lean::inc(x_157);
lean::inc(x_159);
lean::dec(x_154);
x_161 = lean::box(0);
lean::dec(x_152);
x_159 = lean::box(0);
}
x_162 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_148, x_157);
if (lean::is_scalar(x_161)) {
x_163 = lean::alloc_cnstr(0, 2, 0);
x_160 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_146, x_155);
if (lean::is_scalar(x_159)) {
x_161 = lean::alloc_cnstr(0, 2, 0);
} else {
x_163 = x_161;
x_161 = x_159;
}
lean::cnstr_set(x_163, 0, x_162);
lean::cnstr_set(x_163, 1, x_159);
return x_163;
lean::cnstr_set(x_161, 0, x_160);
lean::cnstr_set(x_161, 1, x_157);
return x_161;
}
}
}
}
else
{
obj* x_165; obj* x_167; obj* x_168; uint8 x_170; obj* x_171; obj* x_172; obj* x_173; obj* x_174;
obj* x_163; obj* x_165; obj* x_166; uint8 x_168; obj* x_169; obj* x_170; obj* x_171; obj* x_172;
lean::dec(x_1);
x_165 = lean::cnstr_get(x_6, 1);
x_163 = lean::cnstr_get(x_6, 1);
if (lean::is_exclusive(x_6)) {
lean::cnstr_release(x_6, 0);
x_167 = x_6;
x_165 = x_6;
} else {
lean::inc(x_165);
lean::inc(x_163);
lean::dec(x_6);
x_167 = lean::box(0);
x_165 = lean::box(0);
}
x_168 = lean::cnstr_get(x_7, 0);
x_170 = lean::cnstr_get_scalar<uint8>(x_7, sizeof(void*)*1);
x_166 = lean::cnstr_get(x_7, 0);
x_168 = lean::cnstr_get_scalar<uint8>(x_7, sizeof(void*)*1);
if (lean::is_exclusive(x_7)) {
x_171 = x_7;
x_169 = x_7;
} else {
lean::inc(x_168);
lean::inc(x_166);
lean::dec(x_7);
x_171 = lean::box(0);
x_169 = lean::box(0);
}
if (lean::is_scalar(x_171)) {
x_172 = lean::alloc_cnstr(1, 1, 1);
if (lean::is_scalar(x_169)) {
x_170 = lean::alloc_cnstr(1, 1, 1);
} else {
x_172 = x_171;
x_170 = x_169;
}
lean::cnstr_set(x_172, 0, x_168);
lean::cnstr_set_scalar(x_172, sizeof(void*)*1, x_170);
x_173 = x_172;
if (lean::is_scalar(x_167)) {
x_174 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_170, 0, x_166);
lean::cnstr_set_scalar(x_170, sizeof(void*)*1, x_168);
x_171 = x_170;
if (lean::is_scalar(x_165)) {
x_172 = lean::alloc_cnstr(0, 2, 0);
} else {
x_174 = x_167;
x_172 = x_165;
}
lean::cnstr_set(x_174, 0, x_173);
lean::cnstr_set(x_174, 1, x_165);
return x_174;
lean::cnstr_set(x_172, 0, x_171);
lean::cnstr_set(x_172, 1, x_163);
return x_172;
}
}
}

View file

@ -37,7 +37,6 @@ obj* l_Lean_Parser_ModuleParserM_liftParserT___boxed(obj*);
obj* l_Lean_Parser_resumeModuleParser___boxed(obj*);
obj* l_Lean_Parser_Module_header_HasView_x_27___lambda__1___closed__3;
obj* l_Lean_Parser_ParserT_Lean_Parser_MonadParsec___rarg(obj*);
extern usize l_String_toSubstring___closed__1;
obj* l_Lean_Parser_MonadParsec_eoi___at_Lean_Parser_Module_eoi_Parser___spec__1___boxed(obj*, obj*, obj*, obj*);
obj* l_Lean_Parser_Module_importPath_Parser_Lean_Parser_HasView___lambda__1___boxed(obj*, obj*, obj*, obj*, obj*);
obj* l_Lean_Parser_ParsecT_runFrom___at_Lean_Parser_resumeModuleParser___spec__1(obj*, obj*);
@ -5475,7 +5474,7 @@ return x_2;
obj* l_Lean_Parser_parseHeader(obj* x_0) {
_start:
{
obj* x_1; obj* x_3; obj* x_6; obj* x_9; obj* x_12; usize x_13; obj* x_14; obj* x_15; uint8 x_16; obj* x_17; obj* x_18; obj* x_20; obj* x_21; obj* x_22;
obj* x_1; obj* x_3; obj* x_6; obj* x_9; obj* x_12; obj* x_13; uint8 x_14; obj* x_15; obj* x_16; obj* x_18; obj* x_19; obj* x_20;
x_1 = lean::cnstr_get(x_0, 0);
lean::inc(x_1);
x_3 = lean::cnstr_get(x_1, 0);
@ -5488,23 +5487,21 @@ x_9 = lean::cnstr_get(x_6, 1);
lean::inc(x_9);
lean::dec(x_6);
x_12 = lean::mk_nat_obj(0ul);
x_13 = l_String_toSubstring___closed__1;
x_14 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
lean::cnstr_set(x_14, 0, x_9);
lean::cnstr_set(x_14, 1, x_12);
lean::cnstr_set_scalar(x_14, sizeof(void*)*2, x_13);
x_15 = x_14;
x_16 = 0;
x_17 = lean::alloc_cnstr(0, 1, 1);
lean::cnstr_set(x_17, 0, x_15);
lean::cnstr_set_scalar(x_17, sizeof(void*)*1, x_16);
x_18 = x_17;
lean::inc(x_18);
x_20 = lean::alloc_closure(reinterpret_cast<void*>(l_Lean_Parser_parseHeader___lambda__1), 2, 1);
lean::closure_set(x_20, 0, x_18);
x_21 = l_Lean_Parser_parseHeader___closed__1;
x_22 = l_Lean_Parser_resumeModuleParser___rarg(x_0, x_18, x_20, x_21);
return x_22;
x_13 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_13, 0, x_9);
lean::cnstr_set(x_13, 1, x_12);
lean::cnstr_set(x_13, 2, x_12);
x_14 = 0;
x_15 = lean::alloc_cnstr(0, 1, 1);
lean::cnstr_set(x_15, 0, x_13);
lean::cnstr_set_scalar(x_15, sizeof(void*)*1, x_14);
x_16 = x_15;
lean::inc(x_16);
x_18 = lean::alloc_closure(reinterpret_cast<void*>(l_Lean_Parser_parseHeader___lambda__1), 2, 1);
lean::closure_set(x_18, 0, x_16);
x_19 = l_Lean_Parser_parseHeader___closed__1;
x_20 = l_Lean_Parser_resumeModuleParser___rarg(x_0, x_16, x_18, x_19);
return x_20;
}
}
obj* l_StateT_bind___at_Lean_Parser_parseHeader___spec__1___boxed(obj* x_0, obj* x_1) {

View file

@ -70,7 +70,6 @@ extern obj* l_Lean_Parser_Combinators_choiceAux___main___rarg___closed__1;
obj* l_ReaderT_lift___at_Lean_Parser_command_NotationSpec_symbolQuote_Parser_Lean_Parser_HasTokens___spec__1___boxed(obj*);
obj* l_Lean_Parser_command_NotationSpec_precedence_HasView_x_27;
obj* l_Lean_Parser_command_NotationSpec_unquotedSymbol_tokens;
extern usize l_String_toSubstring___closed__1;
obj* l_Lean_Parser_command_NotationSpec_transition_Parser___closed__1;
obj* l_Lean_Parser_command_notation_HasView_x_27___lambda__2(obj*);
obj* l_Lean_Parser_command_mixfix_HasView_x_27;
@ -5767,73 +5766,71 @@ uint8 x_7;
x_7 = l_String_isEmpty(x_0);
if (x_7 == 0)
{
obj* x_8; obj* x_9; usize x_10; obj* x_12; obj* x_13; obj* x_15;
obj* x_8; obj* x_9; obj* x_11; obj* x_13;
x_8 = lean::string_length(x_0);
x_9 = lean::mk_nat_obj(0ul);
x_10 = l_String_toSubstring___closed__1;
lean::inc(x_0);
x_12 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
lean::cnstr_set(x_12, 0, x_0);
lean::cnstr_set(x_12, 1, x_9);
lean::cnstr_set_scalar(x_12, sizeof(void*)*2, x_10);
x_13 = x_12;
x_11 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_11, 0, x_0);
lean::cnstr_set(x_11, 1, x_9);
lean::cnstr_set(x_11, 2, x_9);
lean::inc(x_5);
x_15 = l___private_init_lean_parser_parsec_2__strAux___main(x_8, x_13, x_5);
if (lean::obj_tag(x_15) == 0)
x_13 = l___private_init_lean_parser_parsec_2__strAux___main(x_8, x_11, x_5);
if (lean::obj_tag(x_13) == 0)
{
obj* x_17; obj* x_18; obj* x_19; uint8 x_20; obj* x_21; obj* x_22; obj* x_23;
obj* x_15; obj* x_16; obj* x_17; uint8 x_18; obj* x_19; obj* x_20; obj* x_21;
lean::dec(x_0);
x_17 = lean::box(0);
x_18 = l_String_splitAux___main___closed__1;
x_19 = lean::alloc_cnstr(0, 4, 0);
lean::cnstr_set(x_19, 0, x_5);
lean::cnstr_set(x_19, 1, x_18);
lean::cnstr_set(x_19, 2, x_1);
lean::cnstr_set(x_19, 3, x_17);
x_20 = 0;
x_21 = lean::alloc_cnstr(1, 1, 1);
lean::cnstr_set(x_21, 0, x_19);
lean::cnstr_set_scalar(x_21, sizeof(void*)*1, x_20);
x_22 = x_21;
x_23 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_23, 0, x_22);
lean::cnstr_set(x_23, 1, x_6);
return x_23;
x_15 = lean::box(0);
x_16 = l_String_splitAux___main___closed__1;
x_17 = lean::alloc_cnstr(0, 4, 0);
lean::cnstr_set(x_17, 0, x_5);
lean::cnstr_set(x_17, 1, x_16);
lean::cnstr_set(x_17, 2, x_1);
lean::cnstr_set(x_17, 3, x_15);
x_18 = 0;
x_19 = lean::alloc_cnstr(1, 1, 1);
lean::cnstr_set(x_19, 0, x_17);
lean::cnstr_set_scalar(x_19, sizeof(void*)*1, x_18);
x_20 = x_19;
x_21 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_21, 0, x_20);
lean::cnstr_set(x_21, 1, x_6);
return x_21;
}
else
{
obj* x_26; obj* x_29; obj* x_30; obj* x_31;
obj* x_24; obj* x_27; obj* x_28; obj* x_29;
lean::dec(x_5);
lean::dec(x_1);
x_26 = lean::cnstr_get(x_15, 0);
lean::inc(x_26);
lean::dec(x_15);
x_29 = lean::box(0);
x_30 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_30, 0, x_0);
lean::cnstr_set(x_30, 1, x_26);
lean::cnstr_set(x_30, 2, x_29);
x_31 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_31, 0, x_30);
lean::cnstr_set(x_31, 1, x_6);
return x_31;
x_24 = lean::cnstr_get(x_13, 0);
lean::inc(x_24);
lean::dec(x_13);
x_27 = lean::box(0);
x_28 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_28, 0, x_0);
lean::cnstr_set(x_28, 1, x_24);
lean::cnstr_set(x_28, 2, x_27);
x_29 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_29, 0, x_28);
lean::cnstr_set(x_29, 1, x_6);
return x_29;
}
}
else
{
obj* x_34; obj* x_35; obj* x_36; obj* x_37;
obj* x_32; obj* x_33; obj* x_34; obj* x_35;
lean::dec(x_1);
lean::dec(x_0);
x_34 = l_String_splitAux___main___closed__1;
x_35 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
x_36 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_36, 0, x_34);
lean::cnstr_set(x_36, 1, x_5);
lean::cnstr_set(x_36, 2, x_35);
x_37 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_37, 0, x_36);
lean::cnstr_set(x_37, 1, x_6);
return x_37;
x_32 = l_String_splitAux___main___closed__1;
x_33 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
x_34 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_34, 0, x_32);
lean::cnstr_set(x_34, 1, x_5);
lean::cnstr_set(x_34, 2, x_33);
x_35 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_35, 0, x_34);
lean::cnstr_set(x_35, 1, x_6);
return x_35;
}
}
}

View file

@ -62,7 +62,7 @@ obj* l_Lean_Parser_MonadParsec_upper___rarg___lambda__1(obj*, obj*, obj*);
obj* l_Lean_Parser_ParsecT_orelse___rarg___lambda__2(obj*, obj*, obj*, obj*, obj*);
obj* l_Lean_Parser_ParsecT_Monad___rarg___lambda__11(obj*, obj*, obj*, obj*, obj*, obj*);
namespace lean {
usize string_utf8_prev_old(obj*, usize);
obj* string_utf8_prev(obj*, obj*);
}
obj* l_Lean_Parser_MonadParsec_takeWhile_x_27___boxed(obj*, obj*, obj*);
obj* l_Lean_Parser_MonadParsec_notFollowedBy(obj*, obj*);
@ -78,7 +78,6 @@ obj* l_Lean_Parser_MonadParsec_take___rarg(obj*, obj*, obj*);
obj* l_Lean_Parser_MonadParsec_error___at_Lean_Parser_MonadParsec_longestMatch___spec__1___rarg(obj*, obj*, obj*, obj*, obj*);
obj* l_String_OldIterator_hasNext___main___boxed(obj*);
obj* l_Lean_Parser_MonadParsec_foldlAux___main___rarg___lambda__1(obj*, obj*, obj*, obj*, obj*, obj*, obj*);
extern usize l_String_toSubstring___closed__1;
obj* l_Lean_Parser_MonadParsec_labels___rarg(obj*, obj*, obj*, obj*);
obj* l_Lean_Parser_MonadParsec_label___rarg___boxed(obj*, obj*, obj*, obj*);
obj* l_String_intercalate(obj*, obj*);
@ -90,7 +89,7 @@ obj* l_List_mfoldr___main___at_Lean_Parser_MonadParsec_longestMatch___spec__2___
obj* l_Lean_Parser_MonadParsec_takeUntil1___rarg(obj*, obj*, obj*);
obj* l_Lean_Parser_ParsecT_parseWithEoi___rarg___lambda__2(obj*, obj*, obj*);
obj* l___private_init_lean_parser_parsec_7__takeWhileAux_x_27___boxed(obj*);
usize l_String_OldIterator_remainingBytes___main(obj*);
obj* l_String_OldIterator_remainingBytes___main(obj*);
obj* l_Lean_Parser_MonadParsec_eoi___rarg___lambda__1___closed__1;
obj* l_String_OldIterator_prevn(obj*, obj*);
obj* l___private_init_lean_parser_parsec_7__takeWhileAux_x_27___main___boxed(obj*);
@ -437,7 +436,7 @@ obj* l_Lean_Parser_MonadParsec_takeWhileCont___at_Lean_Parser_MonadParsec_takeUn
obj* l_Lean_Parser_ParsecT_MonadExcept___rarg___lambda__3(obj*, obj*, obj*, obj*);
obj* l_Lean_Parser_MonadParsec_fix(obj*, obj*);
namespace lean {
uint32 string_utf8_get_old(obj*, usize);
uint32 string_utf8_get(obj*, obj*);
}
obj* l_Lean_Parser_MonadParsec_leftOver(obj*, obj*, obj*);
obj* l_Lean_Parser_MonadParsec_remaining___boxed(obj*, obj*);
@ -579,7 +578,7 @@ obj* l_Lean_Parser_MonadParsec_many1Aux_x_27___rarg(obj*, obj*, obj*);
obj* l_Lean_Parser_ParsecT_Monad___rarg(obj*, obj*);
obj* l_String_OldIterator_isPrefixOfRemaining___main___boxed(obj*, obj*);
obj* l_Lean_Parser_MonadParsec_foldlAux___main___rarg___boxed(obj*, obj*, obj*, obj*, obj*, obj*, obj*, obj*);
usize l_String_OldIterator_remainingBytes(obj*);
obj* l_String_OldIterator_remainingBytes(obj*);
obj* l_Lean_Parser_MonadParsec_strCore___rarg(obj*, obj*, obj*, obj*);
obj* l___private_init_lean_parser_parsec_6__mkConsumedResult___boxed(obj*);
obj* l_Lean_Parser_MonadParsec_curr(obj*, obj*);
@ -597,7 +596,7 @@ obj* l_Lean_Parser_MonadParsec_labels___rarg___lambda__1___boxed(obj*, obj*, obj
obj* l_Lean_Parser_MonadParsec_unexpectedAt___rarg___boxed(obj*, obj*, obj*, obj*);
obj* l_Lean_Parser_MonadParsec_many1Aux___main___rarg___lambda__3(obj*, obj*);
namespace lean {
usize string_utf8_next_old(obj*, usize);
obj* string_utf8_next(obj*, obj*);
}
obj* l_Lean_Parser_ParsecT_bind_x_27(obj*);
extern uint8 l_True_Decidable;
@ -622,7 +621,7 @@ namespace lean {
uint8 nat_dec_le(obj*, obj*);
}
namespace lean {
obj* string_utf8_extract_old(obj*, usize, usize);
obj* string_utf8_extract(obj*, obj*, obj*);
}
obj* l_Lean_Parser_MonadParsec_whitespace(obj*, obj*);
obj* l_Lean_Parser_Parsec_parse___rarg___boxed(obj*, obj*, obj*);
@ -639,7 +638,7 @@ obj* l_Lean_Parser_MonadParsec_fixAux___main___rarg___boxed(obj*, obj*, obj*, ob
obj* l_Lean_Parser_MonadParsec_takeWhile_x_27___at_Lean_Parser_MonadParsec_whitespace___spec__1___rarg(obj*);
obj* l_Lean_Parser_MonadParsec_observing___rarg___boxed(obj*, obj*, obj*, obj*, obj*);
namespace lean {
usize string_utf8_byte_size_old(obj*);
obj* string_utf8_byte_size(obj*);
}
obj* l_Lean_Parser_MonadParsec_fix___rarg(obj*, obj*, obj*, obj*, obj*);
obj* l___private_init_lean_parser_parsec_3__takeAux___main___rarg(obj*, obj*, obj*);
@ -736,7 +735,7 @@ obj* l_Lean_Parser_ParsecT_Monad_x_27___rarg___lambda__2(obj*, obj*, obj*, obj*,
obj* l_Lean_Parser_MonadParsec_takeWhile1___at_Lean_Parser_MonadParsec_num___spec__1___rarg___lambda__1(obj*, obj*, uint32);
extern obj* l_String_splitAux___main___closed__1;
namespace lean {
obj* string_utf8_set_old(obj*, usize, uint32);
obj* string_utf8_set(obj*, obj*, uint32);
}
obj* l_Lean_Parser_MonadParsec_hidden___rarg___lambda__1(obj*, obj*);
namespace lean {
@ -746,15 +745,13 @@ obj* l_Lean_Parser_ParsecT_failure(obj*);
obj* l_String_mkOldIterator(obj* x_0) {
_start:
{
obj* x_1; usize x_2; obj* x_3; obj* x_4;
obj* x_1; obj* x_2;
x_1 = lean::mk_nat_obj(0ul);
x_2 = l_String_toSubstring___closed__1;
x_3 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
lean::cnstr_set(x_3, 0, x_0);
lean::cnstr_set(x_3, 1, x_1);
lean::cnstr_set_scalar(x_3, sizeof(void*)*2, x_2);
x_4 = x_3;
return x_4;
x_2 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_2, 0, x_0);
lean::cnstr_set(x_2, 1, x_1);
lean::cnstr_set(x_2, 2, x_1);
return x_2;
}
}
obj* l_String_OldIterator_remaining___main(obj* x_0) {
@ -830,31 +827,31 @@ lean::dec(x_0);
return x_1;
}
}
usize l_String_OldIterator_remainingBytes___main(obj* x_0) {
obj* l_String_OldIterator_remainingBytes___main(obj* x_0) {
_start:
{
obj* x_1; usize x_2; usize x_3; usize x_4;
obj* x_1; obj* x_2; obj* x_3; obj* x_4;
x_1 = lean::cnstr_get(x_0, 0);
x_2 = lean::cnstr_get_scalar<usize>(x_0, sizeof(void*)*2);
x_3 = lean::string_utf8_byte_size_old(x_1);
x_4 = x_3 - x_2;
x_2 = lean::cnstr_get(x_0, 2);
x_3 = lean::string_utf8_byte_size(x_1);
x_4 = lean::nat_sub(x_3, x_2);
lean::dec(x_3);
return x_4;
}
}
obj* l_String_OldIterator_remainingBytes___main___boxed(obj* x_0) {
_start:
{
usize x_1; obj* x_2;
obj* x_1;
x_1 = l_String_OldIterator_remainingBytes___main(x_0);
x_2 = lean::box_size_t(x_1);
lean::dec(x_0);
return x_2;
return x_1;
}
}
usize l_String_OldIterator_remainingBytes(obj* x_0) {
obj* l_String_OldIterator_remainingBytes(obj* x_0) {
_start:
{
usize x_1;
obj* x_1;
x_1 = l_String_OldIterator_remainingBytes___main(x_0);
return x_1;
}
@ -862,20 +859,19 @@ return x_1;
obj* l_String_OldIterator_remainingBytes___boxed(obj* x_0) {
_start:
{
usize x_1; obj* x_2;
obj* x_1;
x_1 = l_String_OldIterator_remainingBytes(x_0);
x_2 = lean::box_size_t(x_1);
lean::dec(x_0);
return x_2;
return x_1;
}
}
uint32 l_String_OldIterator_curr___main(obj* x_0) {
_start:
{
obj* x_1; usize x_2; uint32 x_3;
obj* x_1; obj* x_2; uint32 x_3;
x_1 = lean::cnstr_get(x_0, 0);
x_2 = lean::cnstr_get_scalar<usize>(x_0, sizeof(void*)*2);
x_3 = lean::string_utf8_get_old(x_1, x_2);
x_2 = lean::cnstr_get(x_0, 2);
x_3 = lean::string_utf8_get(x_1, x_2);
return x_3;
}
}
@ -910,32 +906,33 @@ return x_2;
obj* l_String_OldIterator_next___main(obj* x_0) {
_start:
{
obj* x_1; obj* x_3; usize x_5; obj* x_6; obj* x_7; obj* x_8; usize x_10; obj* x_11; obj* x_12;
obj* x_1; obj* x_3; obj* x_5; obj* x_7; obj* x_8; obj* x_9; obj* x_11; obj* x_13;
x_1 = lean::cnstr_get(x_0, 0);
x_3 = lean::cnstr_get(x_0, 1);
x_5 = lean::cnstr_get_scalar<usize>(x_0, sizeof(void*)*2);
x_5 = lean::cnstr_get(x_0, 2);
if (lean::is_exclusive(x_0)) {
x_6 = x_0;
x_7 = x_0;
} else {
lean::inc(x_1);
lean::inc(x_3);
lean::inc(x_5);
lean::dec(x_0);
x_6 = lean::box(0);
x_7 = lean::box(0);
}
x_7 = lean::mk_nat_obj(1ul);
x_8 = lean::nat_add(x_3, x_7);
x_8 = lean::mk_nat_obj(1ul);
x_9 = lean::nat_add(x_3, x_8);
lean::dec(x_3);
x_10 = lean::string_utf8_next_old(x_1, x_5);
if (lean::is_scalar(x_6)) {
x_11 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
x_11 = lean::string_utf8_next(x_1, x_5);
lean::dec(x_5);
if (lean::is_scalar(x_7)) {
x_13 = lean::alloc_cnstr(0, 3, 0);
} else {
x_11 = x_6;
x_13 = x_7;
}
lean::cnstr_set(x_11, 0, x_1);
lean::cnstr_set(x_11, 1, x_8);
lean::cnstr_set_scalar(x_11, sizeof(void*)*2, x_10);
x_12 = x_11;
return x_12;
lean::cnstr_set(x_13, 0, x_1);
lean::cnstr_set(x_13, 1, x_9);
lean::cnstr_set(x_13, 2, x_11);
return x_13;
}
}
obj* l_String_OldIterator_next(obj* x_0) {
@ -949,32 +946,33 @@ return x_1;
obj* l_String_OldIterator_prev___main(obj* x_0) {
_start:
{
obj* x_1; obj* x_3; usize x_5; obj* x_6; obj* x_7; obj* x_8; usize x_10; obj* x_11; obj* x_12;
obj* x_1; obj* x_3; obj* x_5; obj* x_7; obj* x_8; obj* x_9; obj* x_11; obj* x_13;
x_1 = lean::cnstr_get(x_0, 0);
x_3 = lean::cnstr_get(x_0, 1);
x_5 = lean::cnstr_get_scalar<usize>(x_0, sizeof(void*)*2);
x_5 = lean::cnstr_get(x_0, 2);
if (lean::is_exclusive(x_0)) {
x_6 = x_0;
x_7 = x_0;
} else {
lean::inc(x_1);
lean::inc(x_3);
lean::inc(x_5);
lean::dec(x_0);
x_6 = lean::box(0);
x_7 = lean::box(0);
}
x_7 = lean::mk_nat_obj(1ul);
x_8 = lean::nat_sub(x_3, x_7);
x_8 = lean::mk_nat_obj(1ul);
x_9 = lean::nat_sub(x_3, x_8);
lean::dec(x_3);
x_10 = lean::string_utf8_prev_old(x_1, x_5);
if (lean::is_scalar(x_6)) {
x_11 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
x_11 = lean::string_utf8_prev(x_1, x_5);
lean::dec(x_5);
if (lean::is_scalar(x_7)) {
x_13 = lean::alloc_cnstr(0, 3, 0);
} else {
x_11 = x_6;
x_13 = x_7;
}
lean::cnstr_set(x_11, 0, x_1);
lean::cnstr_set(x_11, 1, x_8);
lean::cnstr_set_scalar(x_11, sizeof(void*)*2, x_10);
x_12 = x_11;
return x_12;
lean::cnstr_set(x_13, 0, x_1);
lean::cnstr_set(x_13, 1, x_9);
lean::cnstr_set(x_13, 2, x_11);
return x_13;
}
}
obj* l_String_OldIterator_prev(obj* x_0) {
@ -988,11 +986,12 @@ return x_1;
uint8 l_String_OldIterator_hasNext___main(obj* x_0) {
_start:
{
obj* x_1; usize x_2; usize x_3; uint8 x_4;
obj* x_1; obj* x_2; obj* x_3; uint8 x_4;
x_1 = lean::cnstr_get(x_0, 0);
x_2 = lean::cnstr_get_scalar<usize>(x_0, sizeof(void*)*2);
x_3 = lean::string_utf8_byte_size_old(x_1);
x_4 = x_2 < x_3;
x_2 = lean::cnstr_get(x_0, 2);
x_3 = lean::string_utf8_byte_size(x_1);
x_4 = lean::nat_dec_lt(x_2, x_3);
lean::dec(x_3);
return x_4;
}
}
@ -1027,10 +1026,10 @@ return x_2;
uint8 l_String_OldIterator_hasPrev___main(obj* x_0) {
_start:
{
usize x_1; usize x_2; uint8 x_3;
x_1 = lean::cnstr_get_scalar<usize>(x_0, sizeof(void*)*2);
x_2 = l_String_toSubstring___closed__1;
x_3 = x_2 < x_1;
obj* x_1; obj* x_2; uint8 x_3;
x_1 = lean::cnstr_get(x_0, 2);
x_2 = lean::mk_nat_obj(0ul);
x_3 = lean::nat_dec_lt(x_2, x_1);
return x_3;
}
}
@ -1065,28 +1064,28 @@ return x_2;
obj* l_String_OldIterator_setCurr___main(obj* x_0, uint32 x_1) {
_start:
{
obj* x_2; obj* x_4; usize x_6; obj* x_7; obj* x_8; obj* x_9; obj* x_10;
obj* x_2; obj* x_4; obj* x_6; obj* x_8; obj* x_9; obj* x_10;
x_2 = lean::cnstr_get(x_0, 0);
x_4 = lean::cnstr_get(x_0, 1);
x_6 = lean::cnstr_get_scalar<usize>(x_0, sizeof(void*)*2);
x_6 = lean::cnstr_get(x_0, 2);
if (lean::is_exclusive(x_0)) {
x_7 = x_0;
x_8 = x_0;
} else {
lean::inc(x_2);
lean::inc(x_4);
lean::inc(x_6);
lean::dec(x_0);
x_7 = lean::box(0);
x_8 = lean::box(0);
}
x_8 = lean::string_utf8_set_old(x_2, x_6, x_1);
if (lean::is_scalar(x_7)) {
x_9 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
x_9 = lean::string_utf8_set(x_2, x_6, x_1);
if (lean::is_scalar(x_8)) {
x_10 = lean::alloc_cnstr(0, 3, 0);
} else {
x_9 = x_7;
x_10 = x_8;
}
lean::cnstr_set(x_9, 0, x_8);
lean::cnstr_set(x_9, 1, x_4);
lean::cnstr_set_scalar(x_9, sizeof(void*)*2, x_6);
x_10 = x_9;
lean::cnstr_set(x_10, 0, x_9);
lean::cnstr_set(x_10, 1, x_4);
lean::cnstr_set(x_10, 2, x_6);
return x_10;
}
}
@ -1119,10 +1118,11 @@ return x_3;
obj* l_String_OldIterator_toEnd___main(obj* x_0) {
_start:
{
obj* x_1; obj* x_3; obj* x_4; usize x_5; obj* x_6; obj* x_7;
obj* x_1; obj* x_3; obj* x_4; obj* x_5; obj* x_6;
x_1 = lean::cnstr_get(x_0, 0);
if (lean::is_exclusive(x_0)) {
lean::cnstr_release(x_0, 1);
lean::cnstr_release(x_0, 2);
x_3 = x_0;
} else {
lean::inc(x_1);
@ -1130,17 +1130,16 @@ if (lean::is_exclusive(x_0)) {
x_3 = lean::box(0);
}
x_4 = lean::string_length(x_1);
x_5 = lean::string_utf8_byte_size_old(x_1);
x_5 = lean::string_utf8_byte_size(x_1);
if (lean::is_scalar(x_3)) {
x_6 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
x_6 = lean::alloc_cnstr(0, 3, 0);
} else {
x_6 = x_3;
}
lean::cnstr_set(x_6, 0, x_1);
lean::cnstr_set(x_6, 1, x_4);
lean::cnstr_set_scalar(x_6, sizeof(void*)*2, x_5);
x_7 = x_6;
return x_7;
lean::cnstr_set(x_6, 2, x_5);
return x_6;
}
}
obj* l_String_OldIterator_toEnd(obj* x_0) {
@ -1154,12 +1153,12 @@ return x_1;
obj* l_String_OldIterator_extract___main(obj* x_0, obj* x_1) {
_start:
{
usize x_2; obj* x_3; obj* x_4; usize x_5; uint8 x_6;
x_2 = lean::cnstr_get_scalar<usize>(x_0, sizeof(void*)*2);
x_3 = lean::cnstr_get(x_0, 0);
obj* x_2; obj* x_3; obj* x_4; obj* x_5; uint8 x_6;
x_2 = lean::cnstr_get(x_0, 0);
x_3 = lean::cnstr_get(x_0, 2);
x_4 = lean::cnstr_get(x_1, 0);
x_5 = lean::cnstr_get_scalar<usize>(x_1, sizeof(void*)*2);
x_6 = lean::string_dec_eq(x_3, x_4);
x_5 = lean::cnstr_get(x_1, 2);
x_6 = lean::string_dec_eq(x_2, x_4);
if (x_6 == 0)
{
obj* x_7;
@ -1169,11 +1168,11 @@ return x_7;
else
{
uint8 x_8;
x_8 = x_5 < x_2;
x_8 = lean::nat_dec_lt(x_5, x_3);
if (x_8 == 0)
{
obj* x_9;
x_9 = lean::string_utf8_extract_old(x_3, x_2, x_5);
x_9 = lean::string_utf8_extract(x_2, x_3, x_5);
return x_9;
}
else
@ -1248,11 +1247,12 @@ return x_2;
obj* l_String_OldIterator_remainingToString___main(obj* x_0) {
_start:
{
obj* x_1; usize x_2; usize x_3; obj* x_4;
obj* x_1; obj* x_2; obj* x_3; obj* x_4;
x_1 = lean::cnstr_get(x_0, 0);
x_2 = lean::cnstr_get_scalar<usize>(x_0, sizeof(void*)*2);
x_3 = lean::string_utf8_byte_size_old(x_1);
x_4 = lean::string_utf8_extract_old(x_1, x_2, x_3);
x_2 = lean::cnstr_get(x_0, 2);
x_3 = lean::string_utf8_byte_size(x_1);
x_4 = lean::string_utf8_extract(x_1, x_2, x_3);
lean::dec(x_3);
return x_4;
}
}
@ -1285,20 +1285,23 @@ return x_1;
uint8 l_String_OldIterator_isPrefixOfRemaining___main(obj* x_0, obj* x_1) {
_start:
{
usize x_2; obj* x_3; obj* x_4; usize x_5; usize x_6; obj* x_7; usize x_8; usize x_9; obj* x_10; uint8 x_11;
x_2 = lean::cnstr_get_scalar<usize>(x_0, sizeof(void*)*2);
x_3 = lean::cnstr_get(x_0, 0);
obj* x_2; obj* x_3; obj* x_4; obj* x_5; obj* x_6; obj* x_7; obj* x_8; obj* x_10; obj* x_12; uint8 x_14;
x_2 = lean::cnstr_get(x_0, 0);
x_3 = lean::cnstr_get(x_0, 2);
x_4 = lean::cnstr_get(x_1, 0);
x_5 = lean::cnstr_get_scalar<usize>(x_1, sizeof(void*)*2);
x_6 = lean::string_utf8_byte_size_old(x_3);
x_7 = lean::string_utf8_extract_old(x_3, x_2, x_6);
x_8 = x_6 - x_2;
x_9 = x_5 + x_8;
x_10 = lean::string_utf8_extract_old(x_4, x_5, x_9);
x_11 = lean::string_dec_eq(x_7, x_10);
x_5 = lean::cnstr_get(x_1, 2);
x_6 = lean::string_utf8_byte_size(x_2);
x_7 = lean::string_utf8_extract(x_2, x_3, x_6);
x_8 = lean::nat_sub(x_6, x_3);
lean::dec(x_6);
x_10 = lean::nat_add(x_5, x_8);
lean::dec(x_8);
x_12 = lean::string_utf8_extract(x_4, x_5, x_10);
lean::dec(x_10);
x_14 = lean::string_dec_eq(x_7, x_12);
lean::dec(x_12);
lean::dec(x_7);
return x_11;
return x_14;
}
}
obj* l_String_OldIterator_isPrefixOfRemaining___main___boxed(obj* x_0, obj* x_1) {
@ -1492,17 +1495,15 @@ return x_3;
obj* l_String_oldLineColumn(obj* x_0, obj* x_1) {
_start:
{
obj* x_2; usize x_3; obj* x_4; obj* x_5; obj* x_6; obj* x_7;
obj* x_2; obj* x_3; obj* x_4; obj* x_5;
x_2 = lean::mk_nat_obj(0ul);
x_3 = l_String_toSubstring___closed__1;
x_4 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
lean::cnstr_set(x_4, 0, x_0);
lean::cnstr_set(x_4, 1, x_2);
lean::cnstr_set_scalar(x_4, sizeof(void*)*2, x_3);
x_5 = x_4;
x_6 = l_String_lineColumn___closed__1;
x_7 = l___private_init_lean_parser_parsec_1__oldLineColumnAux___main(x_1, x_5, x_6);
return x_7;
x_3 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_3, 0, x_0);
lean::cnstr_set(x_3, 1, x_2);
lean::cnstr_set(x_3, 2, x_2);
x_4 = l_String_lineColumn___closed__1;
x_5 = l___private_init_lean_parser_parsec_1__oldLineColumnAux___main(x_1, x_3, x_4);
return x_5;
}
}
obj* _init_l_Lean_Parser_Parsec_expected_toString___main___closed__1() {
@ -1963,21 +1964,19 @@ return x_23;
obj* l_Lean_Parser_ParsecT_run___rarg(obj* x_0, obj* x_1, obj* x_2, obj* x_3, obj* x_4, obj* x_5) {
_start:
{
obj* x_6; obj* x_8; usize x_9; obj* x_10; obj* x_11; obj* x_12; obj* x_13; obj* x_14;
obj* x_6; obj* x_8; obj* x_9; obj* x_10; obj* x_11; obj* x_12;
x_6 = lean::cnstr_get(x_0, 1);
lean::inc(x_6);
x_8 = lean::mk_nat_obj(0ul);
x_9 = l_String_toSubstring___closed__1;
x_10 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
lean::cnstr_set(x_10, 0, x_4);
lean::cnstr_set(x_10, 1, x_8);
lean::cnstr_set_scalar(x_10, sizeof(void*)*2, x_9);
x_11 = x_10;
x_12 = lean::apply_1(x_3, x_11);
x_13 = lean::alloc_closure(reinterpret_cast<void*>(l_Lean_Parser_ParsecT_run___rarg___lambda__1), 2, 1);
lean::closure_set(x_13, 0, x_0);
x_14 = lean::apply_4(x_6, lean::box(0), lean::box(0), x_12, x_13);
return x_14;
x_9 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_9, 0, x_4);
lean::cnstr_set(x_9, 1, x_8);
lean::cnstr_set(x_9, 2, x_8);
x_10 = lean::apply_1(x_3, x_9);
x_11 = lean::alloc_closure(reinterpret_cast<void*>(l_Lean_Parser_ParsecT_run___rarg___lambda__1), 2, 1);
lean::closure_set(x_11, 0, x_0);
x_12 = lean::apply_4(x_6, lean::box(0), lean::box(0), x_10, x_11);
return x_12;
}
}
obj* l_Lean_Parser_ParsecT_run(obj* x_0) {
@ -6574,50 +6573,48 @@ return x_3;
obj* l_Lean_Parser_MonadParsec_strCore___rarg___lambda__1(obj* x_0, obj* x_1, obj* x_2) {
_start:
{
obj* x_3; obj* x_4; usize x_5; obj* x_7; obj* x_8; obj* x_10;
obj* x_3; obj* x_4; obj* x_6; obj* x_8;
x_3 = lean::string_length(x_0);
x_4 = lean::mk_nat_obj(0ul);
x_5 = l_String_toSubstring___closed__1;
lean::inc(x_0);
x_7 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
lean::cnstr_set(x_7, 0, x_0);
lean::cnstr_set(x_7, 1, x_4);
lean::cnstr_set_scalar(x_7, sizeof(void*)*2, x_5);
x_8 = x_7;
x_6 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_6, 0, x_0);
lean::cnstr_set(x_6, 1, x_4);
lean::cnstr_set(x_6, 2, x_4);
lean::inc(x_2);
x_10 = l___private_init_lean_parser_parsec_2__strAux___main(x_3, x_8, x_2);
if (lean::obj_tag(x_10) == 0)
x_8 = l___private_init_lean_parser_parsec_2__strAux___main(x_3, x_6, x_2);
if (lean::obj_tag(x_8) == 0)
{
obj* x_12; obj* x_13; obj* x_14; uint8 x_15; obj* x_16; obj* x_17;
obj* x_10; obj* x_11; obj* x_12; uint8 x_13; obj* x_14; obj* x_15;
lean::dec(x_0);
x_12 = lean::box(0);
x_13 = l_String_splitAux___main___closed__1;
x_14 = lean::alloc_cnstr(0, 4, 0);
lean::cnstr_set(x_14, 0, x_2);
lean::cnstr_set(x_14, 1, x_13);
lean::cnstr_set(x_14, 2, x_1);
lean::cnstr_set(x_14, 3, x_12);
x_15 = 0;
x_16 = lean::alloc_cnstr(1, 1, 1);
lean::cnstr_set(x_16, 0, x_14);
lean::cnstr_set_scalar(x_16, sizeof(void*)*1, x_15);
x_17 = x_16;
return x_17;
x_10 = lean::box(0);
x_11 = l_String_splitAux___main___closed__1;
x_12 = lean::alloc_cnstr(0, 4, 0);
lean::cnstr_set(x_12, 0, x_2);
lean::cnstr_set(x_12, 1, x_11);
lean::cnstr_set(x_12, 2, x_1);
lean::cnstr_set(x_12, 3, x_10);
x_13 = 0;
x_14 = lean::alloc_cnstr(1, 1, 1);
lean::cnstr_set(x_14, 0, x_12);
lean::cnstr_set_scalar(x_14, sizeof(void*)*1, x_13);
x_15 = x_14;
return x_15;
}
else
{
obj* x_20; obj* x_23; obj* x_24;
obj* x_18; obj* x_21; obj* x_22;
lean::dec(x_1);
lean::dec(x_2);
x_20 = lean::cnstr_get(x_10, 0);
lean::inc(x_20);
lean::dec(x_10);
x_23 = lean::box(0);
x_24 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_24, 0, x_0);
lean::cnstr_set(x_24, 1, x_20);
lean::cnstr_set(x_24, 2, x_23);
return x_24;
x_18 = lean::cnstr_get(x_8, 0);
lean::inc(x_18);
lean::dec(x_8);
x_21 = lean::box(0);
x_22 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_22, 0, x_0);
lean::cnstr_set(x_22, 1, x_18);
lean::cnstr_set(x_22, 2, x_21);
return x_22;
}
}
}
@ -10674,21 +10671,19 @@ return x_2;
obj* l_Lean_Parser_ParsecT_run___at_Lean_Parser_ParsecT_parseWithEoi___spec__3___rarg(obj* x_0, obj* x_1, obj* x_2, obj* x_3, obj* x_4, obj* x_5) {
_start:
{
obj* x_6; obj* x_8; usize x_9; obj* x_10; obj* x_11; obj* x_12; obj* x_13; obj* x_14;
obj* x_6; obj* x_8; obj* x_9; obj* x_10; obj* x_11; obj* x_12;
x_6 = lean::cnstr_get(x_0, 1);
lean::inc(x_6);
x_8 = lean::mk_nat_obj(0ul);
x_9 = l_String_toSubstring___closed__1;
x_10 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
lean::cnstr_set(x_10, 0, x_4);
lean::cnstr_set(x_10, 1, x_8);
lean::cnstr_set_scalar(x_10, sizeof(void*)*2, x_9);
x_11 = x_10;
x_12 = lean::apply_1(x_3, x_11);
x_13 = lean::alloc_closure(reinterpret_cast<void*>(l_Lean_Parser_ParsecT_run___rarg___lambda__1), 2, 1);
lean::closure_set(x_13, 0, x_0);
x_14 = lean::apply_4(x_6, lean::box(0), lean::box(0), x_12, x_13);
return x_14;
x_9 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_9, 0, x_4);
lean::cnstr_set(x_9, 1, x_8);
lean::cnstr_set(x_9, 2, x_8);
x_10 = lean::apply_1(x_3, x_9);
x_11 = lean::alloc_closure(reinterpret_cast<void*>(l_Lean_Parser_ParsecT_run___rarg___lambda__1), 2, 1);
lean::closure_set(x_11, 0, x_0);
x_12 = lean::apply_4(x_6, lean::box(0), lean::box(0), x_10, x_11);
return x_12;
}
}
obj* l_Lean_Parser_ParsecT_run___at_Lean_Parser_ParsecT_parseWithEoi___spec__3(obj* x_0) {
@ -10872,21 +10867,19 @@ return x_2;
obj* l_Lean_Parser_ParsecT_run___at_Lean_Parser_ParsecT_parseWithLeftOver___spec__1___rarg(obj* x_0, obj* x_1, obj* x_2, obj* x_3, obj* x_4, obj* x_5) {
_start:
{
obj* x_6; obj* x_8; usize x_9; obj* x_10; obj* x_11; obj* x_12; obj* x_13; obj* x_14;
obj* x_6; obj* x_8; obj* x_9; obj* x_10; obj* x_11; obj* x_12;
x_6 = lean::cnstr_get(x_0, 1);
lean::inc(x_6);
x_8 = lean::mk_nat_obj(0ul);
x_9 = l_String_toSubstring___closed__1;
x_10 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
lean::cnstr_set(x_10, 0, x_4);
lean::cnstr_set(x_10, 1, x_8);
lean::cnstr_set_scalar(x_10, sizeof(void*)*2, x_9);
x_11 = x_10;
x_12 = lean::apply_1(x_3, x_11);
x_13 = lean::alloc_closure(reinterpret_cast<void*>(l_Lean_Parser_ParsecT_run___rarg___lambda__1), 2, 1);
lean::closure_set(x_13, 0, x_0);
x_14 = lean::apply_4(x_6, lean::box(0), lean::box(0), x_12, x_13);
return x_14;
x_9 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_9, 0, x_4);
lean::cnstr_set(x_9, 1, x_8);
lean::cnstr_set(x_9, 2, x_8);
x_10 = lean::apply_1(x_3, x_9);
x_11 = lean::alloc_closure(reinterpret_cast<void*>(l_Lean_Parser_ParsecT_run___rarg___lambda__1), 2, 1);
lean::closure_set(x_11, 0, x_0);
x_12 = lean::apply_4(x_6, lean::box(0), lean::box(0), x_10, x_11);
return x_12;
}
}
obj* l_Lean_Parser_ParsecT_run___at_Lean_Parser_ParsecT_parseWithLeftOver___spec__1(obj* x_0) {
@ -11203,34 +11196,32 @@ return x_2;
obj* l_Lean_Parser_ParsecT_run___at_Lean_Parser_Parsec_parse___spec__1___rarg(obj* x_0, obj* x_1, obj* x_2) {
_start:
{
obj* x_3; usize x_4; obj* x_5; obj* x_6; obj* x_7;
obj* x_3; obj* x_4; obj* x_5;
x_3 = lean::mk_nat_obj(0ul);
x_4 = l_String_toSubstring___closed__1;
x_5 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
lean::cnstr_set(x_5, 0, x_1);
lean::cnstr_set(x_5, 1, x_3);
lean::cnstr_set_scalar(x_5, sizeof(void*)*2, x_4);
x_6 = x_5;
x_7 = lean::apply_1(x_0, x_6);
if (lean::obj_tag(x_7) == 0)
x_4 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_4, 0, x_1);
lean::cnstr_set(x_4, 1, x_3);
lean::cnstr_set(x_4, 2, x_3);
x_5 = lean::apply_1(x_0, x_4);
if (lean::obj_tag(x_5) == 0)
{
obj* x_8; obj* x_11;
x_8 = lean::cnstr_get(x_7, 0);
lean::inc(x_8);
lean::dec(x_7);
x_11 = lean::alloc_cnstr(1, 1, 0);
lean::cnstr_set(x_11, 0, x_8);
return x_11;
obj* x_6; obj* x_9;
x_6 = lean::cnstr_get(x_5, 0);
lean::inc(x_6);
lean::dec(x_5);
x_9 = lean::alloc_cnstr(1, 1, 0);
lean::cnstr_set(x_9, 0, x_6);
return x_9;
}
else
{
obj* x_12; obj* x_15;
x_12 = lean::cnstr_get(x_7, 0);
lean::inc(x_12);
lean::dec(x_7);
x_15 = lean::alloc_cnstr(0, 1, 0);
lean::cnstr_set(x_15, 0, x_12);
return x_15;
obj* x_10; obj* x_13;
x_10 = lean::cnstr_get(x_5, 0);
lean::inc(x_10);
lean::dec(x_5);
x_13 = lean::alloc_cnstr(0, 1, 0);
lean::cnstr_set(x_13, 0, x_10);
return x_13;
}
}
}

View file

@ -24,7 +24,6 @@ namespace lean {
obj* nat_sub(obj*, obj*);
}
obj* l_Lean_Parser_MonadParsec_error___at_Lean_Parser_currLbp___spec__3(obj*, obj*);
extern usize l_String_toSubstring___closed__1;
obj* l_Lean_Parser_prattParser_View___boxed(obj*);
extern obj* l_mjoin___rarg___closed__1;
obj* l_Lean_Parser_currLbp___rarg___lambda__3___closed__2;
@ -210,32 +209,30 @@ return x_20;
obj* l_Lean_Parser_currLbp___rarg___lambda__2(obj* x_0, obj* x_1, obj* x_2, obj* x_3, obj* x_4, obj* x_5) {
_start:
{
obj* x_6; obj* x_9; usize x_10; obj* x_11; obj* x_12; obj* x_13; obj* x_14; obj* x_16; obj* x_20; obj* x_21; obj* x_22;
obj* x_6; obj* x_9; obj* x_10; obj* x_11; obj* x_12; obj* x_14; obj* x_18; obj* x_19; obj* x_20;
x_6 = lean::cnstr_get(x_5, 1);
lean::inc(x_6);
lean::dec(x_5);
x_9 = lean::mk_nat_obj(0ul);
x_10 = l_String_toSubstring___closed__1;
x_11 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
lean::cnstr_set(x_11, 0, x_0);
lean::cnstr_set(x_11, 1, x_9);
lean::cnstr_set_scalar(x_11, sizeof(void*)*2, x_10);
x_12 = x_11;
x_13 = l_Lean_Parser_Trie_matchPrefix___rarg(x_6, x_12);
x_14 = lean::cnstr_get(x_1, 0);
x_10 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_10, 0, x_0);
lean::cnstr_set(x_10, 1, x_9);
lean::cnstr_set(x_10, 2, x_9);
x_11 = l_Lean_Parser_Trie_matchPrefix___rarg(x_6, x_10);
x_12 = lean::cnstr_get(x_1, 0);
lean::inc(x_12);
x_14 = lean::cnstr_get(x_12, 1);
lean::inc(x_14);
x_16 = lean::cnstr_get(x_14, 1);
lean::inc(x_16);
lean::dec(x_14);
lean::inc(x_16);
x_20 = lean::apply_2(x_16, lean::box(0), x_13);
x_21 = lean::alloc_closure(reinterpret_cast<void*>(l_Lean_Parser_currLbp___rarg___lambda__1___boxed), 5, 4);
lean::closure_set(x_21, 0, x_1);
lean::closure_set(x_21, 1, x_2);
lean::closure_set(x_21, 2, x_3);
lean::closure_set(x_21, 3, x_16);
x_22 = lean::apply_4(x_4, lean::box(0), lean::box(0), x_20, x_21);
return x_22;
lean::dec(x_12);
lean::inc(x_14);
x_18 = lean::apply_2(x_14, lean::box(0), x_11);
x_19 = lean::alloc_closure(reinterpret_cast<void*>(l_Lean_Parser_currLbp___rarg___lambda__1___boxed), 5, 4);
lean::closure_set(x_19, 0, x_1);
lean::closure_set(x_19, 1, x_2);
lean::closure_set(x_19, 2, x_3);
lean::closure_set(x_19, 3, x_14);
x_20 = lean::apply_4(x_4, lean::box(0), lean::box(0), x_18, x_19);
return x_20;
}
}
obj* _init_l_Lean_Parser_currLbp___rarg___lambda__3___closed__1() {

View file

@ -31,7 +31,6 @@ obj* l_Lean_Parser_Syntax_mreplaceLst___main___at_Lean_Parser_Syntax_updateLeadi
obj* l_Lean_Parser_Syntax_getHeadInfo___boxed(obj*);
extern obj* l_Lean_Format_paren___closed__2;
obj* l_List_map___main___at_Lean_Parser_Syntax_asNode___main___spec__1(obj*, obj*);
extern usize l_String_toSubstring___closed__1;
obj* l_Lean_Parser_Syntax_updateLeading___closed__1;
obj* l_Lean_Parser_Syntax_getHeadInfoLst___main(obj*);
obj* l_Lean_Parser_MacroScope_DecidableEq;
@ -230,20 +229,18 @@ return x_1;
obj* l_Lean_Parser_Substring_ofString(obj* x_0) {
_start:
{
obj* x_1; usize x_2; obj* x_3; obj* x_4; obj* x_6; obj* x_7;
obj* x_1; obj* x_2; obj* x_4; obj* x_5;
x_1 = lean::mk_nat_obj(0ul);
x_2 = l_String_toSubstring___closed__1;
x_3 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
lean::cnstr_set(x_3, 0, x_0);
lean::cnstr_set(x_3, 1, x_1);
lean::cnstr_set_scalar(x_3, sizeof(void*)*2, x_2);
x_4 = x_3;
lean::inc(x_4);
x_6 = l_String_OldIterator_toEnd___main(x_4);
x_7 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_7, 0, x_4);
lean::cnstr_set(x_7, 1, x_6);
return x_7;
x_2 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_2, 0, x_0);
lean::cnstr_set(x_2, 1, x_1);
lean::cnstr_set(x_2, 2, x_1);
lean::inc(x_2);
x_4 = l_String_OldIterator_toEnd___main(x_2);
x_5 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_5, 0, x_2);
lean::cnstr_set(x_5, 1, x_4);
return x_5;
}
}
obj* _init_l_Lean_Parser_Substring_HasToString() {
@ -1450,20 +1447,18 @@ return x_0;
obj* l_Lean_Parser_Syntax_updateLeading(obj* x_0, obj* x_1) {
_start:
{
obj* x_2; usize x_3; obj* x_4; obj* x_5; obj* x_6; obj* x_7; obj* x_8;
obj* x_2; obj* x_3; obj* x_4; obj* x_5; obj* x_6;
x_2 = lean::mk_nat_obj(0ul);
x_3 = l_String_toSubstring___closed__1;
x_4 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
lean::cnstr_set(x_4, 0, x_0);
lean::cnstr_set(x_4, 1, x_2);
lean::cnstr_set_scalar(x_4, sizeof(void*)*2, x_3);
x_5 = x_4;
x_6 = l_Lean_Parser_Syntax_updateLeading___closed__1;
x_7 = l_Lean_Parser_Syntax_mreplace___main___at_Lean_Parser_Syntax_updateLeading___spec__1(x_6, x_1, x_5);
x_8 = lean::cnstr_get(x_7, 0);
lean::inc(x_8);
lean::dec(x_7);
return x_8;
x_3 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_3, 0, x_0);
lean::cnstr_set(x_3, 1, x_2);
lean::cnstr_set(x_3, 2, x_2);
x_4 = l_Lean_Parser_Syntax_updateLeading___closed__1;
x_5 = l_Lean_Parser_Syntax_mreplace___main___at_Lean_Parser_Syntax_updateLeading___spec__1(x_4, x_1, x_3);
x_6 = lean::cnstr_get(x_5, 0);
lean::inc(x_6);
lean::dec(x_5);
return x_6;
}
}
obj* l_Lean_Parser_Syntax_getHeadInfo___main(obj* x_0) {

View file

@ -115,7 +115,6 @@ obj* l_Lean_Parser_Term_letLhsId;
obj* l_Lean_Parser_Term_bracketedBinder_Parser_Lean_Parser_HasTokens___closed__1;
obj* l_Lean_Parser_Term_structInstWith_HasView_x_27___lambda__2(obj*);
extern obj* l_Lean_Parser_Combinators_choiceAux___main___rarg___closed__1;
extern usize l_String_toSubstring___closed__1;
obj* l_Lean_Parser_Term_structInstField_HasView_x_27___lambda__1(obj*);
obj* l_Lean_Parser_Term_implicitBinder_HasView_x_27___lambda__1___closed__1;
obj* l_Lean_Parser_Term_bindersTypes_HasView_x_27___lambda__1___closed__1;
@ -43519,73 +43518,71 @@ uint8 x_8;
x_8 = l_String_isEmpty(x_0);
if (x_8 == 0)
{
obj* x_9; obj* x_10; usize x_11; obj* x_13; obj* x_14; obj* x_16;
obj* x_9; obj* x_10; obj* x_12; obj* x_14;
x_9 = lean::string_length(x_0);
x_10 = lean::mk_nat_obj(0ul);
x_11 = l_String_toSubstring___closed__1;
lean::inc(x_0);
x_13 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
lean::cnstr_set(x_13, 0, x_0);
lean::cnstr_set(x_13, 1, x_10);
lean::cnstr_set_scalar(x_13, sizeof(void*)*2, x_11);
x_14 = x_13;
x_12 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_12, 0, x_0);
lean::cnstr_set(x_12, 1, x_10);
lean::cnstr_set(x_12, 2, x_10);
lean::inc(x_6);
x_16 = l___private_init_lean_parser_parsec_2__strAux___main(x_9, x_14, x_6);
if (lean::obj_tag(x_16) == 0)
x_14 = l___private_init_lean_parser_parsec_2__strAux___main(x_9, x_12, x_6);
if (lean::obj_tag(x_14) == 0)
{
obj* x_18; obj* x_19; obj* x_20; uint8 x_21; obj* x_22; obj* x_23; obj* x_24;
obj* x_16; obj* x_17; obj* x_18; uint8 x_19; obj* x_20; obj* x_21; obj* x_22;
lean::dec(x_0);
x_18 = lean::box(0);
x_19 = l_String_splitAux___main___closed__1;
x_20 = lean::alloc_cnstr(0, 4, 0);
lean::cnstr_set(x_20, 0, x_6);
lean::cnstr_set(x_20, 1, x_19);
lean::cnstr_set(x_20, 2, x_1);
lean::cnstr_set(x_20, 3, x_18);
x_21 = 0;
x_22 = lean::alloc_cnstr(1, 1, 1);
lean::cnstr_set(x_22, 0, x_20);
lean::cnstr_set_scalar(x_22, sizeof(void*)*1, x_21);
x_23 = x_22;
x_24 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_24, 0, x_23);
lean::cnstr_set(x_24, 1, x_7);
return x_24;
x_16 = lean::box(0);
x_17 = l_String_splitAux___main___closed__1;
x_18 = lean::alloc_cnstr(0, 4, 0);
lean::cnstr_set(x_18, 0, x_6);
lean::cnstr_set(x_18, 1, x_17);
lean::cnstr_set(x_18, 2, x_1);
lean::cnstr_set(x_18, 3, x_16);
x_19 = 0;
x_20 = lean::alloc_cnstr(1, 1, 1);
lean::cnstr_set(x_20, 0, x_18);
lean::cnstr_set_scalar(x_20, sizeof(void*)*1, x_19);
x_21 = x_20;
x_22 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_22, 0, x_21);
lean::cnstr_set(x_22, 1, x_7);
return x_22;
}
else
{
obj* x_27; obj* x_30; obj* x_31; obj* x_32;
obj* x_25; obj* x_28; obj* x_29; obj* x_30;
lean::dec(x_1);
lean::dec(x_6);
x_27 = lean::cnstr_get(x_16, 0);
lean::inc(x_27);
lean::dec(x_16);
x_30 = lean::box(0);
x_31 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_31, 0, x_0);
lean::cnstr_set(x_31, 1, x_27);
lean::cnstr_set(x_31, 2, x_30);
x_32 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_32, 0, x_31);
lean::cnstr_set(x_32, 1, x_7);
return x_32;
x_25 = lean::cnstr_get(x_14, 0);
lean::inc(x_25);
lean::dec(x_14);
x_28 = lean::box(0);
x_29 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_29, 0, x_0);
lean::cnstr_set(x_29, 1, x_25);
lean::cnstr_set(x_29, 2, x_28);
x_30 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_30, 0, x_29);
lean::cnstr_set(x_30, 1, x_7);
return x_30;
}
}
else
{
obj* x_35; obj* x_36; obj* x_37; obj* x_38;
obj* x_33; obj* x_34; obj* x_35; obj* x_36;
lean::dec(x_1);
lean::dec(x_0);
x_35 = l_String_splitAux___main___closed__1;
x_36 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
x_37 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_37, 0, x_35);
lean::cnstr_set(x_37, 1, x_6);
lean::cnstr_set(x_37, 2, x_36);
x_38 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_38, 0, x_37);
lean::cnstr_set(x_38, 1, x_7);
return x_38;
x_33 = l_String_splitAux___main___closed__1;
x_34 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
x_35 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_35, 0, x_33);
lean::cnstr_set(x_35, 1, x_6);
lean::cnstr_set(x_35, 2, x_34);
x_36 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_36, 0, x_35);
lean::cnstr_set(x_36, 1, x_7);
return x_36;
}
}
}
@ -48073,7 +48070,7 @@ lean::dec(x_10);
switch (lean::obj_tag(x_27)) {
case 0:
{
obj* x_30; obj* x_33; obj* x_36; obj* x_38; obj* x_40; obj* x_41; obj* x_44; obj* x_46; usize x_47; obj* x_48; obj* x_49; obj* x_50;
obj* x_30; obj* x_33; obj* x_36; obj* x_38; obj* x_40; obj* x_41; obj* x_44; obj* x_46; obj* x_47; obj* x_48;
x_30 = lean::cnstr_get(x_27, 0);
lean::inc(x_30);
lean::dec(x_27);
@ -48099,330 +48096,328 @@ lean::dec(x_30);
x_44 = lean::cnstr_get(x_1, 1);
lean::inc(x_44);
x_46 = lean::mk_nat_obj(0ul);
x_47 = l_String_toSubstring___closed__1;
x_48 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
lean::cnstr_set(x_48, 0, x_41);
lean::cnstr_set(x_48, 1, x_46);
lean::cnstr_set_scalar(x_48, sizeof(void*)*2, x_47);
x_49 = x_48;
x_50 = l_Lean_Parser_Trie_matchPrefix___rarg(x_44, x_49);
if (lean::obj_tag(x_50) == 0)
x_47 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_47, 0, x_41);
lean::cnstr_set(x_47, 1, x_46);
lean::cnstr_set(x_47, 2, x_46);
x_48 = l_Lean_Parser_Trie_matchPrefix___rarg(x_44, x_47);
if (lean::obj_tag(x_48) == 0)
{
obj* x_52; obj* x_53; obj* x_54; obj* x_55; obj* x_58; obj* x_60; obj* x_62; obj* x_63; obj* x_64; obj* x_65; obj* x_66; obj* x_67;
obj* x_50; obj* x_51; obj* x_52; obj* x_53; obj* x_56; obj* x_58; obj* x_60; obj* x_61; obj* x_62; obj* x_63; obj* x_64; obj* x_65;
lean::dec(x_40);
x_52 = lean::box(0);
x_53 = l_Lean_Parser_currLbp___rarg___lambda__1___closed__1;
x_54 = l_mjoin___rarg___closed__1;
x_55 = l_Lean_Parser_MonadParsec_error___at_Lean_Parser_termParser_run___spec__4___rarg(x_53, x_54, x_52, x_52, x_0, x_1, x_2, x_36, x_33);
x_50 = lean::box(0);
x_51 = l_Lean_Parser_currLbp___rarg___lambda__1___closed__1;
x_52 = l_mjoin___rarg___closed__1;
x_53 = l_Lean_Parser_MonadParsec_error___at_Lean_Parser_termParser_run___spec__4___rarg(x_51, x_52, x_50, x_50, x_0, x_1, x_2, x_36, x_33);
lean::dec(x_36);
lean::dec(x_1);
x_58 = lean::cnstr_get(x_55, 0);
x_60 = lean::cnstr_get(x_55, 1);
if (lean::is_exclusive(x_55)) {
x_62 = x_55;
x_56 = lean::cnstr_get(x_53, 0);
x_58 = lean::cnstr_get(x_53, 1);
if (lean::is_exclusive(x_53)) {
x_60 = x_53;
} else {
lean::inc(x_56);
lean::inc(x_58);
lean::inc(x_60);
lean::dec(x_55);
x_62 = lean::box(0);
lean::dec(x_53);
x_60 = lean::box(0);
}
x_63 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
x_64 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_63, x_58);
x_65 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_63, x_64);
x_66 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_38, x_65);
if (lean::is_scalar(x_62)) {
x_67 = lean::alloc_cnstr(0, 2, 0);
x_61 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
x_62 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_61, x_56);
x_63 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_61, x_62);
x_64 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_38, x_63);
if (lean::is_scalar(x_60)) {
x_65 = lean::alloc_cnstr(0, 2, 0);
} else {
x_67 = x_62;
x_65 = x_60;
}
lean::cnstr_set(x_67, 0, x_66);
lean::cnstr_set(x_67, 1, x_60);
return x_67;
lean::cnstr_set(x_65, 0, x_64);
lean::cnstr_set(x_65, 1, x_58);
return x_65;
}
else
{
obj* x_69; obj* x_72; obj* x_74; obj* x_75; obj* x_78; obj* x_79; obj* x_80; obj* x_81;
obj* x_67; obj* x_70; obj* x_72; obj* x_73; obj* x_76; obj* x_77; obj* x_78; obj* x_79;
lean::dec(x_1);
x_69 = lean::cnstr_get(x_50, 0);
lean::inc(x_69);
lean::dec(x_50);
x_72 = lean::cnstr_get(x_69, 1);
if (lean::is_exclusive(x_69)) {
lean::cnstr_release(x_69, 0);
x_74 = x_69;
x_67 = lean::cnstr_get(x_48, 0);
lean::inc(x_67);
lean::dec(x_48);
x_70 = lean::cnstr_get(x_67, 1);
if (lean::is_exclusive(x_67)) {
lean::cnstr_release(x_67, 0);
x_72 = x_67;
} else {
lean::inc(x_72);
lean::dec(x_69);
x_74 = lean::box(0);
lean::inc(x_70);
lean::dec(x_67);
x_72 = lean::box(0);
}
x_75 = lean::cnstr_get(x_72, 1);
lean::inc(x_75);
lean::dec(x_72);
x_78 = l_Lean_Parser_matchToken___closed__1;
x_73 = lean::cnstr_get(x_70, 1);
lean::inc(x_73);
lean::dec(x_70);
x_76 = l_Lean_Parser_matchToken___closed__1;
if (lean::is_scalar(x_40)) {
x_79 = lean::alloc_cnstr(0, 3, 0);
x_77 = lean::alloc_cnstr(0, 3, 0);
} else {
x_79 = x_40;
x_77 = x_40;
}
lean::cnstr_set(x_79, 0, x_75);
lean::cnstr_set(x_79, 1, x_36);
lean::cnstr_set(x_79, 2, x_78);
x_80 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_38, x_79);
if (lean::is_scalar(x_74)) {
x_81 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_77, 0, x_73);
lean::cnstr_set(x_77, 1, x_36);
lean::cnstr_set(x_77, 2, x_76);
x_78 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_38, x_77);
if (lean::is_scalar(x_72)) {
x_79 = lean::alloc_cnstr(0, 2, 0);
} else {
x_81 = x_74;
x_79 = x_72;
}
lean::cnstr_set(x_81, 0, x_80);
lean::cnstr_set(x_81, 1, x_33);
return x_81;
lean::cnstr_set(x_79, 0, x_78);
lean::cnstr_set(x_79, 1, x_33);
return x_79;
}
}
case 1:
{
obj* x_84; obj* x_86; obj* x_87; obj* x_89; obj* x_91; obj* x_92; obj* x_93; obj* x_94; obj* x_95; obj* x_96;
obj* x_82; obj* x_84; obj* x_85; obj* x_87; obj* x_89; obj* x_90; obj* x_91; obj* x_92; obj* x_93; obj* x_94;
lean::dec(x_1);
lean::dec(x_27);
x_84 = lean::cnstr_get(x_7, 1);
x_82 = lean::cnstr_get(x_7, 1);
if (lean::is_exclusive(x_7)) {
lean::cnstr_release(x_7, 0);
x_86 = x_7;
x_84 = x_7;
} else {
lean::inc(x_84);
lean::inc(x_82);
lean::dec(x_7);
x_86 = lean::box(0);
x_84 = lean::box(0);
}
x_87 = lean::cnstr_get(x_8, 1);
x_89 = lean::cnstr_get(x_8, 2);
x_85 = lean::cnstr_get(x_8, 1);
x_87 = lean::cnstr_get(x_8, 2);
if (lean::is_exclusive(x_8)) {
lean::cnstr_release(x_8, 0);
x_91 = x_8;
x_89 = x_8;
} else {
lean::inc(x_85);
lean::inc(x_87);
lean::inc(x_89);
lean::dec(x_8);
x_91 = lean::box(0);
x_89 = lean::box(0);
}
x_92 = l_Lean_Parser_maxPrec;
x_93 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
if (lean::is_scalar(x_91)) {
x_94 = lean::alloc_cnstr(0, 3, 0);
x_90 = l_Lean_Parser_maxPrec;
x_91 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
if (lean::is_scalar(x_89)) {
x_92 = lean::alloc_cnstr(0, 3, 0);
} else {
x_94 = x_91;
x_92 = x_89;
}
lean::cnstr_set(x_94, 0, x_92);
lean::cnstr_set(x_94, 1, x_87);
lean::cnstr_set(x_94, 2, x_93);
x_95 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_89, x_94);
if (lean::is_scalar(x_86)) {
x_96 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_92, 0, x_90);
lean::cnstr_set(x_92, 1, x_85);
lean::cnstr_set(x_92, 2, x_91);
x_93 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_87, x_92);
if (lean::is_scalar(x_84)) {
x_94 = lean::alloc_cnstr(0, 2, 0);
} else {
x_96 = x_86;
x_94 = x_84;
}
lean::cnstr_set(x_96, 0, x_95);
lean::cnstr_set(x_96, 1, x_84);
return x_96;
lean::cnstr_set(x_94, 0, x_93);
lean::cnstr_set(x_94, 1, x_82);
return x_94;
}
case 2:
{
obj* x_97; obj* x_100; obj* x_102; obj* x_103; obj* x_105; obj* x_107; obj* x_108; obj* x_111; uint8 x_112;
x_97 = lean::cnstr_get(x_27, 0);
lean::inc(x_97);
obj* x_95; obj* x_98; obj* x_100; obj* x_101; obj* x_103; obj* x_105; obj* x_106; obj* x_109; uint8 x_110;
x_95 = lean::cnstr_get(x_27, 0);
lean::inc(x_95);
lean::dec(x_27);
x_100 = lean::cnstr_get(x_7, 1);
x_98 = lean::cnstr_get(x_7, 1);
if (lean::is_exclusive(x_7)) {
lean::cnstr_release(x_7, 0);
lean::cnstr_set(x_7, 1, lean::box(0));
x_102 = x_7;
x_100 = x_7;
} else {
lean::inc(x_100);
lean::inc(x_98);
lean::dec(x_7);
x_102 = lean::box(0);
x_100 = lean::box(0);
}
x_103 = lean::cnstr_get(x_8, 1);
x_105 = lean::cnstr_get(x_8, 2);
x_101 = lean::cnstr_get(x_8, 1);
x_103 = lean::cnstr_get(x_8, 2);
if (lean::is_exclusive(x_8)) {
lean::cnstr_release(x_8, 0);
lean::cnstr_set(x_8, 1, lean::box(0));
lean::cnstr_set(x_8, 2, lean::box(0));
x_107 = x_8;
x_105 = x_8;
} else {
lean::inc(x_101);
lean::inc(x_103);
lean::inc(x_105);
lean::dec(x_8);
x_107 = lean::box(0);
x_105 = lean::box(0);
}
x_108 = lean::cnstr_get(x_97, 0);
lean::inc(x_108);
lean::dec(x_97);
x_111 = l_Lean_Parser_number_HasView_x_27___lambda__1___closed__6;
x_112 = lean_name_dec_eq(x_108, x_111);
x_106 = lean::cnstr_get(x_95, 0);
lean::inc(x_106);
lean::dec(x_95);
x_109 = l_Lean_Parser_number_HasView_x_27___lambda__1___closed__6;
x_110 = lean_name_dec_eq(x_106, x_109);
if (x_110 == 0)
{
obj* x_111; uint8 x_112;
x_111 = l_Lean_Parser_currLbp___rarg___lambda__3___closed__1;
x_112 = lean_name_dec_eq(x_106, x_111);
lean::dec(x_106);
if (x_112 == 0)
{
obj* x_113; uint8 x_114;
x_113 = l_Lean_Parser_currLbp___rarg___lambda__3___closed__1;
x_114 = lean_name_dec_eq(x_108, x_113);
lean::dec(x_108);
if (x_114 == 0)
{
obj* x_118; obj* x_119; obj* x_120; obj* x_121; obj* x_124; obj* x_126; obj* x_128; obj* x_129; obj* x_130;
lean::dec(x_102);
lean::dec(x_107);
x_118 = lean::box(0);
x_119 = l_Lean_Parser_currLbp___rarg___lambda__3___closed__2;
x_120 = l_mjoin___rarg___closed__1;
x_121 = l_Lean_Parser_MonadParsec_error___at_Lean_Parser_termParser_run___spec__4___rarg(x_119, x_120, x_118, x_118, x_0, x_1, x_2, x_103, x_100);
lean::dec(x_103);
obj* x_116; obj* x_117; obj* x_118; obj* x_119; obj* x_122; obj* x_124; obj* x_126; obj* x_127; obj* x_128;
lean::dec(x_100);
lean::dec(x_105);
x_116 = lean::box(0);
x_117 = l_Lean_Parser_currLbp___rarg___lambda__3___closed__2;
x_118 = l_mjoin___rarg___closed__1;
x_119 = l_Lean_Parser_MonadParsec_error___at_Lean_Parser_termParser_run___spec__4___rarg(x_117, x_118, x_116, x_116, x_0, x_1, x_2, x_101, x_98);
lean::dec(x_101);
lean::dec(x_1);
x_124 = lean::cnstr_get(x_121, 0);
x_126 = lean::cnstr_get(x_121, 1);
if (lean::is_exclusive(x_121)) {
x_128 = x_121;
x_122 = lean::cnstr_get(x_119, 0);
x_124 = lean::cnstr_get(x_119, 1);
if (lean::is_exclusive(x_119)) {
x_126 = x_119;
} else {
lean::inc(x_122);
lean::inc(x_124);
lean::inc(x_126);
lean::dec(x_121);
x_128 = lean::box(0);
lean::dec(x_119);
x_126 = lean::box(0);
}
x_129 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_105, x_124);
if (lean::is_scalar(x_128)) {
x_130 = lean::alloc_cnstr(0, 2, 0);
x_127 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_103, x_122);
if (lean::is_scalar(x_126)) {
x_128 = lean::alloc_cnstr(0, 2, 0);
} else {
x_130 = x_128;
x_128 = x_126;
}
lean::cnstr_set(x_130, 0, x_129);
lean::cnstr_set(x_130, 1, x_126);
return x_130;
lean::cnstr_set(x_128, 0, x_127);
lean::cnstr_set(x_128, 1, x_124);
return x_128;
}
else
{
obj* x_132; obj* x_133; obj* x_134; obj* x_135; obj* x_136;
obj* x_130; obj* x_131; obj* x_132; obj* x_133; obj* x_134;
lean::dec(x_1);
x_132 = l_Lean_Parser_maxPrec;
x_133 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
if (lean::is_scalar(x_107)) {
x_134 = lean::alloc_cnstr(0, 3, 0);
x_130 = l_Lean_Parser_maxPrec;
x_131 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
if (lean::is_scalar(x_105)) {
x_132 = lean::alloc_cnstr(0, 3, 0);
} else {
x_134 = x_107;
x_132 = x_105;
}
lean::cnstr_set(x_134, 0, x_132);
lean::cnstr_set(x_134, 1, x_103);
lean::cnstr_set(x_134, 2, x_133);
x_135 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_105, x_134);
if (lean::is_scalar(x_102)) {
x_136 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_132, 0, x_130);
lean::cnstr_set(x_132, 1, x_101);
lean::cnstr_set(x_132, 2, x_131);
x_133 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_103, x_132);
if (lean::is_scalar(x_100)) {
x_134 = lean::alloc_cnstr(0, 2, 0);
} else {
x_136 = x_102;
x_134 = x_100;
}
lean::cnstr_set(x_136, 0, x_135);
lean::cnstr_set(x_136, 1, x_100);
return x_136;
lean::cnstr_set(x_134, 0, x_133);
lean::cnstr_set(x_134, 1, x_98);
return x_134;
}
}
else
{
obj* x_139; obj* x_140; obj* x_141; obj* x_142; obj* x_143;
obj* x_137; obj* x_138; obj* x_139; obj* x_140; obj* x_141;
lean::dec(x_1);
lean::dec(x_108);
x_139 = l_Lean_Parser_maxPrec;
x_140 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
if (lean::is_scalar(x_107)) {
x_141 = lean::alloc_cnstr(0, 3, 0);
lean::dec(x_106);
x_137 = l_Lean_Parser_maxPrec;
x_138 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
if (lean::is_scalar(x_105)) {
x_139 = lean::alloc_cnstr(0, 3, 0);
} else {
x_141 = x_107;
x_139 = x_105;
}
lean::cnstr_set(x_141, 0, x_139);
lean::cnstr_set(x_141, 1, x_103);
lean::cnstr_set(x_141, 2, x_140);
x_142 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_105, x_141);
if (lean::is_scalar(x_102)) {
x_143 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_139, 0, x_137);
lean::cnstr_set(x_139, 1, x_101);
lean::cnstr_set(x_139, 2, x_138);
x_140 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_103, x_139);
if (lean::is_scalar(x_100)) {
x_141 = lean::alloc_cnstr(0, 2, 0);
} else {
x_143 = x_102;
x_141 = x_100;
}
lean::cnstr_set(x_143, 0, x_142);
lean::cnstr_set(x_143, 1, x_100);
return x_143;
lean::cnstr_set(x_141, 0, x_140);
lean::cnstr_set(x_141, 1, x_98);
return x_141;
}
}
default:
{
obj* x_144; obj* x_147; obj* x_149; obj* x_152; obj* x_153; obj* x_154; obj* x_155; obj* x_158; obj* x_160; obj* x_162; obj* x_163; obj* x_164;
x_144 = lean::cnstr_get(x_7, 1);
lean::inc(x_144);
obj* x_142; obj* x_145; obj* x_147; obj* x_150; obj* x_151; obj* x_152; obj* x_153; obj* x_156; obj* x_158; obj* x_160; obj* x_161; obj* x_162;
x_142 = lean::cnstr_get(x_7, 1);
lean::inc(x_142);
lean::dec(x_7);
x_147 = lean::cnstr_get(x_8, 1);
x_145 = lean::cnstr_get(x_8, 1);
lean::inc(x_145);
x_147 = lean::cnstr_get(x_8, 2);
lean::inc(x_147);
x_149 = lean::cnstr_get(x_8, 2);
lean::inc(x_149);
lean::dec(x_8);
x_152 = lean::box(0);
x_153 = l_Lean_Parser_currLbp___rarg___lambda__3___closed__2;
x_154 = l_mjoin___rarg___closed__1;
x_155 = l_Lean_Parser_MonadParsec_error___at_Lean_Parser_termParser_run___spec__4___rarg(x_153, x_154, x_152, x_152, x_0, x_1, x_2, x_147, x_144);
lean::dec(x_147);
x_150 = lean::box(0);
x_151 = l_Lean_Parser_currLbp___rarg___lambda__3___closed__2;
x_152 = l_mjoin___rarg___closed__1;
x_153 = l_Lean_Parser_MonadParsec_error___at_Lean_Parser_termParser_run___spec__4___rarg(x_151, x_152, x_150, x_150, x_0, x_1, x_2, x_145, x_142);
lean::dec(x_145);
lean::dec(x_1);
x_158 = lean::cnstr_get(x_155, 0);
x_160 = lean::cnstr_get(x_155, 1);
if (lean::is_exclusive(x_155)) {
x_162 = x_155;
x_156 = lean::cnstr_get(x_153, 0);
x_158 = lean::cnstr_get(x_153, 1);
if (lean::is_exclusive(x_153)) {
x_160 = x_153;
} else {
lean::inc(x_156);
lean::inc(x_158);
lean::inc(x_160);
lean::dec(x_155);
x_162 = lean::box(0);
lean::dec(x_153);
x_160 = lean::box(0);
}
x_163 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_149, x_158);
if (lean::is_scalar(x_162)) {
x_164 = lean::alloc_cnstr(0, 2, 0);
x_161 = l_Lean_Parser_ParsecT_bindMkRes___rarg(x_147, x_156);
if (lean::is_scalar(x_160)) {
x_162 = lean::alloc_cnstr(0, 2, 0);
} else {
x_164 = x_162;
x_162 = x_160;
}
lean::cnstr_set(x_164, 0, x_163);
lean::cnstr_set(x_164, 1, x_160);
return x_164;
lean::cnstr_set(x_162, 0, x_161);
lean::cnstr_set(x_162, 1, x_158);
return x_162;
}
}
}
}
else
{
obj* x_166; obj* x_168; obj* x_169; uint8 x_171; obj* x_172; obj* x_173; obj* x_174; obj* x_175;
obj* x_164; obj* x_166; obj* x_167; uint8 x_169; obj* x_170; obj* x_171; obj* x_172; obj* x_173;
lean::dec(x_1);
x_166 = lean::cnstr_get(x_7, 1);
x_164 = lean::cnstr_get(x_7, 1);
if (lean::is_exclusive(x_7)) {
lean::cnstr_release(x_7, 0);
x_168 = x_7;
x_166 = x_7;
} else {
lean::inc(x_166);
lean::inc(x_164);
lean::dec(x_7);
x_168 = lean::box(0);
x_166 = lean::box(0);
}
x_169 = lean::cnstr_get(x_8, 0);
x_171 = lean::cnstr_get_scalar<uint8>(x_8, sizeof(void*)*1);
x_167 = lean::cnstr_get(x_8, 0);
x_169 = lean::cnstr_get_scalar<uint8>(x_8, sizeof(void*)*1);
if (lean::is_exclusive(x_8)) {
x_172 = x_8;
x_170 = x_8;
} else {
lean::inc(x_169);
lean::inc(x_167);
lean::dec(x_8);
x_172 = lean::box(0);
x_170 = lean::box(0);
}
if (lean::is_scalar(x_172)) {
x_173 = lean::alloc_cnstr(1, 1, 1);
if (lean::is_scalar(x_170)) {
x_171 = lean::alloc_cnstr(1, 1, 1);
} else {
x_173 = x_172;
x_171 = x_170;
}
lean::cnstr_set(x_173, 0, x_169);
lean::cnstr_set_scalar(x_173, sizeof(void*)*1, x_171);
x_174 = x_173;
if (lean::is_scalar(x_168)) {
x_175 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_171, 0, x_167);
lean::cnstr_set_scalar(x_171, sizeof(void*)*1, x_169);
x_172 = x_171;
if (lean::is_scalar(x_166)) {
x_173 = lean::alloc_cnstr(0, 2, 0);
} else {
x_175 = x_168;
x_173 = x_166;
}
lean::cnstr_set(x_175, 0, x_174);
lean::cnstr_set(x_175, 1, x_166);
return x_175;
lean::cnstr_set(x_173, 0, x_172);
lean::cnstr_set(x_173, 1, x_164);
return x_173;
}
}
}

View file

@ -103,7 +103,6 @@ extern obj* l_Lean_Parser_parseHexDigit___rarg___lambda__3___closed__1;
obj* l_Lean_Parser_stringLit_Parser___rarg(obj*);
extern obj* l_Lean_Parser_Combinators_choiceAux___main___rarg___closed__1;
obj* l_ReaderT_bind___at_Lean_Parser_detailIdentSuffix_Parser_Lean_Parser_HasTokens___spec__6(obj*, obj*);
extern usize l_String_toSubstring___closed__1;
obj* l_Lean_Parser_symbolOrIdent___boxed(obj*);
obj* l_Lean_Parser_MonadParsec_takeWhileCont___at___private_init_lean_parser_token_4__ident_x_27___spec__8___boxed(obj*, obj*, obj*, obj*);
obj* l_Lean_Parser_parseQuotedChar___at_Lean_Parser_stringLit_x_27___spec__3(obj*, obj*, obj*);
@ -954,73 +953,71 @@ uint8 x_5;
x_5 = l_String_isEmpty(x_0);
if (x_5 == 0)
{
obj* x_6; obj* x_7; usize x_8; obj* x_10; obj* x_11; obj* x_13;
obj* x_6; obj* x_7; obj* x_9; obj* x_11;
x_6 = lean::string_length(x_0);
x_7 = lean::mk_nat_obj(0ul);
x_8 = l_String_toSubstring___closed__1;
lean::inc(x_0);
x_10 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
lean::cnstr_set(x_10, 0, x_0);
lean::cnstr_set(x_10, 1, x_7);
lean::cnstr_set_scalar(x_10, sizeof(void*)*2, x_8);
x_11 = x_10;
x_9 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_9, 0, x_0);
lean::cnstr_set(x_9, 1, x_7);
lean::cnstr_set(x_9, 2, x_7);
lean::inc(x_3);
x_13 = l___private_init_lean_parser_parsec_2__strAux___main(x_6, x_11, x_3);
if (lean::obj_tag(x_13) == 0)
x_11 = l___private_init_lean_parser_parsec_2__strAux___main(x_6, x_9, x_3);
if (lean::obj_tag(x_11) == 0)
{
obj* x_15; obj* x_16; obj* x_17; uint8 x_18; obj* x_19; obj* x_20; obj* x_21;
obj* x_13; obj* x_14; obj* x_15; uint8 x_16; obj* x_17; obj* x_18; obj* x_19;
lean::dec(x_0);
x_15 = lean::box(0);
x_16 = l_String_splitAux___main___closed__1;
x_17 = lean::alloc_cnstr(0, 4, 0);
lean::cnstr_set(x_17, 0, x_3);
lean::cnstr_set(x_17, 1, x_16);
lean::cnstr_set(x_17, 2, x_1);
lean::cnstr_set(x_17, 3, x_15);
x_18 = 0;
x_19 = lean::alloc_cnstr(1, 1, 1);
lean::cnstr_set(x_19, 0, x_17);
lean::cnstr_set_scalar(x_19, sizeof(void*)*1, x_18);
x_20 = x_19;
x_21 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_21, 0, x_20);
lean::cnstr_set(x_21, 1, x_4);
return x_21;
x_13 = lean::box(0);
x_14 = l_String_splitAux___main___closed__1;
x_15 = lean::alloc_cnstr(0, 4, 0);
lean::cnstr_set(x_15, 0, x_3);
lean::cnstr_set(x_15, 1, x_14);
lean::cnstr_set(x_15, 2, x_1);
lean::cnstr_set(x_15, 3, x_13);
x_16 = 0;
x_17 = lean::alloc_cnstr(1, 1, 1);
lean::cnstr_set(x_17, 0, x_15);
lean::cnstr_set_scalar(x_17, sizeof(void*)*1, x_16);
x_18 = x_17;
x_19 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_19, 0, x_18);
lean::cnstr_set(x_19, 1, x_4);
return x_19;
}
else
{
obj* x_24; obj* x_27; obj* x_28; obj* x_29;
obj* x_22; obj* x_25; obj* x_26; obj* x_27;
lean::dec(x_1);
lean::dec(x_3);
x_24 = lean::cnstr_get(x_13, 0);
lean::inc(x_24);
lean::dec(x_13);
x_27 = lean::box(0);
x_28 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_28, 0, x_0);
lean::cnstr_set(x_28, 1, x_24);
lean::cnstr_set(x_28, 2, x_27);
x_29 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_29, 0, x_28);
lean::cnstr_set(x_29, 1, x_4);
return x_29;
x_22 = lean::cnstr_get(x_11, 0);
lean::inc(x_22);
lean::dec(x_11);
x_25 = lean::box(0);
x_26 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_26, 0, x_0);
lean::cnstr_set(x_26, 1, x_22);
lean::cnstr_set(x_26, 2, x_25);
x_27 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_27, 0, x_26);
lean::cnstr_set(x_27, 1, x_4);
return x_27;
}
}
else
{
obj* x_32; obj* x_33; obj* x_34; obj* x_35;
obj* x_30; obj* x_31; obj* x_32; obj* x_33;
lean::dec(x_1);
lean::dec(x_0);
x_32 = l_String_splitAux___main___closed__1;
x_33 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
x_34 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_34, 0, x_32);
lean::cnstr_set(x_34, 1, x_3);
lean::cnstr_set(x_34, 2, x_33);
x_35 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_35, 0, x_34);
lean::cnstr_set(x_35, 1, x_4);
return x_35;
x_30 = l_String_splitAux___main___closed__1;
x_31 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
x_32 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_32, 0, x_30);
lean::cnstr_set(x_32, 1, x_3);
lean::cnstr_set(x_32, 2, x_31);
x_33 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_33, 0, x_32);
lean::cnstr_set(x_33, 1, x_4);
return x_33;
}
}
}
@ -9843,73 +9840,71 @@ uint8 x_6;
x_6 = l_String_isEmpty(x_0);
if (x_6 == 0)
{
obj* x_7; obj* x_8; usize x_9; obj* x_11; obj* x_12; obj* x_14;
obj* x_7; obj* x_8; obj* x_10; obj* x_12;
x_7 = lean::string_length(x_0);
x_8 = lean::mk_nat_obj(0ul);
x_9 = l_String_toSubstring___closed__1;
lean::inc(x_0);
x_11 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
lean::cnstr_set(x_11, 0, x_0);
lean::cnstr_set(x_11, 1, x_8);
lean::cnstr_set_scalar(x_11, sizeof(void*)*2, x_9);
x_12 = x_11;
x_10 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_10, 0, x_0);
lean::cnstr_set(x_10, 1, x_8);
lean::cnstr_set(x_10, 2, x_8);
lean::inc(x_4);
x_14 = l___private_init_lean_parser_parsec_2__strAux___main(x_7, x_12, x_4);
if (lean::obj_tag(x_14) == 0)
x_12 = l___private_init_lean_parser_parsec_2__strAux___main(x_7, x_10, x_4);
if (lean::obj_tag(x_12) == 0)
{
obj* x_16; obj* x_17; obj* x_18; uint8 x_19; obj* x_20; obj* x_21; obj* x_22;
obj* x_14; obj* x_15; obj* x_16; uint8 x_17; obj* x_18; obj* x_19; obj* x_20;
lean::dec(x_0);
x_16 = lean::box(0);
x_17 = l_String_splitAux___main___closed__1;
x_18 = lean::alloc_cnstr(0, 4, 0);
lean::cnstr_set(x_18, 0, x_4);
lean::cnstr_set(x_18, 1, x_17);
lean::cnstr_set(x_18, 2, x_1);
lean::cnstr_set(x_18, 3, x_16);
x_19 = 0;
x_20 = lean::alloc_cnstr(1, 1, 1);
lean::cnstr_set(x_20, 0, x_18);
lean::cnstr_set_scalar(x_20, sizeof(void*)*1, x_19);
x_21 = x_20;
x_22 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_22, 0, x_21);
lean::cnstr_set(x_22, 1, x_5);
return x_22;
x_14 = lean::box(0);
x_15 = l_String_splitAux___main___closed__1;
x_16 = lean::alloc_cnstr(0, 4, 0);
lean::cnstr_set(x_16, 0, x_4);
lean::cnstr_set(x_16, 1, x_15);
lean::cnstr_set(x_16, 2, x_1);
lean::cnstr_set(x_16, 3, x_14);
x_17 = 0;
x_18 = lean::alloc_cnstr(1, 1, 1);
lean::cnstr_set(x_18, 0, x_16);
lean::cnstr_set_scalar(x_18, sizeof(void*)*1, x_17);
x_19 = x_18;
x_20 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_20, 0, x_19);
lean::cnstr_set(x_20, 1, x_5);
return x_20;
}
else
{
obj* x_25; obj* x_28; obj* x_29; obj* x_30;
obj* x_23; obj* x_26; obj* x_27; obj* x_28;
lean::dec(x_4);
lean::dec(x_1);
x_25 = lean::cnstr_get(x_14, 0);
lean::inc(x_25);
lean::dec(x_14);
x_28 = lean::box(0);
x_29 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_29, 0, x_0);
lean::cnstr_set(x_29, 1, x_25);
lean::cnstr_set(x_29, 2, x_28);
x_30 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_30, 0, x_29);
lean::cnstr_set(x_30, 1, x_5);
return x_30;
x_23 = lean::cnstr_get(x_12, 0);
lean::inc(x_23);
lean::dec(x_12);
x_26 = lean::box(0);
x_27 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_27, 0, x_0);
lean::cnstr_set(x_27, 1, x_23);
lean::cnstr_set(x_27, 2, x_26);
x_28 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_28, 0, x_27);
lean::cnstr_set(x_28, 1, x_5);
return x_28;
}
}
else
{
obj* x_33; obj* x_34; obj* x_35; obj* x_36;
obj* x_31; obj* x_32; obj* x_33; obj* x_34;
lean::dec(x_1);
lean::dec(x_0);
x_33 = l_String_splitAux___main___closed__1;
x_34 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
x_35 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_35, 0, x_33);
lean::cnstr_set(x_35, 1, x_4);
lean::cnstr_set(x_35, 2, x_34);
x_36 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_36, 0, x_35);
lean::cnstr_set(x_36, 1, x_5);
return x_36;
x_31 = l_String_splitAux___main___closed__1;
x_32 = l_Lean_Parser_Parsec_Result_mkEps___rarg___closed__1;
x_33 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_33, 0, x_31);
lean::cnstr_set(x_33, 1, x_4);
lean::cnstr_set(x_33, 2, x_32);
x_34 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_34, 0, x_33);
lean::cnstr_set(x_34, 1, x_5);
return x_34;
}
}
}
@ -23062,19 +23057,17 @@ return x_4;
obj* l___private_init_lean_parser_token_8__toNatBase(obj* x_0, obj* x_1) {
_start:
{
obj* x_2; usize x_3; obj* x_5; obj* x_6; obj* x_7; obj* x_9;
obj* x_2; obj* x_4; obj* x_5; obj* x_7;
x_2 = lean::mk_nat_obj(0ul);
x_3 = l_String_toSubstring___closed__1;
lean::inc(x_0);
x_5 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
lean::cnstr_set(x_5, 0, x_0);
lean::cnstr_set(x_5, 1, x_2);
lean::cnstr_set_scalar(x_5, sizeof(void*)*2, x_3);
x_6 = x_5;
x_7 = lean::string_length(x_0);
x_4 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_4, 0, x_0);
lean::cnstr_set(x_4, 1, x_2);
lean::cnstr_set(x_4, 2, x_2);
x_5 = lean::string_length(x_0);
lean::dec(x_0);
x_9 = l___private_init_lean_parser_token_7__toNatCore___main(x_1, x_6, x_7, x_2);
return x_9;
x_7 = l___private_init_lean_parser_token_7__toNatCore___main(x_1, x_4, x_5, x_2);
return x_7;
}
}
obj* l___private_init_lean_parser_token_8__toNatBase___boxed(obj* x_0, obj* x_1) {

View file

@ -27,7 +27,6 @@ obj* nat_sub(obj*, obj*);
obj* l_Lean_Format_pretty(obj*, obj*);
obj* l_Lean_Parser_Trie_insert___boxed(obj*);
obj* l_Lean_Parser_Trie_mk___closed__1;
extern usize l_String_toSubstring___closed__1;
obj* l_Lean_Format_group___main(obj*);
obj* l___private_init_lean_parser_trie_4__toStringAux___main___rarg(obj*);
obj* l_RBNode_ins___main___at___private_init_lean_parser_trie_1__insertAux___main___spec__3(obj*);
@ -913,16 +912,15 @@ return x_1;
obj* l_Lean_Parser_Trie_insert___rarg(obj* x_0, obj* x_1, obj* x_2) {
_start:
{
obj* x_3; usize x_4; obj* x_5; obj* x_6; obj* x_7;
obj* x_3; obj* x_4; obj* x_5; obj* x_6;
x_3 = lean::string_length(x_1);
x_4 = l_String_toSubstring___closed__1;
x_5 = lean::alloc_cnstr(0, 1, sizeof(size_t)*1);
x_4 = lean::mk_nat_obj(0ul);
x_5 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_5, 0, x_1);
lean::cnstr_set_scalar(x_5, sizeof(void*)*1, x_4);
x_6 = x_5;
x_7 = l___private_init_lean_parser_trie_1__insertAux___main___rarg(x_2, x_3, x_0, x_6);
lean::cnstr_set(x_5, 1, x_4);
x_6 = l___private_init_lean_parser_trie_1__insertAux___main___rarg(x_2, x_3, x_0, x_5);
lean::dec(x_3);
return x_7;
return x_6;
}
}
obj* l_Lean_Parser_Trie_insert(obj* x_0) {
@ -1037,15 +1035,14 @@ return x_1;
obj* l_Lean_Parser_Trie_find___rarg(obj* x_0, obj* x_1) {
_start:
{
obj* x_2; usize x_3; obj* x_4; obj* x_5; obj* x_6;
obj* x_2; obj* x_3; obj* x_4; obj* x_5;
x_2 = lean::string_length(x_1);
x_3 = l_String_toSubstring___closed__1;
x_4 = lean::alloc_cnstr(0, 1, sizeof(size_t)*1);
x_3 = lean::mk_nat_obj(0ul);
x_4 = lean::alloc_cnstr(0, 2, 0);
lean::cnstr_set(x_4, 0, x_1);
lean::cnstr_set_scalar(x_4, sizeof(void*)*1, x_3);
x_5 = x_4;
x_6 = l___private_init_lean_parser_trie_2__findAux___main___rarg(x_2, x_0, x_5);
return x_6;
lean::cnstr_set(x_4, 1, x_3);
x_5 = l___private_init_lean_parser_trie_2__findAux___main___rarg(x_2, x_0, x_4);
return x_5;
}
}
obj* l_Lean_Parser_Trie_find(obj* x_0) {

View file

@ -20,7 +20,6 @@ namespace lean {
obj* nat_sub(obj*, obj*);
}
obj* l_Lean_Position_DecidableEq___boxed(obj*, obj*);
extern usize l_String_toSubstring___closed__1;
uint32 l_String_OldIterator_curr___main(obj*);
obj* l___private_init_lean_position_1__fromStringAux___main___boxed(obj*, obj*, obj*);
obj* l_Lean_Position_decidableLt___boxed(obj*, obj*);
@ -665,19 +664,17 @@ return x_13;
obj* l_Lean_FileMap_fromString(obj* x_0) {
_start:
{
obj* x_1; obj* x_2; usize x_3; obj* x_4; obj* x_5; obj* x_6; obj* x_7; obj* x_8;
obj* x_1; obj* x_2; obj* x_3; obj* x_4; obj* x_5; obj* x_6;
x_1 = lean::string_length(x_0);
x_2 = lean::mk_nat_obj(0ul);
x_3 = l_String_toSubstring___closed__1;
x_4 = lean::alloc_cnstr(0, 2, sizeof(size_t)*1);
lean::cnstr_set(x_4, 0, x_0);
lean::cnstr_set(x_4, 1, x_2);
lean::cnstr_set_scalar(x_4, sizeof(void*)*2, x_3);
x_5 = x_4;
x_6 = lean::mk_nat_obj(1ul);
x_7 = l___private_init_lean_position_1__fromStringAux___main(x_1, x_5, x_6);
x_8 = l_RBMap_ofList___main___at_Lean_FileMap_fromString___spec__1(x_7);
return x_8;
x_3 = lean::alloc_cnstr(0, 3, 0);
lean::cnstr_set(x_3, 0, x_0);
lean::cnstr_set(x_3, 1, x_2);
lean::cnstr_set(x_3, 2, x_2);
x_4 = lean::mk_nat_obj(1ul);
x_5 = l___private_init_lean_position_1__fromStringAux___main(x_1, x_3, x_4);
x_6 = l_RBMap_ofList___main___at_Lean_FileMap_fromString___spec__1(x_5);
return x_6;
}
}
obj* l_RBNode_lowerBound___main___at_Lean_FileMap_toPosition___spec__2(obj* x_0, obj* x_1, obj* x_2) {