From dd6d275c5c951e61e8d66e02a946500af789ec2f Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Tue, 25 Jul 2023 14:45:31 -0400 Subject: [PATCH 01/28] Always parse \xHH as U+00HH, then decode when needed for Bytes domain values --- include/kllvm/ast/AST.h | 10 +++ lib/ast/AST.cpp | 22 +++++++ lib/codegen/CreateStaticTerm.cpp | 6 ++ lib/codegen/EmitConfigParser.cpp | 106 +++++++++++++++++++------------ lib/parser/KOREScanner.l | 2 +- 5 files changed, 103 insertions(+), 43 deletions(-) diff --git a/include/kllvm/ast/AST.h b/include/kllvm/ast/AST.h index 55869ace0..facceeb5f 100644 --- a/include/kllvm/ast/AST.h +++ b/include/kllvm/ast/AST.h @@ -646,6 +646,16 @@ class KOREStringPattern : public KOREPattern { : contents(Contents) { } }; +// A Bytes domain value is represented as a KOREStringPattern by storing each +// byte 0xHH as the (UTF-8 encoded) Unicode codepoint U+00HH. +// +// Given the contents of such a KOREStringPattern, this function produces the +// actual char[] for the Bytes domain value. In effect, this is just a conversion +// from UTF-8 to latin-1. +// +// The input buffer is overwritten, and the new length is returned. +size_t bytesStringPatternToBytes(char *contents, size_t length); + // KOREDeclaration class KOREDeclaration { protected: diff --git a/lib/ast/AST.cpp b/lib/ast/AST.cpp index addf8f37c..a933a0a78 100644 --- a/lib/ast/AST.cpp +++ b/lib/ast/AST.cpp @@ -1881,6 +1881,28 @@ void KOREStringPattern::print(std::ostream &Out, unsigned indent) const { Out << Indent << "\"" << escapeString(contents) << "\""; } +size_t bytesStringPatternToBytes(char *contents, size_t length) { + char *contentsIter = contents; + char *contentsEnd = contents + length; + size_t newLength = 0; + for (; contentsIter != contentsEnd; ++contentsIter, ++newLength) { + char byte1 = *contentsIter; + char codepoint; + if ((byte1 & 0x80) == 0) { + // 0xxxxxxx + codepoint = byte1; + } else if ((byte1 & 0xE0) == 0xC0) { + // 110xxxxx 10xxxxxx + char byte2 = *(++contentsIter); + codepoint = ((byte1 & ~0xE0) << 6) | (byte2 & 0x3F); + } else { + assert(0 && "Contents are not a UTF-8 encoding of a Bytes domain value"); + } + contents[newLength] = codepoint; + } + return newLength; +} + static void printAttributeList( std::ostream &Out, const std::unordered_map> diff --git a/lib/codegen/CreateStaticTerm.cpp b/lib/codegen/CreateStaticTerm.cpp index 4f824df97..9a477d6ed 100644 --- a/lib/codegen/CreateStaticTerm.cpp +++ b/lib/codegen/CreateStaticTerm.cpp @@ -1,5 +1,6 @@ #include "kllvm/codegen/CreateStaticTerm.h" +#include "kllvm/ast/AST.h" #include "kllvm/codegen/CreateTerm.h" #include "kllvm/codegen/Util.h" @@ -294,6 +295,11 @@ CreateStaticTerm::createToken(ValueType sort, std::string contents) { llvm::Type::getInt1Ty(Ctx), contents == "true"); case SortCategory::Variable: case SortCategory::Symbol: { + if (Definition->getHookedSorts().count(sort) && + Definition->getHookedSorts().at(sort)->getHook(Definition) == "BYTES.Bytes") { + size_t newSize = bytesStringPatternToBytes(contents.data(), contents.size()); + contents.resize(newSize); + } llvm::StructType *StringType = llvm::StructType::get( Ctx, {getTypeByName(Module, BLOCKHEADER_STRUCT), diff --git a/lib/codegen/EmitConfigParser.cpp b/lib/codegen/EmitConfigParser.cpp index 2c2ccbacf..3055f4e48 100644 --- a/lib/codegen/EmitConfigParser.cpp +++ b/lib/codegen/EmitConfigParser.cpp @@ -474,6 +474,50 @@ emitGetTagForFreshSort(KOREDefinition *definition, llvm::Module *module) { } } +static llvm::Value *makeStringToken(llvm::Value *Str, llvm::Value *StrLength, + llvm::BasicBlock *InsertAtEnd) { + auto Module = InsertAtEnd->getModule(); + llvm::LLVMContext &Ctx = Module->getContext(); + auto StringType = getTypeByName(Module, STRING_STRUCT); + auto Len = llvm::BinaryOperator::Create( + llvm::Instruction::Add, StrLength, + llvm::ConstantExpr::getSizeOf(StringType), "", InsertAtEnd); + llvm::Value *Block + = allocateTerm(StringType, Len, InsertAtEnd, "koreAllocToken"); + llvm::Constant *zero = llvm::ConstantInt::get(llvm::Type::getInt64Ty(Ctx), 0); + llvm::Constant *zero32 + = llvm::ConstantInt::get(llvm::Type::getInt32Ty(Ctx), 0); + auto HdrPtr = llvm::GetElementPtrInst::CreateInBounds( + StringType, Block, {zero, zero32, zero32}, "", InsertAtEnd); + auto BlockSize + = Module->getOrInsertGlobal("BLOCK_SIZE", llvm::Type::getInt64Ty(Ctx)); + auto BlockSizeVal = new llvm::LoadInst( + llvm::Type::getInt64Ty(Ctx), BlockSize, "", InsertAtEnd); + auto BlockAllocSize = llvm::BinaryOperator::Create( + llvm::Instruction::Sub, BlockSizeVal, + llvm::ConstantExpr::getSizeOf(llvm::Type::getInt8PtrTy(Ctx)), "", + InsertAtEnd); + auto icmp = new llvm::ICmpInst( + *InsertAtEnd, llvm::CmpInst::ICMP_UGT, Len, BlockAllocSize); + auto Mask = llvm::SelectInst::Create( + icmp, + llvm::ConstantInt::get(llvm::Type::getInt64Ty(Ctx), NOT_YOUNG_OBJECT_BIT), + llvm::ConstantInt::get(llvm::Type::getInt64Ty(Ctx), 0), "", InsertAtEnd); + auto HdrOred = llvm::BinaryOperator::Create( + llvm::Instruction::Or, StrLength, Mask, "", InsertAtEnd); + new llvm::StoreInst(HdrOred, HdrPtr, InsertAtEnd); + llvm::Function *Memcpy = getOrInsertFunction( + Module, "memcpy", llvm::Type::getInt8PtrTy(Ctx), + llvm::Type::getInt8PtrTy(Ctx), llvm::Type::getInt8PtrTy(Ctx), + llvm::Type::getInt64Ty(Ctx)); + auto StrPtr = llvm::GetElementPtrInst::CreateInBounds( + StringType, Block, + {zero, llvm::ConstantInt::get(llvm::Type::getInt32Ty(Ctx), 1), zero}, "", + InsertAtEnd); + llvm::CallInst::Create(Memcpy, {StrPtr, Str, StrLength}, "", InsertAtEnd); + return new llvm::BitCastInst(Block, llvm::Type::getInt8PtrTy(Ctx), "", InsertAtEnd); +} + static void emitGetToken(KOREDefinition *definition, llvm::Module *module) { llvm::LLVMContext &Ctx = module->getContext(); auto getTokenType = llvm::FunctionType::get( @@ -503,9 +547,11 @@ static void emitGetToken(KOREDefinition *definition, llvm::Module *module) { // TODO: MINT in initial configuration continue; } + auto sort = KORECompositeSort::Create(name); ValueType cat = sort->getCategory(definition); - if (cat.cat == SortCategory::Symbol || cat.cat == SortCategory::Variable) { + if ((cat.cat == SortCategory::Symbol && sort->getHook(definition) != "BYTES.Bytes") || + cat.cat == SortCategory::Variable) { continue; } CurrentBlock->insertInto(func); @@ -620,54 +666,30 @@ static void emitGetToken(KOREDefinition *definition, llvm::Module *module) { Phi->addIncoming(cast, CaseBlock); break; } - case SortCategory::Variable: - case SortCategory::Symbol: break; + case SortCategory::Variable: break; + case SortCategory::Symbol: { + llvm::Function *DecodeBytes = + getOrInsertFunction(module, "bytesStringPatternToBytes", + llvm::Type::getInt64Ty(Ctx), + llvm::Type::getInt8PtrTy(Ctx), llvm::Type::getInt64Ty(Ctx)); + llvm::Value *BytesLength = + llvm::CallInst::Create(DecodeBytes, + {func->arg_begin() + 2, func->arg_begin() + 1}, + "", CurrentBlock); + auto result = makeStringToken(func->arg_begin() + 2, BytesLength, CurrentBlock); + Phi->addIncoming(result, CaseBlock); + llvm::BranchInst::Create(MergeBlock, CaseBlock); + break; + } case SortCategory::Uncomputed: abort(); } CurrentBlock = FalseBlock; } CurrentBlock->setName("symbol"); CurrentBlock->insertInto(func); - auto StringType = getTypeByName(module, STRING_STRUCT); - auto Len = llvm::BinaryOperator::Create( - llvm::Instruction::Add, func->arg_begin() + 1, - llvm::ConstantExpr::getSizeOf(StringType), "", CurrentBlock); - llvm::Value *Block - = allocateTerm(StringType, Len, CurrentBlock, "koreAllocToken"); - auto HdrPtr = llvm::GetElementPtrInst::CreateInBounds( - StringType, Block, {zero, zero32, zero32}, "", CurrentBlock); - auto BlockSize - = module->getOrInsertGlobal("BLOCK_SIZE", llvm::Type::getInt64Ty(Ctx)); - auto BlockSizeVal = new llvm::LoadInst( - llvm::Type::getInt64Ty(Ctx), BlockSize, "", CurrentBlock); - auto BlockAllocSize = llvm::BinaryOperator::Create( - llvm::Instruction::Sub, BlockSizeVal, - llvm::ConstantExpr::getSizeOf(llvm::Type::getInt8PtrTy(Ctx)), "", - CurrentBlock); - auto icmp = new llvm::ICmpInst( - *CurrentBlock, llvm::CmpInst::ICMP_UGT, Len, BlockAllocSize); - auto Mask = llvm::SelectInst::Create( - icmp, - llvm::ConstantInt::get(llvm::Type::getInt64Ty(Ctx), NOT_YOUNG_OBJECT_BIT), - llvm::ConstantInt::get(llvm::Type::getInt64Ty(Ctx), 0), "", CurrentBlock); - auto HdrOred = llvm::BinaryOperator::Create( - llvm::Instruction::Or, func->arg_begin() + 1, Mask, "", CurrentBlock); - new llvm::StoreInst(HdrOred, HdrPtr, CurrentBlock); - llvm::Function *Memcpy = getOrInsertFunction( - module, "memcpy", llvm::Type::getInt8PtrTy(Ctx), - llvm::Type::getInt8PtrTy(Ctx), llvm::Type::getInt8PtrTy(Ctx), - llvm::Type::getInt64Ty(Ctx)); - auto StrPtr = llvm::GetElementPtrInst::CreateInBounds( - StringType, Block, - {zero, llvm::ConstantInt::get(llvm::Type::getInt32Ty(Ctx), 1), zero}, "", - CurrentBlock); - llvm::CallInst::Create( - Memcpy, {StrPtr, func->arg_begin() + 2, func->arg_begin() + 1}, "", - CurrentBlock); - auto cast = new llvm::BitCastInst( - Block, llvm::Type::getInt8PtrTy(Ctx), "", CurrentBlock); + auto strToken = makeStringToken(func->arg_begin() + 2, func->arg_begin() + 1, CurrentBlock); llvm::BranchInst::Create(MergeBlock, CurrentBlock); - Phi->addIncoming(cast, CurrentBlock); + Phi->addIncoming(strToken, CurrentBlock); llvm::ReturnInst::Create(Ctx, Phi, MergeBlock); MergeBlock->insertInto(func); } diff --git a/lib/parser/KOREScanner.l b/lib/parser/KOREScanner.l index b75a7c800..96e3ab5e4 100644 --- a/lib/parser/KOREScanner.l +++ b/lib/parser/KOREScanner.l @@ -80,7 +80,7 @@ yyin = in; "\\\"" { stringBuffer.push_back('\"'); } "\\\\" { stringBuffer.push_back('\\'); } \\[0-9]{3} { stringBuffer.push_back((yytext[1] - '0') * 64 + (yytext[2] - '0') * 8 + yytext[3] - '0'); } -\\x[0-9a-fA-F]{2} { stringBuffer.push_back(strtol(yytext+2, NULL, 16)); } +\\x[0-9a-fA-F]{2} { stringBuffer.append(codepoint_to_utf8(strtoul(yytext+2, NULL, 16), *loc)); } \\u[0-9a-fA-F]{4} { stringBuffer.append(codepoint_to_utf8(strtoul(yytext+2, NULL, 16), *loc)); } \\U[0-9a-fA-F]{8} { stringBuffer.append(codepoint_to_utf8(strtoul(yytext+2, NULL, 16), *loc)); } "\"" { From 588d624ee1250cf2d49f295ec477ba8a69ff360b Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Tue, 25 Jul 2023 14:58:45 -0400 Subject: [PATCH 02/28] Fix bytesStringPatternToBytes -> kllvm::bytesStringPatternToBytes --- lib/ast/AST.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ast/AST.cpp b/lib/ast/AST.cpp index a933a0a78..c14631c71 100644 --- a/lib/ast/AST.cpp +++ b/lib/ast/AST.cpp @@ -1881,7 +1881,7 @@ void KOREStringPattern::print(std::ostream &Out, unsigned indent) const { Out << Indent << "\"" << escapeString(contents) << "\""; } -size_t bytesStringPatternToBytes(char *contents, size_t length) { +size_t kllvm::bytesStringPatternToBytes(char *contents, size_t length) { char *contentsIter = contents; char *contentsEnd = contents + length; size_t newLength = 0; From a85c868173f8c159c6b9ed6c187ed95aa2662157 Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Tue, 25 Jul 2023 15:30:28 -0400 Subject: [PATCH 03/28] bytesStringPatternToBytes(): Add dummy assignment to silence uninitialized variable warning --- lib/ast/AST.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/ast/AST.cpp b/lib/ast/AST.cpp index c14631c71..fc5a74660 100644 --- a/lib/ast/AST.cpp +++ b/lib/ast/AST.cpp @@ -1897,6 +1897,7 @@ size_t kllvm::bytesStringPatternToBytes(char *contents, size_t length) { codepoint = ((byte1 & ~0xE0) << 6) | (byte2 & 0x3F); } else { assert(0 && "Contents are not a UTF-8 encoding of a Bytes domain value"); + codepoint = '\0'; } contents[newLength] = codepoint; } From adc4d4b5bfc3399c6379e5d4290d21d0fa118aa6 Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Mon, 31 Jul 2023 11:17:34 -0400 Subject: [PATCH 04/28] Refactor bytesStriingPatternToBytes --- lib/ast/AST.cpp | 59 +++++++++++++++++++++++++++++++++++-------------- 1 file changed, 43 insertions(+), 16 deletions(-) diff --git a/lib/ast/AST.cpp b/lib/ast/AST.cpp index fc5a74660..b1ee57553 100644 --- a/lib/ast/AST.cpp +++ b/lib/ast/AST.cpp @@ -1881,25 +1881,52 @@ void KOREStringPattern::print(std::ostream &Out, unsigned indent) const { Out << Indent << "\"" << escapeString(contents) << "\""; } +struct UTF8EncodingType { + // A mask to extract the leading bits from the first byte + char leadingBitsMask; + // The expected value after applying the leading bits mask + char leadingBitsValue; + // The number of non-leading 10xxxxxx bytes used to encode a codepoint + int numContinuationBytes; +}; + +static const UTF8EncodingType utf8EncodingTypes[4] = { + // 0xxxxxxx + { 0x80, 0x00, 0 }, + // 110xxxxx 10xxxxxx + { 0xE0, 0xC0, 1 }, + // 1110xxxx 10xxxxxx 10xxxxxx + { 0xF0, 0xE0, 2 }, + // 11110xxx 10xxxxxx 10xxxxxx 10xxxxxx + { 0xF8, 0xF0, 3 } +}; + +// Read one codepoint from a UTF-8 encoded string, returning the codepoint +// as well as a pointer to start of the next codepoint +static std::pair readCodepoint(char *utf8Str) { + char leadByte = *utf8Str; + for (auto const &type : utf8EncodingTypes) { + if ((leadByte & type.leadingBitsMask) == type.leadingBitsValue) { + uint32_t codepoint = leadByte & ~type.leadingBitsMask; + for (int i = 0; i < type.numContinuationBytes; ++i) { + char contByte = *(++utf8Str); + codepoint = (codepoint << 6) | (contByte & 0x3F); + } + return { codepoint , ++utf8Str }; + } + } + assert(0 && "Invalid UTF-8 string"); +} size_t kllvm::bytesStringPatternToBytes(char *contents, size_t length) { - char *contentsIter = contents; + char *contentsStart = contents; char *contentsEnd = contents + length; size_t newLength = 0; - for (; contentsIter != contentsEnd; ++contentsIter, ++newLength) { - char byte1 = *contentsIter; - char codepoint; - if ((byte1 & 0x80) == 0) { - // 0xxxxxxx - codepoint = byte1; - } else if ((byte1 & 0xE0) == 0xC0) { - // 110xxxxx 10xxxxxx - char byte2 = *(++contentsIter); - codepoint = ((byte1 & ~0xE0) << 6) | (byte2 & 0x3F); - } else { - assert(0 && "Contents are not a UTF-8 encoding of a Bytes domain value"); - codepoint = '\0'; - } - contents[newLength] = codepoint; + while (contents != contentsEnd) { + auto [codepoint, nextByte] = readCodepoint(contents); + assert(codepoint <= 0xFF && "Bytes string patterns should only contain codepoints up to U+00FF"); + contentsStart[newLength] = static_cast(codepoint); + ++newLength; + contents = nextByte; } return newLength; } From 77c77ee0ec1a6c8e7c5d0b007cdd0fe31d762f67 Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Tue, 15 Aug 2023 15:15:21 -0400 Subject: [PATCH 05/28] Add a bit to the string representation to indicate whether it is a byte string. Update all printers. --- cmake/RuntimeConfig.cmake | 1 + config/macros.h | 1 + debug/kgdb.py | 17 ++- include/kllvm/ast/AST.h | 13 ++ include/runtime/header.h | 19 +++ lib/ast/AST.cpp | 164 ++++++++++++++------------ lib/codegen/CreateStaticTerm.cpp | 28 +++-- lib/codegen/CreateTerm.cpp | 12 +- lib/codegen/EmitConfigParser.cpp | 41 ++++--- runtime/fresh.ll | 2 +- runtime/util/ConfigurationPrinter.cpp | 27 +---- 11 files changed, 190 insertions(+), 135 deletions(-) diff --git a/cmake/RuntimeConfig.cmake b/cmake/RuntimeConfig.cmake index b84a6e4d9..ac83eef71 100644 --- a/cmake/RuntimeConfig.cmake +++ b/cmake/RuntimeConfig.cmake @@ -18,6 +18,7 @@ set(VARIABLE_BIT 0x8000000000000) set(LAYOUT_OFFSET 54) set(TAG_MASK 0xffffffff) set(LENGTH_MASK 0xffffffffff) +set(IS_BYTES_BIT 0x10000000000) if(CMAKE_BUILD_TYPE STREQUAL "GcStats") set(HDR_MASK -18013298997854209) # 0xffc000ffffffffff diff --git a/config/macros.h b/config/macros.h index 6368b73a5..455d284e9 100644 --- a/config/macros.h +++ b/config/macros.h @@ -11,6 +11,7 @@ #define HDR_MASK @HDR_MASK@ #define TAG_MASK @TAG_MASK@LL #define LENGTH_MASK @LENGTH_MASK@ +#define IS_BYTES_BIT @IS_BYTES_BIT@ #define MAP_LAYOUT @MAP_LAYOUT@ #define LIST_LAYOUT @LIST_LAYOUT@ diff --git a/debug/kgdb.py b/debug/kgdb.py index ba1c50de5..447aed00c 100644 --- a/debug/kgdb.py +++ b/debug/kgdb.py @@ -561,9 +561,14 @@ def append(self, subject, isVar, sort): if not layout: string = subject.cast(self.string_ptr) length = hdr & @LENGTH_MASK@ + string_bytes = bytes(int(string.dereference()['data'][i].cast(self.unsigned_char)) for i in range(length)) + if hdr & @IS_BYTES_BIT@: + py_str = string_bytes.decode('iso-8859-1') + else: + py_str = string_bytes.decode('utf-8') + self.result += "\\dv{" + sort + "}(\"" - for i in range(length): - c = chr(int(string.dereference()['data'][i].cast(self.unsigned_char))) + for c in py_str: if c == '\\': self.result += "\\\\" elif c == '"': @@ -576,10 +581,14 @@ def append(self, subject, isVar, sort): self.result += "\\r" elif c == '\f': self.result += "\\f" - elif ord(c) >= 32 and ord(c) < 127: + elif 32 <= ord(c) and ord(c) < 127: self.result += c + elif ord(c) <= 0xFF: + self.result += "\\x{:02x}".format(ord(c)) + elif ord(c) <= 0xFFFF: + self.result += "\\u{:04x}".format(ord(c)) else: - self.result += "{:02x}".format(ord(c)) + self.result += "\\U{:08x}".format(ord(c)) var = Variable(string) stdStr = var.stdStr if isVar and not var in self.var_names: diff --git a/include/kllvm/ast/AST.h b/include/kllvm/ast/AST.h index 6328ff8c7..65afb67da 100644 --- a/include/kllvm/ast/AST.h +++ b/include/kllvm/ast/AST.h @@ -646,6 +646,19 @@ class KOREStringPattern : public KOREPattern { : contents(Contents) { } }; +// Return a representation of str with all special characters replaced by their +// escape sequences. +// +// The provided StringType indicates whether to treat the string as a sequence of bytes +// or as a UTF-8 encoded Unicode string. +// +// For example, U+1F601 (😁) is UTF-8 encoded as the byte sequence 0xF0 0x9F 0x98 0x81, so +// - escapeString("😁", StringType::UTF8) returns "\U0001f601" +// - escapeString("😁", StringType::BYTES) returns "\xf0\x9f\x98\x81" +// +enum class StringType { BYTES, UTF8 }; +std::string escapeString(const std::string &str, StringType strType); + // A Bytes domain value is represented as a KOREStringPattern by storing each // byte 0xHH as the (UTF-8 encoded) Unicode codepoint U+00HH. // diff --git a/include/runtime/header.h b/include/runtime/header.h index c93f5039e..c1d7c24f6 100644 --- a/include/runtime/header.h +++ b/include/runtime/header.h @@ -110,6 +110,25 @@ bool hash_enter(void); void hash_exit(void); } +__attribute__((always_inline)) constexpr bool is_bytes_hdr(uint64_t hdr) { + return hdr & IS_BYTES_BIT; +} + +template +__attribute__((always_inline)) constexpr bool is_bytes(T const *s) { + return is_bytes_hdr(s->h.hdr); +} + +template +__attribute__((always_inline)) constexpr void +set_is_bytes(T *s, bool is_bytes) { + if (is_bytes) { + s->h.hdr |= IS_BYTES_BIT; + } else { + s->h.hdr &= !IS_BYTES_BIT; + } +} + __attribute__((always_inline)) constexpr uint64_t len_hdr(uint64_t hdr) { return hdr & LENGTH_MASK; } diff --git a/lib/ast/AST.cpp b/lib/ast/AST.cpp index 282f7a43d..cbce3011c 100644 --- a/lib/ast/AST.cpp +++ b/lib/ast/AST.cpp @@ -8,6 +8,7 @@ #include #include #include +#include #include #include #include @@ -645,32 +646,90 @@ color(std::ostream &out, std::string color, PrettyPrintData const &data) { #define RESET_COLOR "\x1b[0m" -std::string enquote(std::string str) { +struct UTF8EncodingType { + // A mask to extract the leading bits from the first byte + char leadingBitsMask; + // The expected value after applying the leading bits mask + char leadingBitsValue; + // The number of non-leading 10xxxxxx bytes used to encode a codepoint + int numContinuationBytes; +}; + +static const UTF8EncodingType utf8EncodingTypes[4] = { + // 0xxxxxxx + {static_cast(0x80), static_cast(0x00), 0}, + // 110xxxxx 10xxxxxx + {static_cast(0xE0), static_cast(0xC0), 1}, + // 1110xxxx 10xxxxxx 10xxxxxx + {static_cast(0xF0), static_cast(0xE0), 2}, + // 11110xxx 10xxxxxx 10xxxxxx 10xxxxxx + {static_cast(0xF8), static_cast(0xF0), 3}}; + +// Read one codepoint from a UTF-8 encoded string, returning the codepoint +// along with the number of bytes it took to encode +static std::pair readCodepoint(const char *utf8Str) { + char leadByte = *utf8Str; + for (auto const &type : utf8EncodingTypes) { + if ((leadByte & type.leadingBitsMask) == type.leadingBitsValue) { + uint32_t codepoint = leadByte & ~type.leadingBitsMask; + for (int i = 0; i < type.numContinuationBytes; ++i) { + char contByte = *(++utf8Str); + codepoint = (codepoint << 6) | (contByte & 0x3F); + } + return {codepoint, 1 + type.numContinuationBytes}; + } + } + assert(false && "Invalid UTF-8 string"); +} + +std::string +kllvm::escapeString(const std::string &str, kllvm::StringType strType) { std::string result; - result.push_back('"'); - for (size_t i = 0; i < str.length(); ++i) { - char c = str[i]; - switch (c) { - case '\\': result.append("\\\\"); break; - case '"': result.append("\\\""); break; - case '\n': result.append("\\n"); break; - case '\t': result.append("\\t"); break; - case '\r': result.append("\\r"); break; - case '\f': result.append("\\f"); break; + const char *strIter = str.data(); + const char *strEnd = strIter + str.length(); + while (strIter != strEnd) { + uint64_t codepoint; + if (strType == kllvm::StringType::BYTES) { + codepoint = static_cast(*strIter); + ++strIter; + } else { + assert(strType == kllvm::StringType::UTF8); + int numBytes; + std::tie(codepoint, numBytes) = readCodepoint(strIter); + strIter += numBytes; + } + switch (codepoint) { + case 0x5C: result.append("\\\\"); break; + case 0x22: result.append("\\\""); break; + case 0x0A: result.append("\\n"); break; + case 0x09: result.append("\\t"); break; + case 0x0D: result.append("\\r"); break; + case 0x0C: result.append("\\f"); break; default: - if ((unsigned char)c >= 32 && (unsigned char)c < 127) { - result.push_back(c); - } else { + if (32 <= codepoint && codepoint < 127) { + result.push_back(static_cast(codepoint)); + } else if (codepoint <= 0xFF) { char buf[3]; buf[2] = 0; - snprintf(buf, 3, "%02x", (unsigned char)c); + snprintf(buf, 3, "%02" PRIx64, codepoint); result.append("\\x"); result.append(buf); + } else if (codepoint <= 0xFFFF) { + char buf[5]; + buf[4] = 0; + snprintf(buf, 3, "%04" PRIx64, codepoint); + result.append("\\u"); + result.append(buf); + } else { + char buf[9]; + buf[8] = 0; + snprintf(buf, 3, "%08" PRIx64, codepoint); + result.append("\\U"); + result.append(buf); } break; } } - result.push_back('"'); return result; } @@ -710,10 +769,13 @@ void KORECompositePattern::prettyPrint( if (hasHook) { auto hook = data.hook.at(s->getName()); if (hook == "STRING.String") { - append(out, enquote(str->getContents())); + append(out, '"'); + append(out, escapeString(str->getContents(), StringType::UTF8)); + append(out, '"'); } else if (hook == "BYTES.Bytes") { - append(out, 'b'); - append(out, enquote(str->getContents())); + append(out, "b\""); + append(out, escapeString(str->getContents(), StringType::UTF8)); + append(out, '"'); } else { append(out, str->getContents()); } @@ -1859,74 +1921,24 @@ void KORECompositePattern::print(std::ostream &Out, unsigned indent) const { Out << ")"; } -static std::string escapeString(const std::string &str) { - std::string result; - for (char c : str) { - if (c == '"' || c == '\\' || !isprint(c)) { - result.push_back('\\'); - result.push_back('x'); - char code[3]; - snprintf(code, 3, "%02x", (unsigned char)c); - result.push_back(code[0]); - result.push_back(code[1]); - } else { - result.push_back(c); - } - } - return result; -} - void KOREStringPattern::print(std::ostream &Out, unsigned indent) const { std::string Indent(indent, ' '); - Out << Indent << "\"" << escapeString(contents) << "\""; + Out << Indent << "\"" << escapeString(contents, StringType::UTF8) << "\""; } -struct UTF8EncodingType { - // A mask to extract the leading bits from the first byte - char leadingBitsMask; - // The expected value after applying the leading bits mask - char leadingBitsValue; - // The number of non-leading 10xxxxxx bytes used to encode a codepoint - int numContinuationBytes; -}; - -static const UTF8EncodingType utf8EncodingTypes[4] = { - // 0xxxxxxx - { 0x80, 0x00, 0 }, - // 110xxxxx 10xxxxxx - { 0xE0, 0xC0, 1 }, - // 1110xxxx 10xxxxxx 10xxxxxx - { 0xF0, 0xE0, 2 }, - // 11110xxx 10xxxxxx 10xxxxxx 10xxxxxx - { 0xF8, 0xF0, 3 } -}; - -// Read one codepoint from a UTF-8 encoded string, returning the codepoint -// as well as a pointer to start of the next codepoint -static std::pair readCodepoint(char *utf8Str) { - char leadByte = *utf8Str; - for (auto const &type : utf8EncodingTypes) { - if ((leadByte & type.leadingBitsMask) == type.leadingBitsValue) { - uint32_t codepoint = leadByte & ~type.leadingBitsMask; - for (int i = 0; i < type.numContinuationBytes; ++i) { - char contByte = *(++utf8Str); - codepoint = (codepoint << 6) | (contByte & 0x3F); - } - return { codepoint , ++utf8Str }; - } - } - assert(0 && "Invalid UTF-8 string"); -} size_t kllvm::bytesStringPatternToBytes(char *contents, size_t length) { char *contentsStart = contents; char *contentsEnd = contents + length; size_t newLength = 0; while (contents != contentsEnd) { - auto [codepoint, nextByte] = readCodepoint(contents); - assert(codepoint <= 0xFF && "Bytes string patterns should only contain codepoints up to U+00FF"); + auto [codepoint, numBytes] = readCodepoint(contents); + assert( + codepoint <= 0xFF + && "A StringPattern representing Bytes should only contain codepoints " + "up to U+00FF"); contentsStart[newLength] = static_cast(codepoint); ++newLength; - contents = nextByte; + contents += numBytes; } return newLength; } diff --git a/lib/codegen/CreateStaticTerm.cpp b/lib/codegen/CreateStaticTerm.cpp index 9a477d6ed..78b1ff2b8 100644 --- a/lib/codegen/CreateStaticTerm.cpp +++ b/lib/codegen/CreateStaticTerm.cpp @@ -17,6 +17,7 @@ #include #include #include +#include #include #include #include @@ -28,7 +29,15 @@ namespace kllvm { -extern std::string escape(std::string str); +static std::string stringToHex(const std::string &str) { + std::stringstream os; + os << std::setfill('0') << std::setw(2) << std::hex; + for (char c : str) { + unsigned char uc = c; + os << (int)uc; + } + return os.str(); +} /* create a term, given the assumption that the created term will not be a * triangle injection pair */ @@ -295,17 +304,21 @@ CreateStaticTerm::createToken(ValueType sort, std::string contents) { llvm::Type::getInt1Ty(Ctx), contents == "true"); case SortCategory::Variable: case SortCategory::Symbol: { - if (Definition->getHookedSorts().count(sort) && - Definition->getHookedSorts().at(sort)->getHook(Definition) == "BYTES.Bytes") { - size_t newSize = bytesStringPatternToBytes(contents.data(), contents.size()); + bool isBytes = Definition->getHookedSorts().count(sort) + && Definition->getHookedSorts().at(sort)->getHook(Definition) + == "BYTES.Bytes"; + if (isBytes) { + size_t newSize + = bytesStringPatternToBytes(contents.data(), contents.size()); contents.resize(newSize); } llvm::StructType *StringType = llvm::StructType::get( Ctx, {getTypeByName(Module, BLOCKHEADER_STRUCT), llvm::ArrayType::get(llvm::Type::getInt8Ty(Ctx), contents.size())}); - llvm::Constant *global - = Module->getOrInsertGlobal("token_" + escape(contents), StringType); + std::string globalName = std::string("token_") + (isBytes ? "bytes_" : "") + + stringToHex(contents); + llvm::Constant *global = Module->getOrInsertGlobal(globalName, StringType); llvm::GlobalVariable *globalVar = llvm::dyn_cast(global); if (!globalVar->hasInitializer()) { @@ -316,7 +329,8 @@ CreateStaticTerm::createToken(ValueType sort, std::string contents) { llvm::Constant *BlockHeader = llvm::ConstantStruct::get( BlockHeaderType, llvm::ConstantInt::get( llvm::Type::getInt64Ty(Ctx), - contents.size() | NOT_YOUNG_OBJECT_BIT)); + contents.size() | NOT_YOUNG_OBJECT_BIT + | (isBytes ? IS_BYTES_BIT : 0))); globalVar->setInitializer(llvm::ConstantStruct::get( StringType, BlockHeader, llvm::ConstantDataArray::getString(Ctx, contents, false))); diff --git a/lib/codegen/CreateTerm.cpp b/lib/codegen/CreateTerm.cpp index 4cdc1db24..e60fbd65c 100644 --- a/lib/codegen/CreateTerm.cpp +++ b/lib/codegen/CreateTerm.cpp @@ -62,7 +62,7 @@ target triple = "@BACKEND_TARGET_TRIPLE@" ; We also define the following LLVM structure types: -%string = type { %blockheader, [0 x i8] } ; 10-bit layout, 4-bit gc flags, 10 unused bits, 40-bit length (or buffer capacity for string pointed by stringbuffers), bytes +%string = type { %blockheader, [0 x i8] } ; 10-bit layout, 4-bit gc flags, 9 unused bits, 1 bit to mark byte strings, 40-bit length (or buffer capacity for string pointed by stringbuffers), bytes %stringbuffer = type { i64, i64, %string* } ; 10-bit layout, 4-bit gc flags, 10 unused bits, 40-bit length, string length, current contents %map = type { { i8 *, i64 } } ; immer::map %rangemap = type { { { { { i32 (...)**, i32, i64 }*, { { i32 (...)**, i32, i32 }* } } } } } ; rng_map::RangeMap @@ -282,16 +282,6 @@ sptr termSort(KOREPattern *pattern) { } } -std::string escape(std::string str) { - std::stringstream os; - os << std::setfill('0') << std::setw(2) << std::hex; - for (char c : str) { - unsigned char uc = c; - os << (int)uc; - } - return os.str(); -} - llvm::Value *CreateTerm::createHook( KORECompositePattern *hookAtt, KORECompositePattern *pattern) { assert(hookAtt->getArguments().size() == 1); diff --git a/lib/codegen/EmitConfigParser.cpp b/lib/codegen/EmitConfigParser.cpp index 3055f4e48..bf9dd9352 100644 --- a/lib/codegen/EmitConfigParser.cpp +++ b/lib/codegen/EmitConfigParser.cpp @@ -474,8 +474,9 @@ emitGetTagForFreshSort(KOREDefinition *definition, llvm::Module *module) { } } -static llvm::Value *makeStringToken(llvm::Value *Str, llvm::Value *StrLength, - llvm::BasicBlock *InsertAtEnd) { +static llvm::Value *makeStringToken( + llvm::Value *Str, llvm::Value *StrLength, kllvm::StringType strType, + llvm::BasicBlock *InsertAtEnd) { auto Module = InsertAtEnd->getModule(); llvm::LLVMContext &Ctx = Module->getContext(); auto StringType = getTypeByName(Module, STRING_STRUCT); @@ -505,6 +506,12 @@ static llvm::Value *makeStringToken(llvm::Value *Str, llvm::Value *StrLength, llvm::ConstantInt::get(llvm::Type::getInt64Ty(Ctx), 0), "", InsertAtEnd); auto HdrOred = llvm::BinaryOperator::Create( llvm::Instruction::Or, StrLength, Mask, "", InsertAtEnd); + if (strType == kllvm::StringType::BYTES) { + HdrOred = llvm::BinaryOperator::Create( + llvm::Instruction::Or, HdrOred, + llvm::ConstantInt::get(llvm::Type::getInt64Ty(Ctx), IS_BYTES_BIT), "", + InsertAtEnd); + } new llvm::StoreInst(HdrOred, HdrPtr, InsertAtEnd); llvm::Function *Memcpy = getOrInsertFunction( Module, "memcpy", llvm::Type::getInt8PtrTy(Ctx), @@ -515,7 +522,8 @@ static llvm::Value *makeStringToken(llvm::Value *Str, llvm::Value *StrLength, {zero, llvm::ConstantInt::get(llvm::Type::getInt32Ty(Ctx), 1), zero}, "", InsertAtEnd); llvm::CallInst::Create(Memcpy, {StrPtr, Str, StrLength}, "", InsertAtEnd); - return new llvm::BitCastInst(Block, llvm::Type::getInt8PtrTy(Ctx), "", InsertAtEnd); + return new llvm::BitCastInst( + Block, llvm::Type::getInt8PtrTy(Ctx), "", InsertAtEnd); } static void emitGetToken(KOREDefinition *definition, llvm::Module *module) { @@ -550,8 +558,9 @@ static void emitGetToken(KOREDefinition *definition, llvm::Module *module) { auto sort = KORECompositeSort::Create(name); ValueType cat = sort->getCategory(definition); - if ((cat.cat == SortCategory::Symbol && sort->getHook(definition) != "BYTES.Bytes") || - cat.cat == SortCategory::Variable) { + if ((cat.cat == SortCategory::Symbol + && sort->getHook(definition) != "BYTES.Bytes") + || cat.cat == SortCategory::Variable) { continue; } CurrentBlock->insertInto(func); @@ -668,15 +677,15 @@ static void emitGetToken(KOREDefinition *definition, llvm::Module *module) { } case SortCategory::Variable: break; case SortCategory::Symbol: { - llvm::Function *DecodeBytes = - getOrInsertFunction(module, "bytesStringPatternToBytes", - llvm::Type::getInt64Ty(Ctx), - llvm::Type::getInt8PtrTy(Ctx), llvm::Type::getInt64Ty(Ctx)); - llvm::Value *BytesLength = - llvm::CallInst::Create(DecodeBytes, - {func->arg_begin() + 2, func->arg_begin() + 1}, - "", CurrentBlock); - auto result = makeStringToken(func->arg_begin() + 2, BytesLength, CurrentBlock); + llvm::Function *DecodeBytes = getOrInsertFunction( + module, "bytesStringPatternToBytes", llvm::Type::getInt64Ty(Ctx), + llvm::Type::getInt8PtrTy(Ctx), llvm::Type::getInt64Ty(Ctx)); + llvm::Value *BytesLength = llvm::CallInst::Create( + DecodeBytes, {func->arg_begin() + 2, func->arg_begin() + 1}, "", + CurrentBlock); + auto result = makeStringToken( + func->arg_begin() + 2, BytesLength, kllvm::StringType::BYTES, + CurrentBlock); Phi->addIncoming(result, CaseBlock); llvm::BranchInst::Create(MergeBlock, CaseBlock); break; @@ -687,7 +696,9 @@ static void emitGetToken(KOREDefinition *definition, llvm::Module *module) { } CurrentBlock->setName("symbol"); CurrentBlock->insertInto(func); - auto strToken = makeStringToken(func->arg_begin() + 2, func->arg_begin() + 1, CurrentBlock); + auto strToken = makeStringToken( + func->arg_begin() + 2, func->arg_begin() + 1, kllvm::StringType::UTF8, + CurrentBlock); llvm::BranchInst::Create(MergeBlock, CurrentBlock); Phi->addIncoming(strToken, CurrentBlock); llvm::ReturnInst::Create(Ctx, Phi, MergeBlock); diff --git a/runtime/fresh.ll b/runtime/fresh.ll index 099e14700..24cc2d8ca 100644 --- a/runtime/fresh.ll +++ b/runtime/fresh.ll @@ -1,7 +1,7 @@ target datalayout = "@BACKEND_TARGET_DATALAYOUT@" target triple = "@BACKEND_TARGET_TRIPLE@" -%string = type { %blockheader, [0 x i8] } ; 10-bit layout, 4-bit gc flags, 10 unused bits, 40-bit length (or buffer capacity for string pointed by stringbuffers), bytes +%string = type { %blockheader, [0 x i8] } ; 10-bit layout, 4-bit gc flags, 9 unused bits, 1 bit to mark byte strings, 40-bit length (or buffer capacity for string pointed by stringbuffers), bytes %blockheader = type { i64 } %block = type { %blockheader, [0 x i64 *] } ; 16-bit layout, 8-bit length, 32-bit tag, children %mpz = type { i32, i32, i64* } diff --git a/runtime/util/ConfigurationPrinter.cpp b/runtime/util/ConfigurationPrinter.cpp index df510fb50..6fca50555 100644 --- a/runtime/util/ConfigurationPrinter.cpp +++ b/runtime/util/ConfigurationPrinter.cpp @@ -142,28 +142,13 @@ void printConfigurationInternal( uint16_t layout = get_layout(subject); if (!layout) { string *str = (string *)subject; - size_t subject_len = len(subject); - sfprintf(file, "\\dv{%s}(\"", sort); - for (size_t i = 0; i < subject_len; ++i) { - char c = str->data[i]; - switch (c) { - case '\\': sfprintf(file, "\\\\"); break; - case '"': sfprintf(file, "\\\""); break; - case '\n': sfprintf(file, "\\n"); break; - case '\t': sfprintf(file, "\\t"); break; - case '\r': sfprintf(file, "\\r"); break; - case '\f': sfprintf(file, "\\f"); break; - default: - if ((unsigned char)c >= 32 && (unsigned char)c < 127) { - sfprintf(file, "%c", c); - } else { - sfprintf(file, "\\x%02x", (unsigned char)c); - } - break; - } - } + std::string stdStr = std::string(str->data, len(str)); + kllvm::StringType strType = is_bytes(subject) ? kllvm::StringType::BYTES + : kllvm::StringType::UTF8; + sfprintf( + file, "\\dv{%s}(\"%s", sort, + kllvm::escapeString(stdStr, strType).c_str()); if (isVar && !state.varNames.count(str)) { - std::string stdStr = std::string(str->data, len(str)); std::string suffix = ""; while (state.usedVarNames.count(stdStr + suffix)) { suffix = std::to_string(state.varCounter++); From a3c88e7eaa80bb94b40cb840148b16f4023d8eb8 Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Tue, 15 Aug 2023 15:18:33 -0400 Subject: [PATCH 06/28] Add dummy return to silence warning --- lib/ast/AST.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/ast/AST.cpp b/lib/ast/AST.cpp index cbce3011c..b8573d4ff 100644 --- a/lib/ast/AST.cpp +++ b/lib/ast/AST.cpp @@ -680,6 +680,7 @@ static std::pair readCodepoint(const char *utf8Str) { } } assert(false && "Invalid UTF-8 string"); + return {0, 0}; } std::string From 6e31d8eaf10dbef48c63600e5f460c44d0a019b8 Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Tue, 15 Aug 2023 15:44:49 -0400 Subject: [PATCH 07/28] Set IS_BYTES bit in bytes2string and string2bytes --- runtime/strings/bytes.cpp | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/runtime/strings/bytes.cpp b/runtime/strings/bytes.cpp index 48582e73f..9126916df 100644 --- a/runtime/strings/bytes.cpp +++ b/runtime/strings/bytes.cpp @@ -106,7 +106,7 @@ hook_BYTES_int2bytes(SortInt len, SortInt i, SortEndianness endianness_ptr) { return result; } -string *bytes2string(string *b, size_t len) { +string *allocStringCopy(string *b, size_t len) { string *result = static_cast(koreAllocToken(sizeof(string) + len)); memcpy(result->data, b->data, len); set_len(result, len); @@ -114,11 +114,15 @@ string *bytes2string(string *b, size_t len) { } SortString hook_BYTES_bytes2string(SortBytes b) { - return bytes2string(b, len(b)); + string *result = allocStringCopy(b, len(b)); + set_is_bytes(result, false); + return result; } SortBytes hook_BYTES_string2bytes(SortString s) { - return hook_BYTES_bytes2string(s); + string *result = allocStringCopy(s, len(s)); + set_is_bytes(result, true); + return result; } SortBytes hook_BYTES_substr(SortBytes input, SortInt start, SortInt end) { From acfae41250fceb2718634574f8f69b69417684c5 Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Tue, 15 Aug 2023 16:03:12 -0400 Subject: [PATCH 08/28] Rename missed usage of bytes2string to allocStringCopy --- runtime/strings/strings.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/runtime/strings/strings.cpp b/runtime/strings/strings.cpp index 135c12cd5..edd16e9fa 100644 --- a/runtime/strings/strings.cpp +++ b/runtime/strings/strings.cpp @@ -22,7 +22,7 @@ extern "C" { mpz_ptr move_int(mpz_t); floating *move_float(floating *); -string *bytes2string(string *, size_t); +string *allocStringCopy(string *, size_t); string *hook_BYTES_concat(string *a, string *b); mpz_ptr hook_BYTES_length(string *a); string *hook_BYTES_substr(string *a, mpz_t start, mpz_t end); @@ -442,7 +442,7 @@ hook_BUFFER_concat_raw(stringbuffer *buf, char const *data, uint64_t n) { } SortString hook_BUFFER_toString(SortStringBuffer buf) { - return bytes2string(buf->contents, buf->strlen); + return allocStringCopy(buf->contents, buf->strlen); } } From cf08f4f80f5c013073b8fa78ba6f631e9ebb8a0c Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Tue, 15 Aug 2023 16:16:02 -0400 Subject: [PATCH 09/28] escapeString: Correct lengths passed to snprintf --- lib/ast/AST.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/ast/AST.cpp b/lib/ast/AST.cpp index b8573d4ff..b3587beb2 100644 --- a/lib/ast/AST.cpp +++ b/lib/ast/AST.cpp @@ -718,13 +718,13 @@ kllvm::escapeString(const std::string &str, kllvm::StringType strType) { } else if (codepoint <= 0xFFFF) { char buf[5]; buf[4] = 0; - snprintf(buf, 3, "%04" PRIx64, codepoint); + snprintf(buf, 5, "%04" PRIx64, codepoint); result.append("\\u"); result.append(buf); } else { char buf[9]; buf[8] = 0; - snprintf(buf, 3, "%08" PRIx64, codepoint); + snprintf(buf, 9, "%08" PRIx64, codepoint); result.append("\\U"); result.append(buf); } From d64ef7ab7dc84c1ccda01ecda92a7f73bbf354ee Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Wed, 16 Aug 2023 17:01:30 -0400 Subject: [PATCH 10/28] emitGetToken: Fix type CurrentBlock -> CaseBlock for Bytes case --- lib/codegen/EmitConfigParser.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/codegen/EmitConfigParser.cpp b/lib/codegen/EmitConfigParser.cpp index bf9dd9352..0ef1e4357 100644 --- a/lib/codegen/EmitConfigParser.cpp +++ b/lib/codegen/EmitConfigParser.cpp @@ -682,12 +682,12 @@ static void emitGetToken(KOREDefinition *definition, llvm::Module *module) { llvm::Type::getInt8PtrTy(Ctx), llvm::Type::getInt64Ty(Ctx)); llvm::Value *BytesLength = llvm::CallInst::Create( DecodeBytes, {func->arg_begin() + 2, func->arg_begin() + 1}, "", - CurrentBlock); + CaseBlock); auto result = makeStringToken( func->arg_begin() + 2, BytesLength, kllvm::StringType::BYTES, - CurrentBlock); - Phi->addIncoming(result, CaseBlock); + CaseBlock); llvm::BranchInst::Create(MergeBlock, CaseBlock); + Phi->addIncoming(result, CaseBlock); break; } case SortCategory::Uncomputed: abort(); From 26e472210993c1283930169b38f777937cfb89e6 Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Wed, 16 Aug 2023 17:15:16 -0400 Subject: [PATCH 11/28] Make bytesStringPatternToBytes extern C --- include/kllvm/ast/AST.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/kllvm/ast/AST.h b/include/kllvm/ast/AST.h index 65afb67da..66112d5f6 100644 --- a/include/kllvm/ast/AST.h +++ b/include/kllvm/ast/AST.h @@ -667,7 +667,7 @@ std::string escapeString(const std::string &str, StringType strType); // from UTF-8 to latin-1. // // The input buffer is overwritten, and the new length is returned. -size_t bytesStringPatternToBytes(char *contents, size_t length); +extern "C" size_t bytesStringPatternToBytes(char *contents, size_t length); // KOREDeclaration class KOREDeclaration { From 5dbcb97d893ccb1b9b77152a4f8fce1033ddfe4a Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Thu, 17 Aug 2023 14:11:47 -0400 Subject: [PATCH 12/28] Refactor KOREScanner UTF-8 conversion to use UTF8EncodingType --- include/kllvm/ast/AST.h | 3 ++ include/kllvm/parser/KOREScanner.h | 2 +- lib/ast/AST.cpp | 40 +++++++++++++++++++------ lib/parser/KOREScanner.l | 48 +++++++----------------------- 4 files changed, 46 insertions(+), 47 deletions(-) diff --git a/include/kllvm/ast/AST.h b/include/kllvm/ast/AST.h index 66112d5f6..b6ca4933a 100644 --- a/include/kllvm/ast/AST.h +++ b/include/kllvm/ast/AST.h @@ -646,6 +646,9 @@ class KOREStringPattern : public KOREPattern { : contents(Contents) { } }; +// Convert a Unicode codepoint to a UTF-8 encoded string containing that codepoint +std::string codepointToUTF8(uint32_t codepoint); + // Return a representation of str with all special characters replaced by their // escape sequences. // diff --git a/include/kllvm/parser/KOREScanner.h b/include/kllvm/parser/KOREScanner.h index d825e7a98..633f09218 100644 --- a/include/kllvm/parser/KOREScanner.h +++ b/include/kllvm/parser/KOREScanner.h @@ -50,7 +50,7 @@ class KOREScanner { return yylex(lval, loc, scanner); } void error(const location &loc, const std::string &err_message); - std::string codepoint_to_utf8(unsigned long int code, const location &loc); + std::string codepointToUTF8(const char *codepointStr, const location &loc); FILE *in; std::string stringBuffer; diff --git a/lib/ast/AST.cpp b/lib/ast/AST.cpp index b3587beb2..26691b0d4 100644 --- a/lib/ast/AST.cpp +++ b/lib/ast/AST.cpp @@ -647,6 +647,10 @@ color(std::ostream &out, std::string color, PrettyPrintData const &data) { #define RESET_COLOR "\x1b[0m" struct UTF8EncodingType { + // The first codepoint which is encoded with this type + uint32_t firstCodepoint; + // The last codepoint which is encoded with this type + uint32_t lastCodepoint; // A mask to extract the leading bits from the first byte char leadingBitsMask; // The expected value after applying the leading bits mask @@ -657,13 +661,31 @@ struct UTF8EncodingType { static const UTF8EncodingType utf8EncodingTypes[4] = { // 0xxxxxxx - {static_cast(0x80), static_cast(0x00), 0}, + {0x0000, 0x007F, static_cast(0x80), static_cast(0x00), 0}, // 110xxxxx 10xxxxxx - {static_cast(0xE0), static_cast(0xC0), 1}, + {0x0080, 0x07FF, static_cast(0xE0), static_cast(0xC0), 1}, // 1110xxxx 10xxxxxx 10xxxxxx - {static_cast(0xF0), static_cast(0xE0), 2}, + {0x0800, 0xFFFF, static_cast(0xF0), static_cast(0xE0), 2}, // 11110xxx 10xxxxxx 10xxxxxx 10xxxxxx - {static_cast(0xF8), static_cast(0xF0), 3}}; + {0x10000, 0x10FFFF, static_cast(0xF8), static_cast(0xF0), 3}}; + +std::string kllvm::codepointToUTF8(uint32_t codepoint) { + std::string result; + for (auto const &type : utf8EncodingTypes) { + if (type.firstCodepoint <= codepoint && codepoint <= type.lastCodepoint) { + int numCont = type.numContinuationBytes; + std::string result(1 + numCont, '\0'); + for (int i = numCont; i > 0; --i) { + result[i] = 0x80 | (codepoint & 0x3F); + codepoint >>= 6; + } + result[0] = type.leadingBitsValue | codepoint; + return result; + } + } + assert(false && "Invalid Unicode codepoint"); + return ""; +} // Read one codepoint from a UTF-8 encoded string, returning the codepoint // along with the number of bytes it took to encode @@ -689,9 +711,9 @@ kllvm::escapeString(const std::string &str, kllvm::StringType strType) { const char *strIter = str.data(); const char *strEnd = strIter + str.length(); while (strIter != strEnd) { - uint64_t codepoint; + uint32_t codepoint; if (strType == kllvm::StringType::BYTES) { - codepoint = static_cast(*strIter); + codepoint = static_cast(*strIter); ++strIter; } else { assert(strType == kllvm::StringType::UTF8); @@ -712,19 +734,19 @@ kllvm::escapeString(const std::string &str, kllvm::StringType strType) { } else if (codepoint <= 0xFF) { char buf[3]; buf[2] = 0; - snprintf(buf, 3, "%02" PRIx64, codepoint); + snprintf(buf, 3, "%02" PRIx32, codepoint); result.append("\\x"); result.append(buf); } else if (codepoint <= 0xFFFF) { char buf[5]; buf[4] = 0; - snprintf(buf, 5, "%04" PRIx64, codepoint); + snprintf(buf, 5, "%04" PRIx32, codepoint); result.append("\\u"); result.append(buf); } else { char buf[9]; buf[8] = 0; - snprintf(buf, 9, "%08" PRIx64, codepoint); + snprintf(buf, 9, "%08" PRIx32, codepoint); result.append("\\U"); result.append(buf); } diff --git a/lib/parser/KOREScanner.l b/lib/parser/KOREScanner.l index 96e3ab5e4..6d9fb95d0 100644 --- a/lib/parser/KOREScanner.l +++ b/lib/parser/KOREScanner.l @@ -1,5 +1,6 @@ %{ +#include "kllvm/ast/AST.h" #include "kllvm/parser/KOREScanner.h" #include #include @@ -80,9 +81,9 @@ yyin = in; "\\\"" { stringBuffer.push_back('\"'); } "\\\\" { stringBuffer.push_back('\\'); } \\[0-9]{3} { stringBuffer.push_back((yytext[1] - '0') * 64 + (yytext[2] - '0') * 8 + yytext[3] - '0'); } -\\x[0-9a-fA-F]{2} { stringBuffer.append(codepoint_to_utf8(strtoul(yytext+2, NULL, 16), *loc)); } -\\u[0-9a-fA-F]{4} { stringBuffer.append(codepoint_to_utf8(strtoul(yytext+2, NULL, 16), *loc)); } -\\U[0-9a-fA-F]{8} { stringBuffer.append(codepoint_to_utf8(strtoul(yytext+2, NULL, 16), *loc)); } +\\x[0-9a-fA-F]{2} { stringBuffer.append(codepointToUTF8(yytext + 2, *loc)); } +\\u[0-9a-fA-F]{4} { stringBuffer.append(codepointToUTF8(yytext + 2, *loc)); } +\\U[0-9a-fA-F]{8} { stringBuffer.append(codepointToUTF8(yytext + 2, *loc)); } "\"" { BEGIN(INITIAL); *lval = stringBuffer; @@ -128,45 +129,18 @@ void KOREScanner::error( exit(-1); } -std::string KOREScanner::codepoint_to_utf8(unsigned long int code, - const location &loc) { - // Let xxxx... denote the bits of the code point - if (code <= 0x7F) { - // 0xxxxxxx - char utf8[1] = {static_cast(code)}; - return std::string(utf8, 1); - } - if (code <= 0x7FF) { - // 110xxxxx 10xxxxxx - char utf8[2] - = {static_cast(0xC0 | (code >> 6)), - static_cast(0x80 | (code & 0x3F))}; - return std::string(utf8, 2); - } - if (0xD800 <= code && code <= 0xDFFF) { +std::string +KOREScanner::codepointToUTF8(const char *codepointStr, const location &loc) { + uint32_t codepoint = static_cast(strtoul(codepointStr, NULL, 16)); + if (0xD800 <= codepoint && codepoint <= 0xDFFF) { error( loc, "The surrogate code points in the range [U+D800, U+DFFF] " "are illegal in Unicode escape sequences\n"); } - if (code <= 0xFFFF) { - // 1110xxxx 10xxxxxx 10xxxxxx - char utf8[3] - = {static_cast(0xE0 | (code >> 12)), - static_cast(0x80 | ((code >> 6) & 0x3F)), - static_cast(0x80 | (code & 0x3F))}; - return std::string(utf8, 3); - } - if (code <= 0x10FFFF) { - // 11110xxx 10xxxxxx 10xxxxxx 10xxxxxx - char utf8[4] - = {static_cast(0xF0 | (code >> 18)), - static_cast(0x80 | ((code >> 12) & 0x3F)), - static_cast(0x80 | ((code >> 6) & 0x3F)), - static_cast(0x80 | (code & 0x3F))}; - return std::string(utf8, 4); + if (codepoint > 0x10FFFF) { + error(loc, "Unicode code points cannot exceed U+10FFFF\n"); } - error(loc, "Unicode code points cannot exceed U+10FFFF\n"); - return ""; + return kllvm::codepointToUTF8(codepoint); } int KOREScanner::scan() { From 0670ca0ff09df2174c090d7d336eca9cea748162 Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Thu, 17 Aug 2023 15:34:03 -0400 Subject: [PATCH 13/28] Convert Bytes back to UTF-8 encoded version when serializing --- lib/ast/AST.cpp | 6 ++++-- runtime/util/ConfigurationSerializer.cpp | 8 ++++++++ 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/lib/ast/AST.cpp b/lib/ast/AST.cpp index 26691b0d4..02a129284 100644 --- a/lib/ast/AST.cpp +++ b/lib/ast/AST.cpp @@ -713,7 +713,7 @@ kllvm::escapeString(const std::string &str, kllvm::StringType strType) { while (strIter != strEnd) { uint32_t codepoint; if (strType == kllvm::StringType::BYTES) { - codepoint = static_cast(*strIter); + codepoint = static_cast(static_cast(*strIter)); ++strIter; } else { assert(strType == kllvm::StringType::UTF8); @@ -730,7 +730,7 @@ kllvm::escapeString(const std::string &str, kllvm::StringType strType) { case 0x0C: result.append("\\f"); break; default: if (32 <= codepoint && codepoint < 127) { - result.push_back(static_cast(codepoint)); + result.push_back(static_cast(codepoint)); } else if (codepoint <= 0xFF) { char buf[3]; buf[2] = 0; @@ -738,12 +738,14 @@ kllvm::escapeString(const std::string &str, kllvm::StringType strType) { result.append("\\x"); result.append(buf); } else if (codepoint <= 0xFFFF) { + assert(strType == kllvm::StringType::UTF8); char buf[5]; buf[4] = 0; snprintf(buf, 5, "%04" PRIx32, codepoint); result.append("\\u"); result.append(buf); } else { + assert(strType == kllvm::StringType::UTF8); char buf[9]; buf[8] = 0; snprintf(buf, 9, "%08" PRIx32, codepoint); diff --git a/runtime/util/ConfigurationSerializer.cpp b/runtime/util/ConfigurationSerializer.cpp index bdba56a35..8e1465cec 100644 --- a/runtime/util/ConfigurationSerializer.cpp +++ b/runtime/util/ConfigurationSerializer.cpp @@ -301,6 +301,14 @@ void serializeConfigurationInternal( state.varNames[str] = suffix; } else if (isVar) { emitToken(state.instance, sort, state.varNames[str].c_str()); + } else if (is_bytes(str)) { + std::string utf8Encoded; + for (int i = 0; i < subject_len; ++i) { + utf8Encoded += kllvm::codepointToUTF8( + static_cast(static_cast(str->data[i]))); + } + emitToken( + state.instance, sort, utf8Encoded.c_str(), utf8Encoded.length()); } else { emitToken(state.instance, sort, str->data, subject_len); } From f53aea9817054e96aed7e97eecf620bf84784b4b Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Fri, 18 Aug 2023 10:54:46 -0400 Subject: [PATCH 14/28] sfprintf: Correctly va_copy and va_end to avoid undefined behavior --- runtime/util/ConfigurationPrinter.cpp | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/runtime/util/ConfigurationPrinter.cpp b/runtime/util/ConfigurationPrinter.cpp index 6fca50555..47a5b398a 100644 --- a/runtime/util/ConfigurationPrinter.cpp +++ b/runtime/util/ConfigurationPrinter.cpp @@ -90,6 +90,8 @@ void sfprintf(writer *file, const char *fmt, ...) { } else { char buf[8192]; char *finalBuf = buf; + va_list args_copy; + va_copy(args_copy, args); int res = vsnprintf( buf + sizeof(blockheader), sizeof(buf) - sizeof(blockheader), fmt, args); @@ -97,23 +99,32 @@ void sfprintf(writer *file, const char *fmt, ...) { size_t size = sizeof(buf) * 2; finalBuf = (char *)malloc(size); memcpy(finalBuf, buf, sizeof(buf)); + va_list args_temp; + va_copy(args_temp, args_copy); res = vsnprintf( finalBuf + sizeof(blockheader), size - sizeof(blockheader), fmt, - args); + args_temp); + va_end(args_temp); if (res >= size - sizeof(blockheader)) { do { size *= 2; finalBuf = (char *)realloc(finalBuf, size); + va_list args_temp; + va_copy(args_temp, args_copy); res = vsnprintf( finalBuf + sizeof(blockheader), size - sizeof(blockheader), fmt, - args); + args_temp); + va_end(args_temp); + } while (res >= size - sizeof(blockheader)); } } + va_end(args_copy); string *str = (string *)finalBuf; set_len(str, res); hook_BUFFER_concat(file->buffer, str); } + va_end(args); } void printComma(writer *file, void *state) { From f1b34e3d8014f816c184c1fbf666a4ab75b0cc05 Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Fri, 18 Aug 2023 11:15:15 -0400 Subject: [PATCH 15/28] Convert to UTF-8 encoded representation of Bytes when parsing decision tree --- include/kllvm/ast/AST.h | 3 +++ lib/ast/AST.cpp | 9 +++++++++ lib/codegen/DecisionParser.cpp | 3 +++ runtime/util/ConfigurationSerializer.cpp | 10 +++------- 4 files changed, 18 insertions(+), 7 deletions(-) diff --git a/include/kllvm/ast/AST.h b/include/kllvm/ast/AST.h index b6ca4933a..40a9f3bb4 100644 --- a/include/kllvm/ast/AST.h +++ b/include/kllvm/ast/AST.h @@ -672,6 +672,9 @@ std::string escapeString(const std::string &str, StringType strType); // The input buffer is overwritten, and the new length is returned. extern "C" size_t bytesStringPatternToBytes(char *contents, size_t length); +// Given a char[] of bytes, return its representation as the contents of a KOREStringPattern. +std::string bytesToBytesStringPattern(const char *bytes, size_t length); + // KOREDeclaration class KOREDeclaration { protected: diff --git a/lib/ast/AST.cpp b/lib/ast/AST.cpp index 02a129284..3ed6c5449 100644 --- a/lib/ast/AST.cpp +++ b/lib/ast/AST.cpp @@ -1968,6 +1968,15 @@ size_t kllvm::bytesStringPatternToBytes(char *contents, size_t length) { return newLength; } +std::string kllvm::bytesToBytesStringPattern(const char *bytes, size_t length) { + std::string result; + for (int i = 0; i < length; ++i) { + result += kllvm::codepointToUTF8( + static_cast(static_cast(bytes[i]))); + } + return result; +} + static void printAttributeList( std::ostream &Out, const std::unordered_map> diff --git a/lib/codegen/DecisionParser.cpp b/lib/codegen/DecisionParser.cpp index 0d80fde6c..b7ec1c3e0 100644 --- a/lib/codegen/DecisionParser.cpp +++ b/lib/codegen/DecisionParser.cpp @@ -178,6 +178,9 @@ class DTPreprocessor { sym->addFormalArgument(sort); sym->addSort(sort); auto pat = KORECompositePattern::Create(std::move(sym)); + if (hook == "BYTES.Bytes") { + val = kllvm::bytesToBytesStringPattern(val.c_str(), val.length()); + } pat->addArgument(KOREStringPattern::Create(val)); return pat; } else { diff --git a/runtime/util/ConfigurationSerializer.cpp b/runtime/util/ConfigurationSerializer.cpp index 8e1465cec..3a8885c99 100644 --- a/runtime/util/ConfigurationSerializer.cpp +++ b/runtime/util/ConfigurationSerializer.cpp @@ -302,13 +302,9 @@ void serializeConfigurationInternal( } else if (isVar) { emitToken(state.instance, sort, state.varNames[str].c_str()); } else if (is_bytes(str)) { - std::string utf8Encoded; - for (int i = 0; i < subject_len; ++i) { - utf8Encoded += kllvm::codepointToUTF8( - static_cast(static_cast(str->data[i]))); - } - emitToken( - state.instance, sort, utf8Encoded.c_str(), utf8Encoded.length()); + std::string encoded + = kllvm::bytesToBytesStringPattern(str->data, subject_len); + emitToken(state.instance, sort, encoded.c_str(), encoded.length()); } else { emitToken(state.instance, sort, str->data, subject_len); } From 11270b029c6c8dc448e43267e1a170bf3f437aa3 Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Fri, 18 Aug 2023 12:28:50 -0400 Subject: [PATCH 16/28] Update test-unicode's output to use a Unicode escape --- test/output/test-unicode.out.diff | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/output/test-unicode.out.diff b/test/output/test-unicode.out.diff index 15e0d78c8..b00b70232 100644 --- a/test/output/test-unicode.out.diff +++ b/test/output/test-unicode.out.diff @@ -1 +1 @@ -Lbl'-LT-'generatedTop'-GT-'{}(Lbl'-LT-'k'-GT-'{}(kseq{}(inj{SortEmoji{}, SortKItem{}}(\dv{SortEmoji{}}("\xf0\x9f\x99\x82")),dotk{}())),Lbl'-LT-'generatedCounter'-GT-'{}(\dv{SortInt{}}("0"))) \ No newline at end of file +Lbl'-LT-'generatedTop'-GT-'{}(Lbl'-LT-'k'-GT-'{}(kseq{}(inj{SortEmoji{}, SortKItem{}}(\dv{SortEmoji{}}("\U0001f642")),dotk{}())),Lbl'-LT-'generatedCounter'-GT-'{}(\dv{SortInt{}}("0"))) \ No newline at end of file From 463cb9528fa7d3d5848533955601dcd5c761102d Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Tue, 22 Aug 2023 23:59:58 -0400 Subject: [PATCH 17/28] Create Bytes SortCategory --- bindings/python/ast.cpp | 3 ++- include/kllvm/ast/AST.h | 3 ++- lib/ast/AST.cpp | 3 +++ lib/codegen/CreateStaticTerm.cpp | 14 +++++++------- lib/codegen/CreateTerm.cpp | 18 ++++++++++-------- lib/codegen/Debug.cpp | 1 + lib/codegen/Decision.cpp | 3 +++ lib/codegen/EmitConfigParser.cpp | 12 +++++++----- 8 files changed, 35 insertions(+), 22 deletions(-) diff --git a/bindings/python/ast.cpp b/bindings/python/ast.cpp index ff0850f33..9c7d5a860 100644 --- a/bindings/python/ast.cpp +++ b/bindings/python/ast.cpp @@ -210,7 +210,8 @@ void bind_ast(py::module_ &m) { .value("Bool", SortCategory::Bool) .value("Symbol", SortCategory::Symbol) .value("Variable", SortCategory::Variable) - .value("MInt", SortCategory::MInt); + .value("MInt", SortCategory::MInt) + .value("Bytes", SortCategory::Bytes); py::class_(ast, "ValueType") .def(py::init([](SortCategory cat) { diff --git a/include/kllvm/ast/AST.h b/include/kllvm/ast/AST.h index 40a9f3bb4..4096f30cb 100644 --- a/include/kllvm/ast/AST.h +++ b/include/kllvm/ast/AST.h @@ -123,7 +123,8 @@ enum class SortCategory { Symbol, Variable, MInt, - RangeMap + RangeMap, + Bytes }; // represents the syntactic category of an LLVM backend term at runtime diff --git a/lib/ast/AST.cpp b/lib/ast/AST.cpp index 3ed6c5449..35f03ace6 100644 --- a/lib/ast/AST.cpp +++ b/lib/ast/AST.cpp @@ -207,6 +207,8 @@ ValueType KORECompositeSort::getCategory(std::string name) { category = SortCategory::StringBuffer; else if (name == "BOOL.Bool") category = SortCategory::Bool; + else if (name == "BYTES.Bytes") + category = SortCategory::Bytes; else if (name == "KVAR.KVar") category = SortCategory::Variable; // we expect the "hook" of a MInt to be of the form "MINT.MInt N" for some @@ -259,6 +261,7 @@ std::string KORESymbol::layoutString(KOREDefinition *definition) const { case SortCategory::Variable: result.push_back('8'); break; case SortCategory::MInt: result.append("_" + std::to_string(cat.bits) + "_"); + case SortCategory::Bytes: case SortCategory::Symbol: result.push_back('0'); break; case SortCategory::Uncomputed: abort(); } diff --git a/lib/codegen/CreateStaticTerm.cpp b/lib/codegen/CreateStaticTerm.cpp index 78b1ff2b8..eff7a360c 100644 --- a/lib/codegen/CreateStaticTerm.cpp +++ b/lib/codegen/CreateStaticTerm.cpp @@ -117,11 +117,12 @@ CreateStaticTerm::operator()(KOREPattern *pattern) { } KORESymbolDeclaration *symbolDecl = Definition->getSymbolDeclarations().at(symbol->getName()); + SortCategory cat + = dynamic_cast(symbol->getArguments()[0].get()) + ->getCategory(Definition) + .cat; if (symbolDecl->getAttributes().count("sortInjection") - && dynamic_cast(symbol->getArguments()[0].get()) - ->getCategory(Definition) - .cat - == SortCategory::Symbol) { + && (cat == SortCategory::Symbol || cat == SortCategory::Bytes)) { std::pair val = (*this)(constructor->getArguments()[0].get()); if (val.second) { @@ -303,10 +304,9 @@ CreateStaticTerm::createToken(ValueType sort, std::string contents) { return llvm::ConstantInt::get( llvm::Type::getInt1Ty(Ctx), contents == "true"); case SortCategory::Variable: + case SortCategory::Bytes: case SortCategory::Symbol: { - bool isBytes = Definition->getHookedSorts().count(sort) - && Definition->getHookedSorts().at(sort)->getHook(Definition) - == "BYTES.Bytes"; + bool isBytes = sort.cat == SortCategory::Bytes; if (isBytes) { size_t newSize = bytesStringPatternToBytes(contents.data(), contents.size()); diff --git a/lib/codegen/CreateTerm.cpp b/lib/codegen/CreateTerm.cpp index e60fbd65c..49a0b7459 100644 --- a/lib/codegen/CreateTerm.cpp +++ b/lib/codegen/CreateTerm.cpp @@ -174,6 +174,7 @@ llvm::Type *getValueType(ValueType sort, llvm::Module *Module) { case SortCategory::Bool: return llvm::Type::getInt1Ty(Module->getContext()); case SortCategory::MInt: return llvm::IntegerType::get(Module->getContext(), sort.bits); + case SortCategory::Bytes: case SortCategory::Symbol: case SortCategory::Variable: return llvm::PointerType::getUnqual(getTypeByName(Module, BLOCK_STRUCT)); @@ -971,12 +972,12 @@ CreateTerm::createAllocation(KOREPattern *pattern) { createFunctionCall("eval_" + Out.str(), constructor, false, true), true); } - } else if ( - symbolDecl->getAttributes().count("sortInjection") - && dynamic_cast(symbol->getArguments()[0].get()) - ->getCategory(Definition) - .cat - == SortCategory::Symbol) { + } else if (auto cat = dynamic_cast( + symbol->getArguments()[0].get()) + ->getCategory(Definition) + .cat; + symbolDecl->getAttributes().count("sortInjection") + && (cat == SortCategory::Symbol || cat == SortCategory::Bytes)) { std::pair val = createAllocation(constructor->getArguments()[0].get()); if (val.second) { @@ -1184,8 +1185,8 @@ bool makeFunction( llvm::Type::getInt8PtrTy(Module->getContext()), llvm::Type::getInt8PtrTy(Module->getContext())), {outputFile, varname}); - if (cat.cat == SortCategory::Symbol - || cat.cat == SortCategory::Variable) { + if (cat.cat == SortCategory::Symbol || cat.cat == SortCategory::Variable + || cat.cat == SortCategory::Bytes) { ir->CreateCall( getOrInsertFunction( Module, "serializeTermToFile", @@ -1402,6 +1403,7 @@ llvm::Type *getArgType(ValueType cat, llvm::Module *mod) { case SortCategory::Int: return getTypeByName(mod, INT_STRUCT); case SortCategory::Float: return getTypeByName(mod, FLOAT_STRUCT); case SortCategory::StringBuffer: return getTypeByName(mod, BUFFER_STRUCT); + case SortCategory::Bytes: case SortCategory::Symbol: case SortCategory::Variable: { return getBlockType(mod); diff --git a/lib/codegen/Debug.cpp b/lib/codegen/Debug.cpp index d3fba88cb..3c9caab0b 100644 --- a/lib/codegen/Debug.cpp +++ b/lib/codegen/Debug.cpp @@ -207,6 +207,7 @@ llvm::DIType *getDebugType(ValueType type, std::string typeName) { typeName, type.bits, llvm::dwarf::DW_ATE_unsigned); types[typeName] = mint; return mint; + case SortCategory::Bytes: case SortCategory::Symbol: case SortCategory::Variable: symbol = getPointerDebugType(getForwardDecl(BLOCK_STRUCT), typeName); diff --git a/lib/codegen/Decision.cpp b/lib/codegen/Decision.cpp index 1d35d314a..83346daeb 100644 --- a/lib/codegen/Decision.cpp +++ b/lib/codegen/Decision.cpp @@ -877,6 +877,7 @@ std::pair, llvm::BasicBlock *> stepFunctionHeader( case SortCategory::Int: case SortCategory::Float: case SortCategory::StringBuffer: + case SortCategory::Bytes: case SortCategory::Symbol: case SortCategory::Variable: nroots++; @@ -915,6 +916,7 @@ std::pair, llvm::BasicBlock *> stepFunctionHeader( case SortCategory::List: case SortCategory::Set: case SortCategory::StringBuffer: + case SortCategory::Bytes: case SortCategory::Symbol: case SortCategory::Variable: case SortCategory::Int: @@ -979,6 +981,7 @@ std::pair, llvm::BasicBlock *> stepFunctionHeader( case SortCategory::List: case SortCategory::Set: case SortCategory::StringBuffer: + case SortCategory::Bytes: case SortCategory::Symbol: case SortCategory::Variable: case SortCategory::Int: diff --git a/lib/codegen/EmitConfigParser.cpp b/lib/codegen/EmitConfigParser.cpp index 0ef1e4357..5cfd378ff 100644 --- a/lib/codegen/EmitConfigParser.cpp +++ b/lib/codegen/EmitConfigParser.cpp @@ -341,6 +341,7 @@ static llvm::Value *getArgValue( case SortCategory::Int: case SortCategory::Float: case SortCategory::StringBuffer: + case SortCategory::Bytes: case SortCategory::Symbol: case SortCategory::Variable: arg = new llvm::BitCastInst(arg, getValueType(cat, mod), "", CaseBlock); @@ -378,6 +379,7 @@ static std::pair getEval( case SortCategory::Int: case SortCategory::Float: case SortCategory::StringBuffer: + case SortCategory::Bytes: case SortCategory::Symbol: case SortCategory::Variable: case SortCategory::Map: @@ -558,9 +560,7 @@ static void emitGetToken(KOREDefinition *definition, llvm::Module *module) { auto sort = KORECompositeSort::Create(name); ValueType cat = sort->getCategory(definition); - if ((cat.cat == SortCategory::Symbol - && sort->getHook(definition) != "BYTES.Bytes") - || cat.cat == SortCategory::Variable) { + if (cat.cat == SortCategory::Symbol || cat.cat == SortCategory::Variable) { continue; } CurrentBlock->insertInto(func); @@ -675,8 +675,7 @@ static void emitGetToken(KOREDefinition *definition, llvm::Module *module) { Phi->addIncoming(cast, CaseBlock); break; } - case SortCategory::Variable: break; - case SortCategory::Symbol: { + case SortCategory::Bytes: { llvm::Function *DecodeBytes = getOrInsertFunction( module, "bytesStringPatternToBytes", llvm::Type::getInt64Ty(Ctx), llvm::Type::getInt8PtrTy(Ctx), llvm::Type::getInt64Ty(Ctx)); @@ -690,6 +689,8 @@ static void emitGetToken(KOREDefinition *definition, llvm::Module *module) { Phi->addIncoming(result, CaseBlock); break; } + case SortCategory::Variable: + case SortCategory::Symbol: break; case SortCategory::Uncomputed: abort(); } CurrentBlock = FalseBlock; @@ -997,6 +998,7 @@ static void getVisitor( Str->getType(), global, indices); switch (cat.cat) { case SortCategory::Variable: + case SortCategory::Bytes: case SortCategory::Symbol: llvm::CallInst::Create( llvm::FunctionType::get( From 01659625a205214d2ae238bdc2851172871e12ac Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Wed, 23 Aug 2023 15:57:30 -0400 Subject: [PATCH 18/28] Added test-unicode-strings --- test/defn/k-files/test-unicode-strings.k | 42 + test/defn/test-unicode-strings.kore | 3350 +++++++++++++++++++++ test/input/test-unicode-strings.in | 1 + test/output/test-unicode-strings.out.diff | 1 + 4 files changed, 3394 insertions(+) create mode 100644 test/defn/k-files/test-unicode-strings.k create mode 100644 test/defn/test-unicode-strings.kore create mode 100644 test/input/test-unicode-strings.in create mode 100644 test/output/test-unicode-strings.out.diff diff --git a/test/defn/k-files/test-unicode-strings.k b/test/defn/k-files/test-unicode-strings.k new file mode 100644 index 000000000..946e58f3b --- /dev/null +++ b/test/defn/k-files/test-unicode-strings.k @@ -0,0 +1,42 @@ + +// unicode.k + +module UNICODE-SYNTAX + imports STRING-SYNTAX + syntax Strings ::= List{String,","} +endmodule + +module UNICODE + imports UNICODE-SYNTAX + imports STRING + + configuration $PGM:Strings + .Strings + rule SS:Strings => . ... + _ => goAll(SS) + + syntax Strings ::= goAll(Strings) [function] + syntax String ::= go(String) [function] + + rule goAll(.Strings) => .Strings + rule goAll(S:String, SS:Strings) => go(S) , goAll(SS) + + rule go(S:String) => S [owise] + + rule go("A\x00B") => "goodA\x00B" + + rule go("\x24") => "good$" + + rule go("£") => "good\xA3" + + rule go("\u0418") => "goodИ" + + rule go("ह") => "good\u0939" + + rule go("\u20AC") => "good€" + + rule go("한") => "good\uD55C" + + rule go("𐍈") => "good\U00010348" + +endmodule diff --git a/test/defn/test-unicode-strings.kore b/test/defn/test-unicode-strings.kore new file mode 100644 index 000000000..4f978a1ce --- /dev/null +++ b/test/defn/test-unicode-strings.kore @@ -0,0 +1,3350 @@ +// RUN: %interpreter +// RUN: %check-diff +[topCellInitializer{}(LblinitGeneratedTopCell{}()), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k-test/unicode.k)")] + +module BASIC-K + sort SortK{} [] + sort SortKItem{} [] +endmodule +[] +module KSEQ + import BASIC-K [] + symbol kseq{}(SortKItem{}, SortK{}) : SortK{} [constructor{}(), functional{}(), injective{}()] + symbol dotk{}() : SortK{} [constructor{}(), functional{}(), injective{}()] + symbol append{}(SortK{}, SortK{}) : SortK{} [function{}(), functional{}()] + axiom {R} \implies{R}( + \and{R}( + \top{R}(), + \and{R}( + \in{SortK{}, R}(X0:SortK{}, dotk{}()), + \and{R}( + \in{SortK{}, R}(X1:SortK{}, TAIL:SortK{}), + \top{R}() + )) + ), + \equals{SortK{}, R}( + append{}(X0:SortK{}, X1:SortK{}), + \and{SortK{}}( + TAIL:SortK{}, + \top{SortK{}}() + ) + ) + ) [] + axiom {R} \implies{R}( + \and{R}( + \top{R}(), + \and{R}( + \in{SortK{}, R}(X0:SortK{}, kseq{}(K:SortKItem{}, KS:SortK{})), + \and{R}( + \in{SortK{}, R}(X1:SortK{}, TAIL:SortK{}), + \top{R}() + )) + ), + \equals{SortK{}, R}( + append{}(X0:SortK{}, X1:SortK{}), + \and{SortK{}}( + kseq{}(K:SortKItem{}, append{}(KS:SortK{}, TAIL:SortK{})), + \top{SortK{}}() + ) + ) + ) [] +endmodule +[] +module INJ + symbol inj{From, To}(From) : To [sortInjection{}()] + axiom {S1, S2, S3, R} \equals{S3, R}(inj{S2, S3}(inj{S1, S2}(T:S1)), inj{S1, S3}(T:S1)) [simplification{}()] +endmodule +[] +module K + import KSEQ [] + import INJ [] + alias weakExistsFinally{A}(A) : A where weakExistsFinally{A}(@X:A) := @X:A [] + alias weakAlwaysFinally{A}(A) : A where weakAlwaysFinally{A}(@X:A) := @X:A [] + alias allPathGlobally{A}(A) : A where allPathGlobally{A}(@X:A) := @X:A [] +endmodule +[] + +module UNICODE + +// imports + import K [] + +// sorts + sort SortKCellOpt{} [] + sort SortGeneratedTopCellFragment{} [] + hooked-sort SortList{} [concat{}(Lbl'Unds'List'Unds'{}()), element{}(LblListItem{}()), hook{}("LIST.List"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(913,3,913,32)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), unit{}(Lbl'Stop'List{}())] + sort SortKCell{} [] + sort SortOutCell{} [] + sort SortGeneratedTopCell{} [] + sort SortGeneratedCounterCell{} [] + hooked-sort SortFloat{} [hasDomainValues{}(), hook{}("FLOAT.Float"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1470,3,1470,35)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)")] + hooked-sort SortMap{} [concat{}(Lbl'Unds'Map'Unds'{}()), element{}(Lbl'UndsPipe'-'-GT-Unds'{}()), hook{}("MAP.Map"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(218,3,218,29)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), unit{}(Lbl'Stop'Map{}())] + hooked-sort SortString{} [hasDomainValues{}(), hook{}("STRING.String"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1683,3,1683,38)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)")] + sort SortKConfigVar{} [hasDomainValues{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(40,3,40,28)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/kast.md)"), token{}()] + hooked-sort SortInt{} [hasDomainValues{}(), hook{}("INT.Int"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1189,3,1189,29)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)")] + hooked-sort SortSet{} [concat{}(Lbl'Unds'Set'Unds'{}()), element{}(LblSetItem{}()), hook{}("SET.Set"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(700,3,700,29)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), unit{}(Lbl'Stop'Set{}())] + sort SortOutCellOpt{} [] + sort SortStrings{} [] + hooked-sort SortBool{} [hasDomainValues{}(), hook{}("BOOL.Bool"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1068,3,1068,32)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)")] + +// symbols + hooked-symbol Lbl'Hash'if'UndsHash'then'UndsHash'else'UndsHash'fi'Unds'K-EQUAL-SYNTAX'Unds'Sort'Unds'Bool'Unds'Sort'Unds'Sort{SortSort}(SortBool{}, SortSort, SortSort) : SortSort [format{}("%c#if%r %1 %c#then%r %2 %c#else%r %3 %c#fi%r"), function{}(), functional{}(), hook{}("KEQUAL.ite"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(2262,26,2262,121)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), smt-hook{}("ite"), terminals{}("1010101"), total{}()] + hooked-symbol Lbl'Stop'List{}() : SortList{} [format{}("%c.List%r"), function{}(), functional{}(), hook{}("LIST.unit"), klabel{}(".List"), latex{}("\\dotCt{List}"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(937,19,937,142)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), smtlib{}("smt_seq_nil"), symbol'Kywd'{}(), terminals{}("1"), total{}()] + symbol Lbl'Stop'List'LBraQuotUndsCommUndsUnds'UNICODE-SYNTAX'Unds'Strings'Unds'String'Unds'Strings'QuotRBraUnds'Strings{}() : SortStrings{} [constructor{}(), format{}("%c.Strings%r"), functional{}(), injective{}(), klabel{}(".List{\"_,__UNICODE-SYNTAX\"}"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(6,24,6,40)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k-test/unicode.k)"), priorities{}(), right{}(), terminals{}("1"), userList{}("*")] + hooked-symbol Lbl'Stop'Map{}() : SortMap{} [format{}("%c.Map%r"), function{}(), functional{}(), hook{}("MAP.unit"), klabel{}(".Map"), latex{}("\\dotCt{Map}"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(248,18,248,124)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), symbol'Kywd'{}(), terminals{}("1"), total{}()] + hooked-symbol Lbl'Stop'Set{}() : SortSet{} [format{}("%c.Set%r"), function{}(), functional{}(), hook{}("SET.unit"), klabel{}(".Set"), latex{}("\\dotCt{Set}"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(729,18,729,118)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), symbol'Kywd'{}(), terminals{}("1"), total{}()] + symbol Lbl'-LT-'generatedCounter'-GT-'{}(SortInt{}) : SortGeneratedCounterCell{} [cell{}(), cellName{}("generatedCounter"), constructor{}(), format{}("%c%r%i%n%1%d%n%c%r"), functional{}(), injective{}(), left{}(), priorities{}(), right{}(), terminals{}("101"), topcell{}()] + symbol Lbl'-LT-'generatedTop'-GT-'{}(SortKCell{}, SortOutCell{}, SortGeneratedCounterCell{}) : SortGeneratedTopCell{} [cell{}(), cellName{}("generatedTop"), constructor{}(), format{}("%c%r%i%n%1%n%2%d%n%c%r"), functional{}(), injective{}(), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(13,19,14,30)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k-test/unicode.k)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]"), priorities{}(), right{}(), terminals{}("10001"), topcell{}()] + symbol Lbl'-LT-'generatedTop'-GT-'-fragment{}(SortKCellOpt{}, SortOutCellOpt{}) : SortGeneratedTopCellFragment{} [cellFragment{}("GeneratedTopCell"), constructor{}(), format{}("%c-fragment%r %1 %2 %c-fragment%r"), functional{}(), injective{}(), left{}(), priorities{}(), right{}(), terminals{}("1001")] + symbol Lbl'-LT-'k'-GT-'{}(SortK{}) : SortKCell{} [cell{}(), cellName{}("k"), constructor{}(), format{}("%c%r%i%n%1%d%n%c%r"), functional{}(), injective{}(), left{}(), maincell{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(13,19,13,40)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k-test/unicode.k)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]"), priorities{}(), right{}(), terminals{}("101")] + symbol Lbl'-LT-'out'-GT-'{}(SortStrings{}) : SortOutCell{} [cell{}(), cellName{}("out"), constructor{}(), format{}("%c%r%i%n%1%d%n%c%r"), functional{}(), injective{}(), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(14,9,14,30)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k-test/unicode.k)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]"), priorities{}(), right{}(), terminals{}("101")] + hooked-symbol LblBase2String'LParUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'Int'Unds'Int{}(SortInt{}, SortInt{}) : SortString{} [format{}("%cBase2String%r %c(%r %1 %c,%r %2 %c)%r"), function{}(), hook{}("STRING.base2string"), klabel{}("Base2String"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1812,21,1812,99)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("110101")] + symbol LblBool2String'LParUndsRParUnds'STRING-COMMON'Unds'String'Unds'Bool{}(SortBool{}) : SortString{} [format{}("%cBool2String%r %c(%r %1 %c)%r"), function{}(), functional{}(), klabel{}("Bool2String"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1762,21,1762,56)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("1101"), total{}()] + hooked-symbol LblFloat2String'LParUndsRParUnds'STRING-COMMON'Unds'String'Unds'Float{}(SortFloat{}) : SortString{} [format{}("%cFloat2String%r %c(%r %1 %c)%r"), function{}(), functional{}(), hook{}("STRING.float2string"), klabel{}("Float2String"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1789,21,1789,101)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("1101"), total{}()] + hooked-symbol LblFloat2String'LParUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'Float'Unds'String{}(SortFloat{}, SortString{}) : SortString{} [format{}("%cFloat2String%r %c(%r %1 %c,%r %2 %c)%r"), function{}(), hook{}("STRING.floatFormat"), klabel{}("FloatFormat"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1790,21,1790,122)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("110101")] + hooked-symbol LblInt2String'LParUndsRParUnds'STRING-COMMON'Unds'String'Unds'Int{}(SortInt{}) : SortString{} [format{}("%cInt2String%r %c(%r %1 %c)%r"), function{}(), functional{}(), hook{}("STRING.int2string"), klabel{}("Int2String"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1811,21,1811,99)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("1101"), total{}()] + hooked-symbol LblList'Coln'get{}(SortList{}, SortInt{}) : SortKItem{} [format{}("%1 %c[%r %2 %c]%r"), function{}(), hook{}("LIST.get"), klabel{}("List:get"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(956,20,956,99)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), symbol'Kywd'{}(), terminals{}("0101")] + hooked-symbol LblList'Coln'range{}(SortList{}, SortInt{}, SortInt{}) : SortList{} [format{}("%crange%r %c(%r %1 %c,%r %2 %c,%r %3 %c)%r"), function{}(), hook{}("LIST.range"), klabel{}("List:range"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1003,19,1003,120)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), symbol'Kywd'{}(), terminals{}("11010101")] + hooked-symbol LblListItem{}(SortKItem{}) : SortList{} [format{}("%cListItem%r %c(%r %1 %c)%r"), function{}(), functional{}(), hook{}("LIST.element"), klabel{}("ListItem"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(945,19,945,132)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), smtlib{}("smt_seq_elem"), symbol'Kywd'{}(), terminals{}("1101"), total{}()] + hooked-symbol LblMap'Coln'lookup{}(SortMap{}, SortKItem{}) : SortKItem{} [format{}("%1 %c[%r %2 %c]%r"), function{}(), hook{}("MAP.lookup"), klabel{}("Map:lookup"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(271,20,271,113)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), symbol'Kywd'{}(), terminals{}("0101")] + hooked-symbol LblMap'Coln'update{}(SortMap{}, SortKItem{}, SortKItem{}) : SortMap{} [format{}("%1 %c[%r %2 %c<-%r %3 %c]%r"), function{}(), functional{}(), hook{}("MAP.update"), klabel{}("Map:update"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(290,18,290,140)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), prefer{}(), priorities{}(), right{}(), symbol'Kywd'{}(), terminals{}("010101"), total{}()] + hooked-symbol LblSet'Coln'difference{}(SortSet{}, SortSet{}) : SortSet{} [format{}("%1 %c-Set%r %2"), function{}(), functional{}(), hook{}("SET.difference"), klabel{}("Set:difference"), latex{}("{#1}-_{\\it Set}{#2}"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(769,18,769,142)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), symbol'Kywd'{}(), terminals{}("010"), total{}()] + hooked-symbol LblSet'Coln'in{}(SortKItem{}, SortSet{}) : SortBool{} [format{}("%1 %cin%r %2"), function{}(), functional{}(), hook{}("SET.in"), klabel{}("Set:in"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(777,19,777,102)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), symbol'Kywd'{}(), terminals{}("010"), total{}()] + hooked-symbol LblSetItem{}(SortKItem{}) : SortSet{} [format{}("%cSetItem%r %c(%r %1 %c)%r"), function{}(), functional{}(), hook{}("SET.element"), injective{}(), klabel{}("SetItem"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(737,18,737,119)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), symbol'Kywd'{}(), terminals{}("1101"), total{}()] + hooked-symbol LblString2Base'LParUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'Int{}(SortString{}, SortInt{}) : SortInt{} [format{}("%cString2Base%r %c(%r %1 %c,%r %2 %c)%r"), function{}(), hook{}("STRING.string2base"), klabel{}("String2Base"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1813,21,1813,99)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("110101")] + symbol LblString2Bool'LParUndsRParUnds'STRING-COMMON'Unds'Bool'Unds'String{}(SortString{}) : SortBool{} [format{}("%cString2Bool%r %c(%r %1 %c)%r"), function{}(), klabel{}("String2Bool"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1768,19,1768,49)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("1101")] + hooked-symbol LblString2Float'LParUndsRParUnds'STRING-COMMON'Unds'Float'Unds'String{}(SortString{}) : SortFloat{} [format{}("%cString2Float%r %c(%r %1 %c)%r"), function{}(), hook{}("STRING.string2float"), klabel{}("String2Float"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1791,21,1791,94)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("1101")] + hooked-symbol LblString2Int'LParUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String{}(SortString{}) : SortInt{} [format{}("%cString2Int%r %c(%r %1 %c)%r"), function{}(), hook{}("STRING.string2int"), klabel{}("String2Int"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1810,21,1810,92)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("1101")] + hooked-symbol Lbl'UndsPerc'Int'Unds'{}(SortInt{}, SortInt{}) : SortInt{} [format{}("%1 %c%%Int%r %2"), function{}(), hook{}("INT.tmod"), klabel{}("_%Int_"), latex{}("{#1}\\mathrel{\\%_{\\scriptstyle\\it Int}}{#2}"), left{}(Lbl'UndsStar'Int'Unds'{}(),Lbl'Unds'divInt'Unds'{}(),Lbl'UndsPerc'Int'Unds'{}(),Lbl'UndsSlsh'Int'Unds'{}(),Lbl'Unds'modInt'Unds'{}()), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1237,18,1237,171)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(Lbl'UndsPlus'Int'Unds'{}(),Lbl'Unds-GT--GT-'Int'Unds'{}(),Lbl'Unds'xorInt'Unds'{}(),Lbl'UndsAnd-'Int'Unds'{}(),Lbl'Unds-LT--LT-'Int'Unds'{}(),Lbl'UndsPipe'Int'Unds'{}(),Lbl'Unds'-Int'Unds'{}()), right{}(), smt-hook{}("mod"), symbol'Kywd'{}(), terminals{}("010")] + hooked-symbol Lbl'UndsAnd-'Int'Unds'{}(SortInt{}, SortInt{}) : SortInt{} [comm{}(), format{}("%1 %c&Int%r %2"), function{}(), functional{}(), hook{}("INT.and"), klabel{}("_&Int_"), latex{}("{#1}\\mathrel{\\&_{\\scriptstyle\\it Int}}{#2}"), left{}(Lbl'UndsAnd-'Int'Unds'{}()), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1248,18,1248,184)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(Lbl'Unds'xorInt'Unds'{}(),Lbl'UndsPipe'Int'Unds'{}()), right{}(), smtlib{}("andInt"), symbol'Kywd'{}(), terminals{}("010"), total{}()] + hooked-symbol Lbl'UndsStar'Int'Unds'{}(SortInt{}, SortInt{}) : SortInt{} [comm{}(), format{}("%1 %c*Int%r %2"), function{}(), functional{}(), hook{}("INT.mul"), klabel{}("_*Int_"), latex{}("{#1}\\mathrel{\\ast_{\\scriptstyle\\it Int}}{#2}"), left{}(Lbl'Unds'modInt'Unds'{}(),Lbl'UndsPerc'Int'Unds'{}(),Lbl'UndsSlsh'Int'Unds'{}(),Lbl'Unds'divInt'Unds'{}(),Lbl'UndsStar'Int'Unds'{}()), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1233,18,1233,183)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(Lbl'UndsPlus'Int'Unds'{}(),Lbl'Unds-GT--GT-'Int'Unds'{}(),Lbl'Unds'xorInt'Unds'{}(),Lbl'UndsAnd-'Int'Unds'{}(),Lbl'Unds-LT--LT-'Int'Unds'{}(),Lbl'UndsPipe'Int'Unds'{}(),Lbl'Unds'-Int'Unds'{}()), right{}(), smt-hook{}("*"), symbol'Kywd'{}(), terminals{}("010"), total{}()] + hooked-symbol Lbl'UndsPlus'Int'Unds'{}(SortInt{}, SortInt{}) : SortInt{} [comm{}(), format{}("%1 %c+Int%r %2"), function{}(), functional{}(), hook{}("INT.add"), klabel{}("_+Int_"), latex{}("{#1}\\mathrel{+_{\\scriptstyle\\it Int}}{#2}"), left{}(Lbl'UndsPlus'Int'Unds'{}(),Lbl'Unds'-Int'Unds'{}()), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1242,18,1242,180)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(Lbl'Unds-GT--GT-'Int'Unds'{}(),Lbl'Unds'xorInt'Unds'{}(),Lbl'UndsAnd-'Int'Unds'{}(),Lbl'Unds-LT--LT-'Int'Unds'{}(),Lbl'UndsPipe'Int'Unds'{}()), right{}(), smt-hook{}("+"), symbol'Kywd'{}(), terminals{}("010"), total{}()] + hooked-symbol Lbl'UndsPlus'String'UndsUnds'STRING-COMMON'Unds'String'Unds'String'Unds'String{}(SortString{}, SortString{}) : SortString{} [format{}("%1 %c+String%r %2"), function{}(), functional{}(), hook{}("STRING.concat"), latex{}("{#1}+_{\\scriptstyle\\it String}{#2}"), left{}(Lbl'UndsPlus'String'UndsUnds'STRING-COMMON'Unds'String'Unds'String'Unds'String{}()), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1701,21,1701,135)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("010"), total{}()] + symbol Lbl'UndsCommUndsUnds'UNICODE-SYNTAX'Unds'Strings'Unds'String'Unds'Strings{}(SortString{}, SortStrings{}) : SortStrings{} [constructor{}(), format{}("%1 %c,%r %2"), functional{}(), injective{}(), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(6,24,6,40)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k-test/unicode.k)"), priorities{}(), right{}(), terminals{}("010"), userList{}("*")] + hooked-symbol Lbl'Unds'-Int'Unds'{}(SortInt{}, SortInt{}) : SortInt{} [format{}("%1 %c-Int%r %2"), function{}(), functional{}(), hook{}("INT.sub"), klabel{}("_-Int_"), latex{}("{#1}\\mathrel{-_{\\scriptstyle\\it Int}}{#2}"), left{}(Lbl'UndsPlus'Int'Unds'{}(),Lbl'Unds'-Int'Unds'{}()), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1243,18,1243,174)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(Lbl'Unds-GT--GT-'Int'Unds'{}(),Lbl'Unds'xorInt'Unds'{}(),Lbl'UndsAnd-'Int'Unds'{}(),Lbl'Unds-LT--LT-'Int'Unds'{}(),Lbl'UndsPipe'Int'Unds'{}()), right{}(), smt-hook{}("-"), symbol'Kywd'{}(), terminals{}("010"), total{}()] + hooked-symbol Lbl'Unds'-Map'UndsUnds'MAP'Unds'Map'Unds'Map'Unds'Map{}(SortMap{}, SortMap{}) : SortMap{} [format{}("%1 %c-Map%r %2"), function{}(), functional{}(), hook{}("MAP.difference"), latex{}("{#1}-_{\\it Map}{#2}"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(311,18,311,116)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("010"), total{}()] + hooked-symbol Lbl'UndsSlsh'Int'Unds'{}(SortInt{}, SortInt{}) : SortInt{} [format{}("%1 %c/Int%r %2"), function{}(), hook{}("INT.tdiv"), klabel{}("_/Int_"), latex{}("{#1}\\mathrel{\\div_{\\scriptstyle\\it Int}}{#2}"), left{}(Lbl'UndsSlsh'Int'Unds'{}(),Lbl'Unds'modInt'Unds'{}(),Lbl'Unds'divInt'Unds'{}(),Lbl'UndsPerc'Int'Unds'{}(),Lbl'UndsStar'Int'Unds'{}()), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1236,18,1236,173)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(Lbl'UndsPlus'Int'Unds'{}(),Lbl'Unds-GT--GT-'Int'Unds'{}(),Lbl'Unds'xorInt'Unds'{}(),Lbl'UndsAnd-'Int'Unds'{}(),Lbl'Unds-LT--LT-'Int'Unds'{}(),Lbl'UndsPipe'Int'Unds'{}(),Lbl'Unds'-Int'Unds'{}()), right{}(), smt-hook{}("div"), symbol'Kywd'{}(), terminals{}("010")] + hooked-symbol Lbl'Unds-LT--LT-'Int'Unds'{}(SortInt{}, SortInt{}) : SortInt{} [format{}("%1 %c<=Int%r %2"), function{}(), functional{}(), hook{}("INT.ge"), klabel{}("_>=Int_"), latex{}("{#1}\\mathrel{\\geq_{\\scriptstyle\\it Int}}{#2}"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1306,19,1306,166)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), smt-hook{}(">="), symbol'Kywd'{}(), terminals{}("010"), total{}()] + hooked-symbol Lbl'Unds-GT-Eqls'String'UndsUnds'STRING-COMMON'Unds'Bool'Unds'String'Unds'String{}(SortString{}, SortString{}) : SortBool{} [format{}("%1 %c>=String%r %2"), function{}(), functional{}(), hook{}("STRING.ge"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1848,19,1848,78)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("010"), total{}()] + hooked-symbol Lbl'Unds-GT--GT-'Int'Unds'{}(SortInt{}, SortInt{}) : SortInt{} [format{}("%1 %c>>Int%r %2"), function{}(), hook{}("INT.shr"), klabel{}("_>>Int_"), latex{}("{#1}\\mathrel{\\gg_{\\scriptstyle\\it Int}}{#2}"), left{}(Lbl'Unds-LT--LT-'Int'Unds'{}(),Lbl'Unds-GT--GT-'Int'Unds'{}()), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1245,18,1245,173)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(Lbl'Unds'xorInt'Unds'{}(),Lbl'UndsAnd-'Int'Unds'{}(),Lbl'UndsPipe'Int'Unds'{}()), right{}(), smtlib{}("shrInt"), symbol'Kywd'{}(), terminals{}("010")] + hooked-symbol Lbl'Unds-GT-'Int'Unds'{}(SortInt{}, SortInt{}) : SortBool{} [format{}("%1 %c>Int%r %2"), function{}(), functional{}(), hook{}("INT.gt"), klabel{}("_>Int_"), latex{}("{#1}\\mathrel{>_{\\scriptstyle\\it Int}}{#2}"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1307,19,1307,161)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), smt-hook{}(">"), symbol'Kywd'{}(), terminals{}("010"), total{}()] + hooked-symbol Lbl'Unds-GT-'String'UndsUnds'STRING-COMMON'Unds'Bool'Unds'String'Unds'String{}(SortString{}, SortString{}) : SortBool{} [format{}("%1 %c>String%r %2"), function{}(), functional{}(), hook{}("STRING.gt"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1847,19,1847,78)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("010"), total{}()] + hooked-symbol Lbl'Unds'List'Unds'{}(SortList{}, SortList{}) : SortList{} [assoc{}(), element{}(LblListItem{}()), format{}("%1%n%2"), function{}(), functional{}(), hook{}("LIST.concat"), klabel{}("_List_"), left{}(Lbl'Unds'List'Unds'{}()), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(929,19,929,188)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), smtlib{}("smt_seq_concat"), symbol'Kywd'{}(), terminals{}("00"), total{}(), unit{}(Lbl'Stop'List{}())] + hooked-symbol Lbl'Unds'Map'Unds'{}(SortMap{}, SortMap{}) : SortMap{} [assoc{}(), comm{}(), element{}(Lbl'UndsPipe'-'-GT-Unds'{}()), format{}("%1%n%2"), function{}(), hook{}("MAP.concat"), index{}("0"), klabel{}("_Map_"), left{}(Lbl'Unds'Map'Unds'{}()), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(240,18,240,173)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), symbol'Kywd'{}(), terminals{}("00"), unit{}(Lbl'Stop'Map{}())] + hooked-symbol Lbl'Unds'Set'Unds'{}(SortSet{}, SortSet{}) : SortSet{} [assoc{}(), comm{}(), element{}(LblSetItem{}()), format{}("%1%n%2"), function{}(), hook{}("SET.concat"), idem{}(), klabel{}("_Set_"), left{}(Lbl'Unds'Set'Unds'{}()), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(721,18,721,165)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), symbol'Kywd'{}(), terminals{}("00"), unit{}(Lbl'Stop'Set{}())] + hooked-symbol Lbl'UndsLSqBUnds-LT-'-'UndsRSqBUnds'LIST'Unds'List'Unds'List'Unds'Int'Unds'KItem{}(SortList{}, SortInt{}, SortKItem{}) : SortList{} [format{}("%1 %c[%r %2 %c<-%r %3 %c]%r"), function{}(), hook{}("LIST.update"), klabel{}("List:set"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(965,19,965,108)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("010101")] + hooked-symbol Lbl'UndsLSqBUnds-LT-'-undef'RSqB'{}(SortMap{}, SortKItem{}) : SortMap{} [format{}("%1 %c[%r %2 %c<-%r %cundef%r %c]%r"), function{}(), functional{}(), hook{}("MAP.remove"), klabel{}("_[_<-undef]"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(299,18,299,117)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), symbol'Kywd'{}(), terminals{}("010111"), total{}()] + hooked-symbol Lbl'UndsLSqBUndsRSqB'orDefault'UndsUnds'MAP'Unds'KItem'Unds'Map'Unds'KItem'Unds'KItem{}(SortMap{}, SortKItem{}, SortKItem{}) : SortKItem{} [format{}("%1 %c[%r %2 %c]%r %corDefault%r %3"), function{}(), functional{}(), hook{}("MAP.lookupOrDefault"), klabel{}("Map:lookupOrDefault"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(281,20,281,134)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("010110"), total{}()] + hooked-symbol Lbl'UndsXor-Perc'Int'UndsUnds'{}(SortInt{}, SortInt{}, SortInt{}) : SortInt{} [format{}("%1 %c^%%Int%r %2 %3"), function{}(), hook{}("INT.powmod"), klabel{}("_^%Int__"), left{}(Lbl'UndsXor-Perc'Int'UndsUnds'{}(),Lbl'UndsXor-'Int'Unds'{}()), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1231,18,1231,139)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(Lbl'UndsPlus'Int'Unds'{}(),Lbl'Unds'divInt'Unds'{}(),Lbl'UndsPerc'Int'Unds'{}(),Lbl'Unds-GT--GT-'Int'Unds'{}(),Lbl'Unds'xorInt'Unds'{}(),Lbl'UndsSlsh'Int'Unds'{}(),Lbl'UndsAnd-'Int'Unds'{}(),Lbl'Unds-LT--LT-'Int'Unds'{}(),Lbl'UndsStar'Int'Unds'{}(),Lbl'UndsPipe'Int'Unds'{}(),Lbl'Unds'modInt'Unds'{}(),Lbl'Unds'-Int'Unds'{}()), right{}(), smt-hook{}("(mod (^ #1 #2) #3)"), symbol'Kywd'{}(), terminals{}("0100")] + hooked-symbol Lbl'UndsXor-'Int'Unds'{}(SortInt{}, SortInt{}) : SortInt{} [format{}("%1 %c^Int%r %2"), function{}(), hook{}("INT.pow"), klabel{}("_^Int_"), latex{}("{#1}\\mathrel{{\\char`\\^}_{\\!\\scriptstyle\\it Int}}{#2}"), left{}(Lbl'UndsXor-'Int'Unds'{}(),Lbl'UndsXor-Perc'Int'UndsUnds'{}()), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1230,18,1230,178)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(Lbl'UndsPlus'Int'Unds'{}(),Lbl'Unds'divInt'Unds'{}(),Lbl'UndsPerc'Int'Unds'{}(),Lbl'Unds-GT--GT-'Int'Unds'{}(),Lbl'Unds'xorInt'Unds'{}(),Lbl'UndsSlsh'Int'Unds'{}(),Lbl'UndsAnd-'Int'Unds'{}(),Lbl'Unds-LT--LT-'Int'Unds'{}(),Lbl'UndsStar'Int'Unds'{}(),Lbl'UndsPipe'Int'Unds'{}(),Lbl'Unds'modInt'Unds'{}(),Lbl'Unds'-Int'Unds'{}()), right{}(), smt-hook{}("^"), symbol'Kywd'{}(), terminals{}("010")] + hooked-symbol Lbl'Unds'andBool'Unds'{}(SortBool{}, SortBool{}) : SortBool{} [format{}("%1 %candBool%r %2"), function{}(), functional{}(), group{}("boolOperation"), hook{}("BOOL.and"), klabel{}("_andBool_"), latex{}("{#1}\\wedge_{\\scriptstyle\\it Bool}{#2}"), left{}(Lbl'Unds'andBool'Unds'{}()), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1101,19,1101,192)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(Lbl'UndsEqlsSlshEqls'Bool'Unds'{}(),Lbl'UndsEqlsEqls'Bool'Unds'{}()), right{}(), smt-hook{}("and"), symbol'Kywd'{}(), terminals{}("010"), total{}()] + hooked-symbol Lbl'Unds'andThenBool'Unds'{}(SortBool{}, SortBool{}) : SortBool{} [format{}("%1 %candThenBool%r %2"), function{}(), functional{}(), group{}("boolOperation"), hook{}("BOOL.andThen"), klabel{}("_andThenBool_"), left{}(Lbl'Unds'andThenBool'Unds'{}()), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1102,19,1102,154)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(Lbl'UndsEqlsSlshEqls'Bool'Unds'{}(),Lbl'UndsEqlsEqls'Bool'Unds'{}()), right{}(), smt-hook{}("and"), symbol'Kywd'{}(), terminals{}("010"), total{}()] + hooked-symbol Lbl'Unds'divInt'Unds'{}(SortInt{}, SortInt{}) : SortInt{} [format{}("%1 %cdivInt%r %2"), function{}(), hook{}("INT.ediv"), klabel{}("_divInt_"), left{}(Lbl'UndsSlsh'Int'Unds'{}(),Lbl'Unds'modInt'Unds'{}(),Lbl'UndsStar'Int'Unds'{}(),Lbl'UndsPerc'Int'Unds'{}(),Lbl'Unds'divInt'Unds'{}()), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1239,18,1239,122)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(Lbl'UndsPlus'Int'Unds'{}(),Lbl'Unds-GT--GT-'Int'Unds'{}(),Lbl'Unds'xorInt'Unds'{}(),Lbl'UndsAnd-'Int'Unds'{}(),Lbl'Unds-LT--LT-'Int'Unds'{}(),Lbl'UndsPipe'Int'Unds'{}(),Lbl'Unds'-Int'Unds'{}()), right{}(), smt-hook{}("div"), symbol'Kywd'{}(), terminals{}("010")] + symbol Lbl'Unds'dividesInt'UndsUnds'INT-COMMON'Unds'Bool'Unds'Int'Unds'Int{}(SortInt{}, SortInt{}) : SortBool{} [format{}("%1 %cdividesInt%r %2"), function{}(), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1318,19,1318,53)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("010")] + hooked-symbol Lbl'Unds'impliesBool'Unds'{}(SortBool{}, SortBool{}) : SortBool{} [format{}("%1 %cimpliesBool%r %2"), function{}(), functional{}(), group{}("boolOperation"), hook{}("BOOL.implies"), klabel{}("_impliesBool_"), left{}(Lbl'Unds'impliesBool'Unds'{}()), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1106,19,1106,153)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(Lbl'UndsEqlsSlshEqls'Bool'Unds'{}(),Lbl'UndsEqlsEqls'Bool'Unds'{}()), right{}(), smt-hook{}("=>"), symbol'Kywd'{}(), terminals{}("010"), total{}()] + hooked-symbol Lbl'Unds'in'UndsUnds'LIST'Unds'Bool'Unds'KItem'Unds'List{}(SortKItem{}, SortList{}) : SortBool{} [format{}("%1 %cin%r %2"), function{}(), functional{}(), hook{}("LIST.in"), klabel{}("_inList_"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1012,19,1012,97)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("010"), total{}()] + hooked-symbol Lbl'Unds'in'Unds'keys'LParUndsRParUnds'MAP'Unds'Bool'Unds'KItem'Unds'Map{}(SortKItem{}, SortMap{}) : SortBool{} [format{}("%1 %cin_keys%r %c(%r %2 %c)%r"), function{}(), functional{}(), hook{}("MAP.in_keys"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(357,19,357,89)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("01101"), total{}()] + hooked-symbol Lbl'Unds'modInt'Unds'{}(SortInt{}, SortInt{}) : SortInt{} [format{}("%1 %cmodInt%r %2"), function{}(), hook{}("INT.emod"), klabel{}("_modInt_"), left{}(Lbl'UndsStar'Int'Unds'{}(),Lbl'UndsPerc'Int'Unds'{}(),Lbl'Unds'divInt'Unds'{}(),Lbl'UndsSlsh'Int'Unds'{}(),Lbl'Unds'modInt'Unds'{}()), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1240,18,1240,122)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(Lbl'UndsPlus'Int'Unds'{}(),Lbl'Unds-GT--GT-'Int'Unds'{}(),Lbl'Unds'xorInt'Unds'{}(),Lbl'UndsAnd-'Int'Unds'{}(),Lbl'Unds-LT--LT-'Int'Unds'{}(),Lbl'UndsPipe'Int'Unds'{}(),Lbl'Unds'-Int'Unds'{}()), right{}(), smt-hook{}("mod"), symbol'Kywd'{}(), terminals{}("010")] + hooked-symbol Lbl'Unds'orBool'Unds'{}(SortBool{}, SortBool{}) : SortBool{} [format{}("%1 %corBool%r %2"), function{}(), functional{}(), group{}("boolOperation"), hook{}("BOOL.or"), klabel{}("_orBool_"), latex{}("{#1}\\vee_{\\scriptstyle\\it Bool}{#2}"), left{}(Lbl'Unds'orBool'Unds'{}()), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1104,19,1104,187)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(Lbl'UndsEqlsSlshEqls'Bool'Unds'{}(),Lbl'UndsEqlsEqls'Bool'Unds'{}()), right{}(), smt-hook{}("or"), symbol'Kywd'{}(), terminals{}("010"), total{}()] + hooked-symbol Lbl'Unds'orElseBool'Unds'{}(SortBool{}, SortBool{}) : SortBool{} [format{}("%1 %corElseBool%r %2"), function{}(), functional{}(), group{}("boolOperation"), hook{}("BOOL.orElse"), klabel{}("_orElseBool_"), left{}(Lbl'Unds'orElseBool'Unds'{}()), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1105,19,1105,151)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(Lbl'UndsEqlsSlshEqls'Bool'Unds'{}(),Lbl'UndsEqlsEqls'Bool'Unds'{}()), right{}(), smt-hook{}("or"), symbol'Kywd'{}(), terminals{}("010"), total{}()] + hooked-symbol Lbl'Unds'xorBool'Unds'{}(SortBool{}, SortBool{}) : SortBool{} [format{}("%1 %cxorBool%r %2"), function{}(), functional{}(), group{}("boolOperation"), hook{}("BOOL.xor"), klabel{}("_xorBool_"), left{}(Lbl'Unds'xorBool'Unds'{}()), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1103,19,1103,146)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(Lbl'UndsEqlsSlshEqls'Bool'Unds'{}(),Lbl'UndsEqlsEqls'Bool'Unds'{}()), right{}(), smt-hook{}("xor"), symbol'Kywd'{}(), terminals{}("010"), total{}()] + hooked-symbol Lbl'Unds'xorInt'Unds'{}(SortInt{}, SortInt{}) : SortInt{} [comm{}(), format{}("%1 %cxorInt%r %2"), function{}(), functional{}(), hook{}("INT.xor"), klabel{}("_xorInt_"), latex{}("{#1}\\mathrel{\\oplus_{\\scriptstyle\\it Int}}{#2}"), left{}(Lbl'Unds'xorInt'Unds'{}()), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1250,18,1250,190)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(Lbl'UndsPipe'Int'Unds'{}()), right{}(), smtlib{}("xorInt"), symbol'Kywd'{}(), terminals{}("010"), total{}()] + hooked-symbol Lbl'UndsPipe'-'-GT-Unds'{}(SortKItem{}, SortKItem{}) : SortMap{} [format{}("%1 %c|->%r %2"), function{}(), functional{}(), hook{}("MAP.element"), injective{}(), klabel{}("_|->_"), latex{}("{#1}\\mapsto{#2}"), left{}(Lbl'UndsPipe'-'-GT-Unds'{}()), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(257,18,257,151)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(Lbl'Stop'Map{}(),Lbl'Unds'Map'Unds'{}()), right{}(Lbl'UndsPipe'-'-GT-Unds'{}()), symbol'Kywd'{}(), terminals{}("010"), total{}()] + hooked-symbol Lbl'UndsPipe'Int'Unds'{}(SortInt{}, SortInt{}) : SortInt{} [comm{}(), format{}("%1 %c|Int%r %2"), function{}(), functional{}(), hook{}("INT.or"), klabel{}("_|Int_"), latex{}("{#1}\\mathrel{|_{\\scriptstyle\\it Int}}{#2}"), left{}(Lbl'UndsPipe'Int'Unds'{}()), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1252,18,1252,181)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), smtlib{}("orInt"), symbol'Kywd'{}(), terminals{}("010"), total{}()] + hooked-symbol Lbl'UndsPipe'Set'UndsUnds'SET'Unds'Set'Unds'Set'Unds'Set{}(SortSet{}, SortSet{}) : SortSet{} [comm{}(), format{}("%1 %c|Set%r %2"), function{}(), functional{}(), hook{}("SET.union"), left{}(Lbl'UndsPipe'Set'UndsUnds'SET'Unds'Set'Unds'Set'Unds'Set{}()), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(748,18,748,92)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("010"), total{}()] + hooked-symbol LblabsInt'LParUndsRParUnds'INT-COMMON'Unds'Int'Unds'Int{}(SortInt{}) : SortInt{} [format{}("%cabsInt%r %c(%r %1 %c)%r"), function{}(), functional{}(), hook{}("INT.abs"), klabel{}("absInt"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1269,18,1269,119)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), smt-hook{}("(ite (< #1 0) (- 0 #1) #1)"), terminals{}("1101"), total{}()] + hooked-symbol LblbitRangeInt'LParUndsCommUndsCommUndsRParUnds'INT-COMMON'Unds'Int'Unds'Int'Unds'Int'Unds'Int{}(SortInt{}, SortInt{}, SortInt{}) : SortInt{} [format{}("%cbitRangeInt%r %c(%r %1 %c,%r %2 %c,%r %3 %c)%r"), function{}(), hook{}("INT.bitRange"), klabel{}("bitRangeInt"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1294,18,1294,103)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("11010101")] + hooked-symbol LblcategoryChar'LParUndsRParUnds'STRING-COMMON'Unds'String'Unds'String{}(SortString{}) : SortString{} [format{}("%ccategoryChar%r %c(%r %1 %c)%r"), function{}(), hook{}("STRING.category"), klabel{}("categoryChar"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1858,21,1858,81)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("1101")] + hooked-symbol Lblchoice'LParUndsRParUnds'MAP'Unds'KItem'Unds'Map{}(SortMap{}) : SortKItem{} [format{}("%cchoice%r %c(%r %1 %c)%r"), function{}(), hook{}("MAP.choice"), klabel{}("Map:choice"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(393,20,393,101)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("1101")] + hooked-symbol Lblchoice'LParUndsRParUnds'SET'Unds'KItem'Unds'Set{}(SortSet{}) : SortKItem{} [format{}("%cchoice%r %c(%r %1 %c)%r"), function{}(), hook{}("SET.choice"), klabel{}("Set:choice"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(804,20,804,95)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("1101")] + hooked-symbol LblchrChar'LParUndsRParUnds'STRING-COMMON'Unds'String'Unds'Int{}(SortInt{}) : SortString{} [format{}("%cchrChar%r %c(%r %1 %c)%r"), function{}(), hook{}("STRING.chr"), klabel{}("chrChar"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1718,21,1718,70)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("1101")] + hooked-symbol LblcountAllOccurrences'LParUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String{}(SortString{}, SortString{}) : SortInt{} [format{}("%ccountAllOccurrences%r %c(... %r haystack: %1 %c,%r needle: %2 %c)%r"), function{}(), functional{}(), hook{}("STRING.countAllOccurrences"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1831,18,1831,146)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("110101"), total{}()] + hooked-symbol LbldirectionalityChar'LParUndsRParUnds'STRING-COMMON'Unds'String'Unds'String{}(SortString{}) : SortString{} [format{}("%cdirectionalityChar%r %c(%r %1 %c)%r"), function{}(), hook{}("STRING.directionality"), klabel{}("directionalityChar"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1859,21,1859,87)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("1101")] + hooked-symbol LblfillList'LParUndsCommUndsCommUndsCommUndsRParUnds'LIST'Unds'List'Unds'List'Unds'Int'Unds'Int'Unds'KItem{}(SortList{}, SortInt{}, SortInt{}, SortKItem{}) : SortList{} [format{}("%cfillList%r %c(%r %1 %c,%r %2 %c,%r %3 %c,%r %4 %c)%r"), function{}(), hook{}("LIST.fill"), klabel{}("fillList"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(993,19,993,100)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("1101010101")] + hooked-symbol LblfindChar'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String'Unds'Int{}(SortString{}, SortString{}, SortInt{}) : SortInt{} [format{}("%cfindChar%r %c(... %r haystack: %1 %c,%r needles: %2 %c,%r index: %3 %c)%r"), function{}(), hook{}("STRING.findChar"), klabel{}("findChar"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1755,18,1755,116)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("11010101")] + hooked-symbol LblfindString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String'Unds'Int{}(SortString{}, SortString{}, SortInt{}) : SortInt{} [format{}("%cfindString%r %c(... %r haystack: %1 %c,%r needle: %2 %c,%r index: %3 %c)%r"), function{}(), hook{}("STRING.find"), klabel{}("findString"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1744,18,1744,111)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("11010101")] + symbol LblfreshInt'LParUndsRParUnds'INT'Unds'Int'Unds'Int{}(SortInt{}) : SortInt{} [format{}("%cfreshInt%r %c(%r %1 %c)%r"), freshGenerator{}(), function{}(), functional{}(), klabel{}("freshInt"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1432,18,1432,77)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), private{}(), right{}(), terminals{}("1101"), total{}()] + symbol LblgetGeneratedCounterCell{}(SortGeneratedTopCell{}) : SortGeneratedCounterCell{} [format{}("%cgetGeneratedCounterCell%r %c(%r %1 %c)%r"), function{}(), left{}(), priorities{}(), right{}(), terminals{}("1101")] + symbol Lblgo'LParUndsRParUnds'UNICODE'Unds'String'Unds'String{}(SortString{}) : SortString{} [format{}("%cgo%r %c(%r %1 %c)%r"), function{}(), klabel{}("go"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(19,23,19,44)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k-test/unicode.k)"), priorities{}(), right{}(), terminals{}("1101")] + symbol LblgoAll'LParUndsRParUnds'UNICODE'Unds'Strings'Unds'Strings{}(SortStrings{}) : SortStrings{} [format{}("%cgoAll%r %c(%r %1 %c)%r"), function{}(), klabel{}("goAll"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(18,24,18,49)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k-test/unicode.k)"), priorities{}(), right{}(), terminals{}("1101")] + symbol LblinitGeneratedCounterCell{}() : SortGeneratedCounterCell{} [format{}("%cinitGeneratedCounterCell%r"), function{}(), initializer{}(), left{}(), noThread{}(), priorities{}(), right{}(), terminals{}("1")] + symbol LblinitGeneratedTopCell{}(SortMap{}) : SortGeneratedTopCell{} [format{}("%cinitGeneratedTopCell%r %c(%r %1 %c)%r"), function{}(), initializer{}(), left{}(), noThread{}(), priorities{}(), right{}(), terminals{}("1101")] + symbol LblinitKCell{}(SortMap{}) : SortKCell{} [format{}("%cinitKCell%r %c(%r %1 %c)%r"), function{}(), initializer{}(), left{}(), noThread{}(), priorities{}(), right{}(), terminals{}("1101")] + symbol LblinitOutCell{}() : SortOutCell{} [format{}("%cinitOutCell%r"), function{}(), initializer{}(), left{}(), noThread{}(), priorities{}(), right{}(), terminals{}("1")] + hooked-symbol LblintersectSet'LParUndsCommUndsRParUnds'SET'Unds'Set'Unds'Set'Unds'Set{}(SortSet{}, SortSet{}) : SortSet{} [comm{}(), format{}("%cintersectSet%r %c(%r %1 %c,%r %2 %c)%r"), function{}(), functional{}(), hook{}("SET.intersection"), klabel{}("intersectSet"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(759,18,759,90)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("110101"), total{}()] + symbol LblisBool{}(SortK{}) : SortBool{} [format{}("%cisBool%r %c(%r %1 %c)%r"), function{}(), functional{}(), left{}(), predicate{}("Bool"), priorities{}(), right{}(), terminals{}("1101"), total{}()] + symbol LblisFloat{}(SortK{}) : SortBool{} [format{}("%cisFloat%r %c(%r %1 %c)%r"), function{}(), functional{}(), left{}(), predicate{}("Float"), priorities{}(), right{}(), terminals{}("1101"), total{}()] + symbol LblisGeneratedCounterCell{}(SortK{}) : SortBool{} [format{}("%cisGeneratedCounterCell%r %c(%r %1 %c)%r"), function{}(), functional{}(), left{}(), predicate{}("GeneratedCounterCell"), priorities{}(), right{}(), terminals{}("1101"), total{}()] + symbol LblisGeneratedTopCell{}(SortK{}) : SortBool{} [format{}("%cisGeneratedTopCell%r %c(%r %1 %c)%r"), function{}(), functional{}(), left{}(), predicate{}("GeneratedTopCell"), priorities{}(), right{}(), terminals{}("1101"), total{}()] + symbol LblisGeneratedTopCellFragment{}(SortK{}) : SortBool{} [format{}("%cisGeneratedTopCellFragment%r %c(%r %1 %c)%r"), function{}(), functional{}(), left{}(), predicate{}("GeneratedTopCellFragment"), priorities{}(), right{}(), terminals{}("1101"), total{}()] + symbol LblisInt{}(SortK{}) : SortBool{} [format{}("%cisInt%r %c(%r %1 %c)%r"), function{}(), functional{}(), left{}(), predicate{}("Int"), priorities{}(), right{}(), terminals{}("1101"), total{}()] + symbol LblisK{}(SortK{}) : SortBool{} [format{}("%cisK%r %c(%r %1 %c)%r"), function{}(), functional{}(), left{}(), predicate{}("K"), priorities{}(), right{}(), terminals{}("1101"), total{}()] + symbol LblisKCell{}(SortK{}) : SortBool{} [format{}("%cisKCell%r %c(%r %1 %c)%r"), function{}(), functional{}(), left{}(), predicate{}("KCell"), priorities{}(), right{}(), terminals{}("1101"), total{}()] + symbol LblisKCellOpt{}(SortK{}) : SortBool{} [format{}("%cisKCellOpt%r %c(%r %1 %c)%r"), function{}(), functional{}(), left{}(), predicate{}("KCellOpt"), priorities{}(), right{}(), terminals{}("1101"), total{}()] + symbol LblisKConfigVar{}(SortK{}) : SortBool{} [format{}("%cisKConfigVar%r %c(%r %1 %c)%r"), function{}(), functional{}(), left{}(), predicate{}("KConfigVar"), priorities{}(), right{}(), terminals{}("1101"), total{}()] + symbol LblisKItem{}(SortK{}) : SortBool{} [format{}("%cisKItem%r %c(%r %1 %c)%r"), function{}(), functional{}(), left{}(), predicate{}("KItem"), priorities{}(), right{}(), terminals{}("1101"), total{}()] + symbol LblisList{}(SortK{}) : SortBool{} [format{}("%cisList%r %c(%r %1 %c)%r"), function{}(), functional{}(), left{}(), predicate{}("List"), priorities{}(), right{}(), terminals{}("1101"), total{}()] + symbol LblisMap{}(SortK{}) : SortBool{} [format{}("%cisMap%r %c(%r %1 %c)%r"), function{}(), functional{}(), left{}(), predicate{}("Map"), priorities{}(), right{}(), terminals{}("1101"), total{}()] + symbol LblisOutCell{}(SortK{}) : SortBool{} [format{}("%cisOutCell%r %c(%r %1 %c)%r"), function{}(), functional{}(), left{}(), predicate{}("OutCell"), priorities{}(), right{}(), terminals{}("1101"), total{}()] + symbol LblisOutCellOpt{}(SortK{}) : SortBool{} [format{}("%cisOutCellOpt%r %c(%r %1 %c)%r"), function{}(), functional{}(), left{}(), predicate{}("OutCellOpt"), priorities{}(), right{}(), terminals{}("1101"), total{}()] + symbol LblisSet{}(SortK{}) : SortBool{} [format{}("%cisSet%r %c(%r %1 %c)%r"), function{}(), functional{}(), left{}(), predicate{}("Set"), priorities{}(), right{}(), terminals{}("1101"), total{}()] + symbol LblisString{}(SortK{}) : SortBool{} [format{}("%cisString%r %c(%r %1 %c)%r"), function{}(), functional{}(), left{}(), predicate{}("String"), priorities{}(), right{}(), terminals{}("1101"), total{}()] + symbol LblisStrings{}(SortK{}) : SortBool{} [format{}("%cisStrings%r %c(%r %1 %c)%r"), function{}(), functional{}(), left{}(), predicate{}("Strings"), priorities{}(), right{}(), terminals{}("1101"), total{}()] + hooked-symbol Lblkeys'LParUndsRParUnds'MAP'Unds'Set'Unds'Map{}(SortMap{}) : SortSet{} [format{}("%ckeys%r %c(%r %1 %c)%r"), function{}(), functional{}(), hook{}("MAP.keys"), klabel{}("keys"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(341,18,341,82)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("1101"), total{}()] + hooked-symbol Lblkeys'Unds'list'LParUndsRParUnds'MAP'Unds'List'Unds'Map{}(SortMap{}) : SortList{} [format{}("%ckeys_list%r %c(%r %1 %c)%r"), function{}(), hook{}("MAP.keys_list"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(349,19,349,80)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("1101")] + hooked-symbol LbllengthString'LParUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String{}(SortString{}) : SortInt{} [format{}("%clengthString%r %c(%r %1 %c)%r"), function{}(), functional{}(), hook{}("STRING.length"), klabel{}("lengthString"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1709,18,1709,80)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("1101"), total{}()] + hooked-symbol Lbllog2Int'LParUndsRParUnds'INT-COMMON'Unds'Int'Unds'Int{}(SortInt{}) : SortInt{} [format{}("%clog2Int%r %c(%r %1 %c)%r"), function{}(), hook{}("INT.log2"), klabel{}("log2Int"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1280,18,1280,75)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("1101")] + hooked-symbol LblmakeList'LParUndsCommUndsRParUnds'LIST'Unds'List'Unds'Int'Unds'KItem{}(SortInt{}, SortKItem{}) : SortList{} [format{}("%cmakeList%r %c(... %r length: %1 %c,%r value: %2 %c)%r"), function{}(), hook{}("LIST.make"), klabel{}("makeList"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(974,19,974,82)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("110101")] + hooked-symbol LblmaxInt'LParUndsCommUndsRParUnds'INT-COMMON'Unds'Int'Unds'Int'Unds'Int{}(SortInt{}, SortInt{}) : SortInt{} [format{}("%cmaxInt%r %c(%r %1 %c,%r %2 %c)%r"), function{}(), functional{}(), hook{}("INT.max"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1261,18,1261,114)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), smt-hook{}("(ite (< #1 #2) #2 #1)"), terminals{}("110101"), total{}()] + hooked-symbol LblminInt'LParUndsCommUndsRParUnds'INT-COMMON'Unds'Int'Unds'Int'Unds'Int{}(SortInt{}, SortInt{}) : SortInt{} [format{}("%cminInt%r %c(%r %1 %c,%r %2 %c)%r"), function{}(), functional{}(), hook{}("INT.min"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1260,18,1260,114)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), smt-hook{}("(ite (< #1 #2) #1 #2)"), terminals{}("110101"), total{}()] + hooked-symbol LblnewUUID'Unds'STRING-COMMON'Unds'String{}() : SortString{} [format{}("%cnewUUID%r"), function{}(), hook{}("STRING.uuid"), impure{}(), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1861,21,1861,68)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("1")] + symbol LblnoKCell{}() : SortKCellOpt{} [cellOptAbsent{}("KCell"), constructor{}(), format{}("%cnoKCell%r"), functional{}(), injective{}(), left{}(), priorities{}(), right{}(), terminals{}("1")] + symbol LblnoOutCell{}() : SortOutCellOpt{} [cellOptAbsent{}("OutCell"), constructor{}(), format{}("%cnoOutCell%r"), functional{}(), injective{}(), left{}(), priorities{}(), right{}(), terminals{}("1")] + hooked-symbol LblnotBool'Unds'{}(SortBool{}) : SortBool{} [format{}("%cnotBool%r %1"), function{}(), functional{}(), group{}("boolOperation"), hook{}("BOOL.not"), klabel{}("notBool_"), latex{}("\\neg_{\\scriptstyle\\it Bool}{#1}"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1100,19,1100,179)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(Lbl'Unds'orElseBool'Unds'{}(),Lbl'Unds'orBool'Unds'{}(),Lbl'UndsEqlsSlshEqls'Bool'Unds'{}(),Lbl'Unds'andThenBool'Unds'{}(),Lbl'Unds'impliesBool'Unds'{}(),Lbl'UndsEqlsEqls'Bool'Unds'{}(),Lbl'Unds'andBool'Unds'{}(),Lbl'Unds'xorBool'Unds'{}()), right{}(), smt-hook{}("not"), symbol'Kywd'{}(), terminals{}("10"), total{}()] + hooked-symbol LblordChar'LParUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String{}(SortString{}) : SortInt{} [format{}("%cordChar%r %c(%r %1 %c)%r"), function{}(), hook{}("STRING.ord"), klabel{}("ordChar"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1719,18,1719,70)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("1101")] + symbol Lblproject'Coln'Bool{}(SortK{}) : SortBool{} [format{}("%cproject:Bool%r %c(%r %1 %c)%r"), function{}(), left{}(), priorities{}(), projection{}(), right{}(), terminals{}("1101")] + symbol Lblproject'Coln'Float{}(SortK{}) : SortFloat{} [format{}("%cproject:Float%r %c(%r %1 %c)%r"), function{}(), left{}(), priorities{}(), projection{}(), right{}(), terminals{}("1101")] + symbol Lblproject'Coln'GeneratedCounterCell{}(SortK{}) : SortGeneratedCounterCell{} [format{}("%cproject:GeneratedCounterCell%r %c(%r %1 %c)%r"), function{}(), left{}(), priorities{}(), projection{}(), right{}(), terminals{}("1101")] + symbol Lblproject'Coln'GeneratedTopCell{}(SortK{}) : SortGeneratedTopCell{} [format{}("%cproject:GeneratedTopCell%r %c(%r %1 %c)%r"), function{}(), left{}(), priorities{}(), projection{}(), right{}(), terminals{}("1101")] + symbol Lblproject'Coln'GeneratedTopCellFragment{}(SortK{}) : SortGeneratedTopCellFragment{} [format{}("%cproject:GeneratedTopCellFragment%r %c(%r %1 %c)%r"), function{}(), left{}(), priorities{}(), projection{}(), right{}(), terminals{}("1101")] + symbol Lblproject'Coln'Int{}(SortK{}) : SortInt{} [format{}("%cproject:Int%r %c(%r %1 %c)%r"), function{}(), left{}(), priorities{}(), projection{}(), right{}(), terminals{}("1101")] + symbol Lblproject'Coln'K{}(SortK{}) : SortK{} [format{}("%cproject:K%r %c(%r %1 %c)%r"), function{}(), left{}(), priorities{}(), projection{}(), right{}(), terminals{}("1101")] + symbol Lblproject'Coln'KCell{}(SortK{}) : SortKCell{} [format{}("%cproject:KCell%r %c(%r %1 %c)%r"), function{}(), left{}(), priorities{}(), projection{}(), right{}(), terminals{}("1101")] + symbol Lblproject'Coln'KCellOpt{}(SortK{}) : SortKCellOpt{} [format{}("%cproject:KCellOpt%r %c(%r %1 %c)%r"), function{}(), left{}(), priorities{}(), projection{}(), right{}(), terminals{}("1101")] + symbol Lblproject'Coln'KItem{}(SortK{}) : SortKItem{} [format{}("%cproject:KItem%r %c(%r %1 %c)%r"), function{}(), left{}(), priorities{}(), projection{}(), right{}(), terminals{}("1101")] + symbol Lblproject'Coln'List{}(SortK{}) : SortList{} [format{}("%cproject:List%r %c(%r %1 %c)%r"), function{}(), left{}(), priorities{}(), projection{}(), right{}(), terminals{}("1101")] + symbol Lblproject'Coln'Map{}(SortK{}) : SortMap{} [format{}("%cproject:Map%r %c(%r %1 %c)%r"), function{}(), left{}(), priorities{}(), projection{}(), right{}(), terminals{}("1101")] + symbol Lblproject'Coln'OutCell{}(SortK{}) : SortOutCell{} [format{}("%cproject:OutCell%r %c(%r %1 %c)%r"), function{}(), left{}(), priorities{}(), projection{}(), right{}(), terminals{}("1101")] + symbol Lblproject'Coln'OutCellOpt{}(SortK{}) : SortOutCellOpt{} [format{}("%cproject:OutCellOpt%r %c(%r %1 %c)%r"), function{}(), left{}(), priorities{}(), projection{}(), right{}(), terminals{}("1101")] + symbol Lblproject'Coln'Set{}(SortK{}) : SortSet{} [format{}("%cproject:Set%r %c(%r %1 %c)%r"), function{}(), left{}(), priorities{}(), projection{}(), right{}(), terminals{}("1101")] + symbol Lblproject'Coln'String{}(SortK{}) : SortString{} [format{}("%cproject:String%r %c(%r %1 %c)%r"), function{}(), left{}(), priorities{}(), projection{}(), right{}(), terminals{}("1101")] + symbol Lblproject'Coln'Strings{}(SortK{}) : SortStrings{} [format{}("%cproject:Strings%r %c(%r %1 %c)%r"), function{}(), left{}(), priorities{}(), projection{}(), right{}(), terminals{}("1101")] + hooked-symbol LblrandInt'LParUndsRParUnds'INT-COMMON'Unds'Int'Unds'Int{}(SortInt{}) : SortInt{} [format{}("%crandInt%r %c(%r %1 %c)%r"), function{}(), hook{}("INT.rand"), impure{}(), klabel{}("randInt"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1328,18,1328,65)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("1101")] + hooked-symbol LblremoveAll'LParUndsCommUndsRParUnds'MAP'Unds'Map'Unds'Map'Unds'Set{}(SortMap{}, SortSet{}) : SortMap{} [format{}("%cremoveAll%r %c(%r %1 %c,%r %2 %c)%r"), function{}(), functional{}(), hook{}("MAP.removeAll"), klabel{}("removeAll"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(333,18,333,87)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("110101"), total{}()] + hooked-symbol Lblreplace'LParUndsCommUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'String'Unds'String'Unds'Int{}(SortString{}, SortString{}, SortString{}, SortInt{}) : SortString{} [format{}("%creplace%r %c(... %r haystack: %1 %c,%r needle: %2 %c,%r replacement: %3 %c,%r times: %4 %c)%r"), function{}(), hook{}("STRING.replace"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1829,21,1829,146)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("1101010101")] + hooked-symbol LblreplaceAll'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'String'Unds'String{}(SortString{}, SortString{}, SortString{}) : SortString{} [format{}("%creplaceAll%r %c(... %r haystack: %1 %c,%r needle: %2 %c,%r replacement: %3 %c)%r"), function{}(), functional{}(), hook{}("STRING.replaceAll"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1828,21,1828,149)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("11010101"), total{}()] + hooked-symbol LblreplaceFirst'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'String'Unds'String{}(SortString{}, SortString{}, SortString{}) : SortString{} [format{}("%creplaceFirst%r %c(... %r haystack: %1 %c,%r needle: %2 %c,%r replacement: %3 %c)%r"), function{}(), functional{}(), hook{}("STRING.replaceFirst"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1830,21,1830,151)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("11010101"), total{}()] + hooked-symbol LblrfindChar'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String'Unds'Int{}(SortString{}, SortString{}, SortInt{}) : SortInt{} [format{}("%crfindChar%r %c(... %r haystack: %1 %c,%r needles: %2 %c,%r index: %3 %c)%r"), function{}(), hook{}("STRING.rfindChar"), klabel{}("rfindChar"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1756,18,1756,117)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("11010101")] + hooked-symbol LblrfindString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String'Unds'Int{}(SortString{}, SortString{}, SortInt{}) : SortInt{} [format{}("%crfindString%r %c(... %r haystack: %1 %c,%r needle: %2 %c,%r index: %3 %c)%r"), function{}(), hook{}("STRING.rfind"), klabel{}("rfindString"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1745,18,1745,112)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("11010101")] + hooked-symbol LblsignExtendBitRangeInt'LParUndsCommUndsCommUndsRParUnds'INT-COMMON'Unds'Int'Unds'Int'Unds'Int'Unds'Int{}(SortInt{}, SortInt{}, SortInt{}) : SortInt{} [format{}("%csignExtendBitRangeInt%r %c(%r %1 %c,%r %2 %c,%r %3 %c)%r"), function{}(), hook{}("INT.signExtendBitRange"), klabel{}("signExtendBitRangeInt"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1295,18,1295,113)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("11010101")] + hooked-symbol Lblsize'LParUndsRParUnds'LIST'Unds'Int'Unds'List{}(SortList{}) : SortInt{} [format{}("%csize%r %c(%r %1 %c)%r"), function{}(), functional{}(), hook{}("LIST.size"), klabel{}("sizeList"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1020,18,1020,117)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), smtlib{}("smt_seq_len"), terminals{}("1101"), total{}()] + hooked-symbol Lblsize'LParUndsRParUnds'MAP'Unds'Int'Unds'Map{}(SortMap{}) : SortInt{} [format{}("%csize%r %c(%r %1 %c)%r"), function{}(), functional{}(), hook{}("MAP.size"), klabel{}("sizeMap"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(373,18,373,99)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("1101"), total{}()] + hooked-symbol Lblsize'LParUndsRParUnds'SET'Unds'Int'Unds'Set{}(SortSet{}) : SortInt{} [format{}("%csize%r %c(%r %1 %c)%r"), function{}(), functional{}(), hook{}("SET.size"), klabel{}("size"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(794,18,794,76)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("1101"), total{}()] + hooked-symbol LblsrandInt'LParUndsRParUnds'INT-COMMON'Unds'K'Unds'Int{}(SortInt{}) : SortK{} [format{}("%csrandInt%r %c(%r %1 %c)%r"), function{}(), hook{}("INT.srand"), impure{}(), klabel{}("srandInt"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1329,16,1329,65)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("1101")] + hooked-symbol LblsubstrString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'Int'Unds'Int{}(SortString{}, SortInt{}, SortInt{}) : SortString{} [format{}("%csubstrString%r %c(%r %1 %c,%r %2 %c,%r %3 %c)%r"), function{}(), functional{}(), hook{}("STRING.substr"), klabel{}("substrString"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1734,21,1734,117)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("11010101"), total{}()] + hooked-symbol LblupdateList'LParUndsCommUndsCommUndsRParUnds'LIST'Unds'List'Unds'List'Unds'Int'Unds'List{}(SortList{}, SortInt{}, SortList{}) : SortList{} [format{}("%cupdateList%r %c(... %r dest: %1 %c,%r index: %2 %c,%r src: %3 %c)%r"), function{}(), hook{}("LIST.updateAll"), klabel{}("updateList"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(984,19,984,97)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("11010101")] + hooked-symbol LblupdateMap'LParUndsCommUndsRParUnds'MAP'Unds'Map'Unds'Map'Unds'Map{}(SortMap{}, SortMap{}) : SortMap{} [format{}("%cupdateMap%r %c(%r %1 %c,%r %2 %c)%r"), function{}(), functional{}(), hook{}("MAP.updateAll"), klabel{}("updateMap"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(324,18,324,87)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("110101"), total{}()] + hooked-symbol Lblvalues'LParUndsRParUnds'MAP'Unds'List'Unds'Map{}(SortMap{}) : SortList{} [format{}("%cvalues%r %c(%r %1 %c)%r"), function{}(), hook{}("MAP.values"), klabel{}("values"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(365,19,365,77)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(), right{}(), terminals{}("1101")] + hooked-symbol Lbl'Tild'Int'Unds'{}(SortInt{}) : SortInt{} [format{}("%c~Int%r %1"), function{}(), functional{}(), hook{}("INT.not"), klabel{}("~Int_"), latex{}("\\mathop{\\sim_{\\scriptstyle\\it Int}}{#1}"), left{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1228,18,1228,168)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), priorities{}(Lbl'UndsPlus'Int'Unds'{}(),Lbl'Unds'divInt'Unds'{}(),Lbl'UndsPerc'Int'Unds'{}(),Lbl'Unds-GT--GT-'Int'Unds'{}(),Lbl'Unds'xorInt'Unds'{}(),Lbl'UndsSlsh'Int'Unds'{}(),Lbl'UndsAnd-'Int'Unds'{}(),Lbl'UndsXor-'Int'Unds'{}(),Lbl'Unds-LT--LT-'Int'Unds'{}(),Lbl'UndsStar'Int'Unds'{}(),Lbl'UndsPipe'Int'Unds'{}(),Lbl'Unds'modInt'Unds'{}(),Lbl'UndsXor-Perc'Int'UndsUnds'{}(),Lbl'Unds'-Int'Unds'{}()), right{}(), smtlib{}("notInt"), symbol'Kywd'{}(), terminals{}("10"), total{}()] + +// generated axioms + axiom{R} \exists{R} (Val:SortKItem{}, \equals{SortKItem{}, R} (Val:SortKItem{}, inj{SortString{}, SortKItem{}} (From:SortString{}))) [subsort{SortString{}, SortKItem{}}()] // subsort + axiom{R} \exists{R} (Val:SortKItem{}, \equals{SortKItem{}, R} (Val:SortKItem{}, inj{SortKCellOpt{}, SortKItem{}} (From:SortKCellOpt{}))) [subsort{SortKCellOpt{}, SortKItem{}}()] // subsort + axiom{R} \exists{R} (Val:SortKItem{}, \equals{SortKItem{}, R} (Val:SortKItem{}, inj{SortKCell{}, SortKItem{}} (From:SortKCell{}))) [subsort{SortKCell{}, SortKItem{}}()] // subsort + axiom{R} \exists{R} (Val:SortKItem{}, \equals{SortKItem{}, R} (Val:SortKItem{}, inj{SortOutCell{}, SortKItem{}} (From:SortOutCell{}))) [subsort{SortOutCell{}, SortKItem{}}()] // subsort + axiom{R} \exists{R} (Val:SortKCellOpt{}, \equals{SortKCellOpt{}, R} (Val:SortKCellOpt{}, inj{SortKCell{}, SortKCellOpt{}} (From:SortKCell{}))) [subsort{SortKCell{}, SortKCellOpt{}}()] // subsort + axiom{R} \exists{R} (Val:SortKItem{}, \equals{SortKItem{}, R} (Val:SortKItem{}, inj{SortSet{}, SortKItem{}} (From:SortSet{}))) [subsort{SortSet{}, SortKItem{}}()] // subsort + axiom{R} \exists{R} (Val:SortKItem{}, \equals{SortKItem{}, R} (Val:SortKItem{}, inj{SortGeneratedCounterCell{}, SortKItem{}} (From:SortGeneratedCounterCell{}))) [subsort{SortGeneratedCounterCell{}, SortKItem{}}()] // subsort + axiom{R} \exists{R} (Val:SortOutCellOpt{}, \equals{SortOutCellOpt{}, R} (Val:SortOutCellOpt{}, inj{SortOutCell{}, SortOutCellOpt{}} (From:SortOutCell{}))) [subsort{SortOutCell{}, SortOutCellOpt{}}()] // subsort + axiom{R} \exists{R} (Val:SortKItem{}, \equals{SortKItem{}, R} (Val:SortKItem{}, inj{SortGeneratedTopCell{}, SortKItem{}} (From:SortGeneratedTopCell{}))) [subsort{SortGeneratedTopCell{}, SortKItem{}}()] // subsort + axiom{R} \exists{R} (Val:SortKItem{}, \equals{SortKItem{}, R} (Val:SortKItem{}, inj{SortOutCellOpt{}, SortKItem{}} (From:SortOutCellOpt{}))) [subsort{SortOutCellOpt{}, SortKItem{}}()] // subsort + axiom{R} \exists{R} (Val:SortKItem{}, \equals{SortKItem{}, R} (Val:SortKItem{}, inj{SortList{}, SortKItem{}} (From:SortList{}))) [subsort{SortList{}, SortKItem{}}()] // subsort + axiom{R} \exists{R} (Val:SortKItem{}, \equals{SortKItem{}, R} (Val:SortKItem{}, inj{SortKConfigVar{}, SortKItem{}} (From:SortKConfigVar{}))) [subsort{SortKConfigVar{}, SortKItem{}}()] // subsort + axiom{R} \exists{R} (Val:SortKItem{}, \equals{SortKItem{}, R} (Val:SortKItem{}, inj{SortFloat{}, SortKItem{}} (From:SortFloat{}))) [subsort{SortFloat{}, SortKItem{}}()] // subsort + axiom{R} \exists{R} (Val:SortKItem{}, \equals{SortKItem{}, R} (Val:SortKItem{}, inj{SortBool{}, SortKItem{}} (From:SortBool{}))) [subsort{SortBool{}, SortKItem{}}()] // subsort + axiom{R} \exists{R} (Val:SortKItem{}, \equals{SortKItem{}, R} (Val:SortKItem{}, inj{SortInt{}, SortKItem{}} (From:SortInt{}))) [subsort{SortInt{}, SortKItem{}}()] // subsort + axiom{R} \exists{R} (Val:SortKItem{}, \equals{SortKItem{}, R} (Val:SortKItem{}, inj{SortGeneratedTopCellFragment{}, SortKItem{}} (From:SortGeneratedTopCellFragment{}))) [subsort{SortGeneratedTopCellFragment{}, SortKItem{}}()] // subsort + axiom{R} \exists{R} (Val:SortKItem{}, \equals{SortKItem{}, R} (Val:SortKItem{}, inj{SortMap{}, SortKItem{}} (From:SortMap{}))) [subsort{SortMap{}, SortKItem{}}()] // subsort + axiom{R} \exists{R} (Val:SortKItem{}, \equals{SortKItem{}, R} (Val:SortKItem{}, inj{SortStrings{}, SortKItem{}} (From:SortStrings{}))) [subsort{SortStrings{}, SortKItem{}}()] // subsort + axiom{R, SortSort} \exists{R} (Val:SortSort, \equals{SortSort, R} (Val:SortSort, Lbl'Hash'if'UndsHash'then'UndsHash'else'UndsHash'fi'Unds'K-EQUAL-SYNTAX'Unds'Sort'Unds'Bool'Unds'Sort'Unds'Sort{SortSort}(K0:SortBool{}, K1:SortSort, K2:SortSort))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortList{}, \equals{SortList{}, R} (Val:SortList{}, Lbl'Stop'List{}())) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortStrings{}, \equals{SortStrings{}, R} (Val:SortStrings{}, Lbl'Stop'List'LBraQuotUndsCommUndsUnds'UNICODE-SYNTAX'Unds'Strings'Unds'String'Unds'Strings'QuotRBraUnds'Strings{}())) [functional{}()] // functional + axiom{}\not{SortStrings{}} (\and{SortStrings{}} (Lbl'Stop'List'LBraQuotUndsCommUndsUnds'UNICODE-SYNTAX'Unds'Strings'Unds'String'Unds'Strings'QuotRBraUnds'Strings{}(), Lbl'UndsCommUndsUnds'UNICODE-SYNTAX'Unds'Strings'Unds'String'Unds'Strings{}(Y0:SortString{}, Y1:SortStrings{}))) [constructor{}()] // no confusion different constructors + axiom{R} \exists{R} (Val:SortMap{}, \equals{SortMap{}, R} (Val:SortMap{}, Lbl'Stop'Map{}())) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortSet{}, \equals{SortSet{}, R} (Val:SortSet{}, Lbl'Stop'Set{}())) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortGeneratedCounterCell{}, \equals{SortGeneratedCounterCell{}, R} (Val:SortGeneratedCounterCell{}, Lbl'-LT-'generatedCounter'-GT-'{}(K0:SortInt{}))) [functional{}()] // functional + axiom{}\implies{SortGeneratedCounterCell{}} (\and{SortGeneratedCounterCell{}} (Lbl'-LT-'generatedCounter'-GT-'{}(X0:SortInt{}), Lbl'-LT-'generatedCounter'-GT-'{}(Y0:SortInt{})), Lbl'-LT-'generatedCounter'-GT-'{}(\and{SortInt{}} (X0:SortInt{}, Y0:SortInt{}))) [constructor{}()] // no confusion same constructor + axiom{R} \exists{R} (Val:SortGeneratedTopCell{}, \equals{SortGeneratedTopCell{}, R} (Val:SortGeneratedTopCell{}, Lbl'-LT-'generatedTop'-GT-'{}(K0:SortKCell{}, K1:SortOutCell{}, K2:SortGeneratedCounterCell{}))) [functional{}()] // functional + axiom{}\implies{SortGeneratedTopCell{}} (\and{SortGeneratedTopCell{}} (Lbl'-LT-'generatedTop'-GT-'{}(X0:SortKCell{}, X1:SortOutCell{}, X2:SortGeneratedCounterCell{}), Lbl'-LT-'generatedTop'-GT-'{}(Y0:SortKCell{}, Y1:SortOutCell{}, Y2:SortGeneratedCounterCell{})), Lbl'-LT-'generatedTop'-GT-'{}(\and{SortKCell{}} (X0:SortKCell{}, Y0:SortKCell{}), \and{SortOutCell{}} (X1:SortOutCell{}, Y1:SortOutCell{}), \and{SortGeneratedCounterCell{}} (X2:SortGeneratedCounterCell{}, Y2:SortGeneratedCounterCell{}))) [constructor{}()] // no confusion same constructor + axiom{R} \exists{R} (Val:SortGeneratedTopCellFragment{}, \equals{SortGeneratedTopCellFragment{}, R} (Val:SortGeneratedTopCellFragment{}, Lbl'-LT-'generatedTop'-GT-'-fragment{}(K0:SortKCellOpt{}, K1:SortOutCellOpt{}))) [functional{}()] // functional + axiom{}\implies{SortGeneratedTopCellFragment{}} (\and{SortGeneratedTopCellFragment{}} (Lbl'-LT-'generatedTop'-GT-'-fragment{}(X0:SortKCellOpt{}, X1:SortOutCellOpt{}), Lbl'-LT-'generatedTop'-GT-'-fragment{}(Y0:SortKCellOpt{}, Y1:SortOutCellOpt{})), Lbl'-LT-'generatedTop'-GT-'-fragment{}(\and{SortKCellOpt{}} (X0:SortKCellOpt{}, Y0:SortKCellOpt{}), \and{SortOutCellOpt{}} (X1:SortOutCellOpt{}, Y1:SortOutCellOpt{}))) [constructor{}()] // no confusion same constructor + axiom{R} \exists{R} (Val:SortKCell{}, \equals{SortKCell{}, R} (Val:SortKCell{}, Lbl'-LT-'k'-GT-'{}(K0:SortK{}))) [functional{}()] // functional + axiom{}\implies{SortKCell{}} (\and{SortKCell{}} (Lbl'-LT-'k'-GT-'{}(X0:SortK{}), Lbl'-LT-'k'-GT-'{}(Y0:SortK{})), Lbl'-LT-'k'-GT-'{}(\and{SortK{}} (X0:SortK{}, Y0:SortK{}))) [constructor{}()] // no confusion same constructor + axiom{R} \exists{R} (Val:SortOutCell{}, \equals{SortOutCell{}, R} (Val:SortOutCell{}, Lbl'-LT-'out'-GT-'{}(K0:SortStrings{}))) [functional{}()] // functional + axiom{}\implies{SortOutCell{}} (\and{SortOutCell{}} (Lbl'-LT-'out'-GT-'{}(X0:SortStrings{}), Lbl'-LT-'out'-GT-'{}(Y0:SortStrings{})), Lbl'-LT-'out'-GT-'{}(\and{SortStrings{}} (X0:SortStrings{}, Y0:SortStrings{}))) [constructor{}()] // no confusion same constructor + axiom{R} \exists{R} (Val:SortString{}, \equals{SortString{}, R} (Val:SortString{}, LblBool2String'LParUndsRParUnds'STRING-COMMON'Unds'String'Unds'Bool{}(K0:SortBool{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortString{}, \equals{SortString{}, R} (Val:SortString{}, LblFloat2String'LParUndsRParUnds'STRING-COMMON'Unds'String'Unds'Float{}(K0:SortFloat{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortString{}, \equals{SortString{}, R} (Val:SortString{}, LblInt2String'LParUndsRParUnds'STRING-COMMON'Unds'String'Unds'Int{}(K0:SortInt{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortList{}, \equals{SortList{}, R} (Val:SortList{}, LblListItem{}(K0:SortKItem{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortMap{}, \equals{SortMap{}, R} (Val:SortMap{}, LblMap'Coln'update{}(K0:SortMap{}, K1:SortKItem{}, K2:SortKItem{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortSet{}, \equals{SortSet{}, R} (Val:SortSet{}, LblSet'Coln'difference{}(K0:SortSet{}, K1:SortSet{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, LblSet'Coln'in{}(K0:SortKItem{}, K1:SortSet{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortSet{}, \equals{SortSet{}, R} (Val:SortSet{}, LblSetItem{}(K0:SortKItem{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortInt{}, \equals{SortInt{}, R} (Val:SortInt{}, Lbl'UndsAnd-'Int'Unds'{}(K0:SortInt{}, K1:SortInt{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortInt{}, \equals{SortInt{}, R} (Val:SortInt{}, Lbl'UndsStar'Int'Unds'{}(K0:SortInt{}, K1:SortInt{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortInt{}, \equals{SortInt{}, R} (Val:SortInt{}, Lbl'UndsPlus'Int'Unds'{}(K0:SortInt{}, K1:SortInt{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortString{}, \equals{SortString{}, R} (Val:SortString{}, Lbl'UndsPlus'String'UndsUnds'STRING-COMMON'Unds'String'Unds'String'Unds'String{}(K0:SortString{}, K1:SortString{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortStrings{}, \equals{SortStrings{}, R} (Val:SortStrings{}, Lbl'UndsCommUndsUnds'UNICODE-SYNTAX'Unds'Strings'Unds'String'Unds'Strings{}(K0:SortString{}, K1:SortStrings{}))) [functional{}()] // functional + axiom{}\implies{SortStrings{}} (\and{SortStrings{}} (Lbl'UndsCommUndsUnds'UNICODE-SYNTAX'Unds'Strings'Unds'String'Unds'Strings{}(X0:SortString{}, X1:SortStrings{}), Lbl'UndsCommUndsUnds'UNICODE-SYNTAX'Unds'Strings'Unds'String'Unds'Strings{}(Y0:SortString{}, Y1:SortStrings{})), Lbl'UndsCommUndsUnds'UNICODE-SYNTAX'Unds'Strings'Unds'String'Unds'Strings{}(\and{SortString{}} (X0:SortString{}, Y0:SortString{}), \and{SortStrings{}} (X1:SortStrings{}, Y1:SortStrings{}))) [constructor{}()] // no confusion same constructor + axiom{R} \exists{R} (Val:SortInt{}, \equals{SortInt{}, R} (Val:SortInt{}, Lbl'Unds'-Int'Unds'{}(K0:SortInt{}, K1:SortInt{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortMap{}, \equals{SortMap{}, R} (Val:SortMap{}, Lbl'Unds'-Map'UndsUnds'MAP'Unds'Map'Unds'Map'Unds'Map{}(K0:SortMap{}, K1:SortMap{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'Unds-LT-Eqls'Int'Unds'{}(K0:SortInt{}, K1:SortInt{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'Unds-LT-Eqls'Map'UndsUnds'MAP'Unds'Bool'Unds'Map'Unds'Map{}(K0:SortMap{}, K1:SortMap{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'Unds-LT-Eqls'Set'UndsUnds'SET'Unds'Bool'Unds'Set'Unds'Set{}(K0:SortSet{}, K1:SortSet{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'Unds-LT-Eqls'String'UndsUnds'STRING-COMMON'Unds'Bool'Unds'String'Unds'String{}(K0:SortString{}, K1:SortString{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'Unds-LT-'Int'Unds'{}(K0:SortInt{}, K1:SortInt{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'Unds-LT-'String'UndsUnds'STRING-COMMON'Unds'Bool'Unds'String'Unds'String{}(K0:SortString{}, K1:SortString{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'UndsEqlsSlshEqls'Bool'Unds'{}(K0:SortBool{}, K1:SortBool{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'UndsEqlsSlshEqls'Int'Unds'{}(K0:SortInt{}, K1:SortInt{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'UndsEqlsSlshEqls'K'Unds'{}(K0:SortK{}, K1:SortK{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'UndsEqlsSlshEqls'String'UndsUnds'STRING-COMMON'Unds'Bool'Unds'String'Unds'String{}(K0:SortString{}, K1:SortString{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'UndsEqlsEqls'Bool'Unds'{}(K0:SortBool{}, K1:SortBool{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'UndsEqlsEqls'Int'Unds'{}(K0:SortInt{}, K1:SortInt{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'UndsEqlsEqls'K'Unds'{}(K0:SortK{}, K1:SortK{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'UndsEqlsEqls'String'UndsUnds'STRING-COMMON'Unds'Bool'Unds'String'Unds'String{}(K0:SortString{}, K1:SortString{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'Unds-GT-Eqls'Int'Unds'{}(K0:SortInt{}, K1:SortInt{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'Unds-GT-Eqls'String'UndsUnds'STRING-COMMON'Unds'Bool'Unds'String'Unds'String{}(K0:SortString{}, K1:SortString{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'Unds-GT-'Int'Unds'{}(K0:SortInt{}, K1:SortInt{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'Unds-GT-'String'UndsUnds'STRING-COMMON'Unds'Bool'Unds'String'Unds'String{}(K0:SortString{}, K1:SortString{}))) [functional{}()] // functional + axiom{R} \equals{SortList{}, R} (Lbl'Unds'List'Unds'{}(Lbl'Unds'List'Unds'{}(K1:SortList{},K2:SortList{}),K3:SortList{}),Lbl'Unds'List'Unds'{}(K1:SortList{},Lbl'Unds'List'Unds'{}(K2:SortList{},K3:SortList{}))) [assoc{}()] // associativity + axiom{R}\equals{SortList{}, R} (Lbl'Unds'List'Unds'{}(K:SortList{},Lbl'Stop'List{}()),K:SortList{}) [unit{}()] // right unit + axiom{R}\equals{SortList{}, R} (Lbl'Unds'List'Unds'{}(Lbl'Stop'List{}(),K:SortList{}),K:SortList{}) [unit{}()] // left unit + axiom{R} \exists{R} (Val:SortList{}, \equals{SortList{}, R} (Val:SortList{}, Lbl'Unds'List'Unds'{}(K0:SortList{}, K1:SortList{}))) [functional{}()] // functional + axiom{R} \equals{SortMap{}, R} (Lbl'Unds'Map'Unds'{}(Lbl'Unds'Map'Unds'{}(K1:SortMap{},K2:SortMap{}),K3:SortMap{}),Lbl'Unds'Map'Unds'{}(K1:SortMap{},Lbl'Unds'Map'Unds'{}(K2:SortMap{},K3:SortMap{}))) [assoc{}()] // associativity + axiom{R}\equals{SortMap{}, R} (Lbl'Unds'Map'Unds'{}(K:SortMap{},Lbl'Stop'Map{}()),K:SortMap{}) [unit{}()] // right unit + axiom{R}\equals{SortMap{}, R} (Lbl'Unds'Map'Unds'{}(Lbl'Stop'Map{}(),K:SortMap{}),K:SortMap{}) [unit{}()] // left unit + axiom{R} \equals{SortSet{}, R} (Lbl'Unds'Set'Unds'{}(Lbl'Unds'Set'Unds'{}(K1:SortSet{},K2:SortSet{}),K3:SortSet{}),Lbl'Unds'Set'Unds'{}(K1:SortSet{},Lbl'Unds'Set'Unds'{}(K2:SortSet{},K3:SortSet{}))) [assoc{}()] // associativity + axiom{R} \equals{SortSet{}, R} (Lbl'Unds'Set'Unds'{}(K:SortSet{},K:SortSet{}),K:SortSet{}) [idem{}()] // idempotency + axiom{R}\equals{SortSet{}, R} (Lbl'Unds'Set'Unds'{}(K:SortSet{},Lbl'Stop'Set{}()),K:SortSet{}) [unit{}()] // right unit + axiom{R}\equals{SortSet{}, R} (Lbl'Unds'Set'Unds'{}(Lbl'Stop'Set{}(),K:SortSet{}),K:SortSet{}) [unit{}()] // left unit + axiom{R} \exists{R} (Val:SortMap{}, \equals{SortMap{}, R} (Val:SortMap{}, Lbl'UndsLSqBUnds-LT-'-undef'RSqB'{}(K0:SortMap{}, K1:SortKItem{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortKItem{}, \equals{SortKItem{}, R} (Val:SortKItem{}, Lbl'UndsLSqBUndsRSqB'orDefault'UndsUnds'MAP'Unds'KItem'Unds'Map'Unds'KItem'Unds'KItem{}(K0:SortMap{}, K1:SortKItem{}, K2:SortKItem{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'Unds'andBool'Unds'{}(K0:SortBool{}, K1:SortBool{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'Unds'andThenBool'Unds'{}(K0:SortBool{}, K1:SortBool{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'Unds'impliesBool'Unds'{}(K0:SortBool{}, K1:SortBool{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'Unds'in'UndsUnds'LIST'Unds'Bool'Unds'KItem'Unds'List{}(K0:SortKItem{}, K1:SortList{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'Unds'in'Unds'keys'LParUndsRParUnds'MAP'Unds'Bool'Unds'KItem'Unds'Map{}(K0:SortKItem{}, K1:SortMap{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'Unds'orBool'Unds'{}(K0:SortBool{}, K1:SortBool{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'Unds'orElseBool'Unds'{}(K0:SortBool{}, K1:SortBool{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, Lbl'Unds'xorBool'Unds'{}(K0:SortBool{}, K1:SortBool{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortInt{}, \equals{SortInt{}, R} (Val:SortInt{}, Lbl'Unds'xorInt'Unds'{}(K0:SortInt{}, K1:SortInt{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortMap{}, \equals{SortMap{}, R} (Val:SortMap{}, Lbl'UndsPipe'-'-GT-Unds'{}(K0:SortKItem{}, K1:SortKItem{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortInt{}, \equals{SortInt{}, R} (Val:SortInt{}, Lbl'UndsPipe'Int'Unds'{}(K0:SortInt{}, K1:SortInt{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortSet{}, \equals{SortSet{}, R} (Val:SortSet{}, Lbl'UndsPipe'Set'UndsUnds'SET'Unds'Set'Unds'Set'Unds'Set{}(K0:SortSet{}, K1:SortSet{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortInt{}, \equals{SortInt{}, R} (Val:SortInt{}, LblabsInt'LParUndsRParUnds'INT-COMMON'Unds'Int'Unds'Int{}(K0:SortInt{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortInt{}, \equals{SortInt{}, R} (Val:SortInt{}, LblcountAllOccurrences'LParUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String{}(K0:SortString{}, K1:SortString{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortInt{}, \equals{SortInt{}, R} (Val:SortInt{}, LblfreshInt'LParUndsRParUnds'INT'Unds'Int'Unds'Int{}(K0:SortInt{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortSet{}, \equals{SortSet{}, R} (Val:SortSet{}, LblintersectSet'LParUndsCommUndsRParUnds'SET'Unds'Set'Unds'Set'Unds'Set{}(K0:SortSet{}, K1:SortSet{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, LblisBool{}(K0:SortK{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, LblisFloat{}(K0:SortK{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, LblisGeneratedCounterCell{}(K0:SortK{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, LblisGeneratedTopCell{}(K0:SortK{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, LblisGeneratedTopCellFragment{}(K0:SortK{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, LblisInt{}(K0:SortK{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, LblisK{}(K0:SortK{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, LblisKCell{}(K0:SortK{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, LblisKCellOpt{}(K0:SortK{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, LblisKConfigVar{}(K0:SortK{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, LblisKItem{}(K0:SortK{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, LblisList{}(K0:SortK{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, LblisMap{}(K0:SortK{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, LblisOutCell{}(K0:SortK{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, LblisOutCellOpt{}(K0:SortK{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, LblisSet{}(K0:SortK{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, LblisString{}(K0:SortK{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, LblisStrings{}(K0:SortK{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortSet{}, \equals{SortSet{}, R} (Val:SortSet{}, Lblkeys'LParUndsRParUnds'MAP'Unds'Set'Unds'Map{}(K0:SortMap{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortInt{}, \equals{SortInt{}, R} (Val:SortInt{}, LbllengthString'LParUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String{}(K0:SortString{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortInt{}, \equals{SortInt{}, R} (Val:SortInt{}, LblmaxInt'LParUndsCommUndsRParUnds'INT-COMMON'Unds'Int'Unds'Int'Unds'Int{}(K0:SortInt{}, K1:SortInt{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortInt{}, \equals{SortInt{}, R} (Val:SortInt{}, LblminInt'LParUndsCommUndsRParUnds'INT-COMMON'Unds'Int'Unds'Int'Unds'Int{}(K0:SortInt{}, K1:SortInt{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortKCellOpt{}, \equals{SortKCellOpt{}, R} (Val:SortKCellOpt{}, LblnoKCell{}())) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortOutCellOpt{}, \equals{SortOutCellOpt{}, R} (Val:SortOutCellOpt{}, LblnoOutCell{}())) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortBool{}, \equals{SortBool{}, R} (Val:SortBool{}, LblnotBool'Unds'{}(K0:SortBool{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortMap{}, \equals{SortMap{}, R} (Val:SortMap{}, LblremoveAll'LParUndsCommUndsRParUnds'MAP'Unds'Map'Unds'Map'Unds'Set{}(K0:SortMap{}, K1:SortSet{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortString{}, \equals{SortString{}, R} (Val:SortString{}, LblreplaceAll'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'String'Unds'String{}(K0:SortString{}, K1:SortString{}, K2:SortString{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortString{}, \equals{SortString{}, R} (Val:SortString{}, LblreplaceFirst'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'String'Unds'String{}(K0:SortString{}, K1:SortString{}, K2:SortString{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortInt{}, \equals{SortInt{}, R} (Val:SortInt{}, Lblsize'LParUndsRParUnds'LIST'Unds'Int'Unds'List{}(K0:SortList{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortInt{}, \equals{SortInt{}, R} (Val:SortInt{}, Lblsize'LParUndsRParUnds'MAP'Unds'Int'Unds'Map{}(K0:SortMap{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortInt{}, \equals{SortInt{}, R} (Val:SortInt{}, Lblsize'LParUndsRParUnds'SET'Unds'Int'Unds'Set{}(K0:SortSet{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortString{}, \equals{SortString{}, R} (Val:SortString{}, LblsubstrString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'Int'Unds'Int{}(K0:SortString{}, K1:SortInt{}, K2:SortInt{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortMap{}, \equals{SortMap{}, R} (Val:SortMap{}, LblupdateMap'LParUndsCommUndsRParUnds'MAP'Unds'Map'Unds'Map'Unds'Map{}(K0:SortMap{}, K1:SortMap{}))) [functional{}()] // functional + axiom{R} \exists{R} (Val:SortInt{}, \equals{SortInt{}, R} (Val:SortInt{}, Lbl'Tild'Int'Unds'{}(K0:SortInt{}))) [functional{}()] // functional + axiom{} \or{SortKItem{}} (\exists{SortKItem{}} (Val:SortList{}, inj{SortList{}, SortKItem{}} (Val:SortList{})), \or{SortKItem{}} (\exists{SortKItem{}} (Val:SortOutCellOpt{}, inj{SortOutCellOpt{}, SortKItem{}} (Val:SortOutCellOpt{})), \or{SortKItem{}} (\exists{SortKItem{}} (Val:SortOutCell{}, inj{SortOutCell{}, SortKItem{}} (Val:SortOutCell{})), \or{SortKItem{}} (\exists{SortKItem{}} (Val:SortString{}, inj{SortString{}, SortKItem{}} (Val:SortString{})), \or{SortKItem{}} (\exists{SortKItem{}} (Val:SortKConfigVar{}, inj{SortKConfigVar{}, SortKItem{}} (Val:SortKConfigVar{})), \or{SortKItem{}} (\exists{SortKItem{}} (Val:SortGeneratedCounterCell{}, inj{SortGeneratedCounterCell{}, SortKItem{}} (Val:SortGeneratedCounterCell{})), \or{SortKItem{}} (\exists{SortKItem{}} (Val:SortBool{}, inj{SortBool{}, SortKItem{}} (Val:SortBool{})), \or{SortKItem{}} (\exists{SortKItem{}} (Val:SortKCell{}, inj{SortKCell{}, SortKItem{}} (Val:SortKCell{})), \or{SortKItem{}} (\exists{SortKItem{}} (Val:SortMap{}, inj{SortMap{}, SortKItem{}} (Val:SortMap{})), \or{SortKItem{}} (\exists{SortKItem{}} (Val:SortKCellOpt{}, inj{SortKCellOpt{}, SortKItem{}} (Val:SortKCellOpt{})), \or{SortKItem{}} (\exists{SortKItem{}} (Val:SortInt{}, inj{SortInt{}, SortKItem{}} (Val:SortInt{})), \or{SortKItem{}} (\exists{SortKItem{}} (Val:SortFloat{}, inj{SortFloat{}, SortKItem{}} (Val:SortFloat{})), \or{SortKItem{}} (\exists{SortKItem{}} (Val:SortGeneratedTopCell{}, inj{SortGeneratedTopCell{}, SortKItem{}} (Val:SortGeneratedTopCell{})), \or{SortKItem{}} (\exists{SortKItem{}} (Val:SortStrings{}, inj{SortStrings{}, SortKItem{}} (Val:SortStrings{})), \or{SortKItem{}} (\exists{SortKItem{}} (Val:SortSet{}, inj{SortSet{}, SortKItem{}} (Val:SortSet{})), \or{SortKItem{}} (\exists{SortKItem{}} (Val:SortGeneratedTopCellFragment{}, inj{SortGeneratedTopCellFragment{}, SortKItem{}} (Val:SortGeneratedTopCellFragment{})), \bottom{SortKItem{}}())))))))))))))))) [constructor{}()] // no junk + axiom{} \or{SortOutCellOpt{}} (LblnoOutCell{}(), \or{SortOutCellOpt{}} (\exists{SortOutCellOpt{}} (Val:SortOutCell{}, inj{SortOutCell{}, SortOutCellOpt{}} (Val:SortOutCell{})), \bottom{SortOutCellOpt{}}())) [constructor{}()] // no junk + axiom{} \or{SortOutCell{}} (\exists{SortOutCell{}} (X0:SortStrings{}, Lbl'-LT-'out'-GT-'{}(X0:SortStrings{})), \bottom{SortOutCell{}}()) [constructor{}()] // no junk + axiom{} \or{SortString{}} (\top{SortString{}}(), \bottom{SortString{}}()) [constructor{}()] // no junk (TODO: fix bug with \dv) + axiom{} \or{SortKConfigVar{}} (\top{SortKConfigVar{}}(), \bottom{SortKConfigVar{}}()) [constructor{}()] // no junk (TODO: fix bug with \dv) + axiom{} \or{SortGeneratedCounterCell{}} (\exists{SortGeneratedCounterCell{}} (X0:SortInt{}, Lbl'-LT-'generatedCounter'-GT-'{}(X0:SortInt{})), \bottom{SortGeneratedCounterCell{}}()) [constructor{}()] // no junk + axiom{} \or{SortBool{}} (\top{SortBool{}}(), \bottom{SortBool{}}()) [constructor{}()] // no junk (TODO: fix bug with \dv) + axiom{} \or{SortKCell{}} (\exists{SortKCell{}} (X0:SortK{}, Lbl'-LT-'k'-GT-'{}(X0:SortK{})), \bottom{SortKCell{}}()) [constructor{}()] // no junk + axiom{} \or{SortKCellOpt{}} (LblnoKCell{}(), \or{SortKCellOpt{}} (\exists{SortKCellOpt{}} (Val:SortKCell{}, inj{SortKCell{}, SortKCellOpt{}} (Val:SortKCell{})), \bottom{SortKCellOpt{}}())) [constructor{}()] // no junk + axiom{} \or{SortInt{}} (\top{SortInt{}}(), \bottom{SortInt{}}()) [constructor{}()] // no junk (TODO: fix bug with \dv) + axiom{} \or{SortFloat{}} (\top{SortFloat{}}(), \bottom{SortFloat{}}()) [constructor{}()] // no junk (TODO: fix bug with \dv) + axiom{} \or{SortGeneratedTopCell{}} (\exists{SortGeneratedTopCell{}} (X0:SortKCell{}, \exists{SortGeneratedTopCell{}} (X1:SortOutCell{}, \exists{SortGeneratedTopCell{}} (X2:SortGeneratedCounterCell{}, Lbl'-LT-'generatedTop'-GT-'{}(X0:SortKCell{}, X1:SortOutCell{}, X2:SortGeneratedCounterCell{})))), \bottom{SortGeneratedTopCell{}}()) [constructor{}()] // no junk + axiom{} \or{SortStrings{}} (Lbl'Stop'List'LBraQuotUndsCommUndsUnds'UNICODE-SYNTAX'Unds'Strings'Unds'String'Unds'Strings'QuotRBraUnds'Strings{}(), \or{SortStrings{}} (\exists{SortStrings{}} (X0:SortString{}, \exists{SortStrings{}} (X1:SortStrings{}, Lbl'UndsCommUndsUnds'UNICODE-SYNTAX'Unds'Strings'Unds'String'Unds'Strings{}(X0:SortString{}, X1:SortStrings{}))), \bottom{SortStrings{}}())) [constructor{}()] // no junk + axiom{} \or{SortGeneratedTopCellFragment{}} (\exists{SortGeneratedTopCellFragment{}} (X0:SortKCellOpt{}, \exists{SortGeneratedTopCellFragment{}} (X1:SortOutCellOpt{}, Lbl'-LT-'generatedTop'-GT-'-fragment{}(X0:SortKCellOpt{}, X1:SortOutCellOpt{}))), \bottom{SortGeneratedTopCellFragment{}}()) [constructor{}()] // no junk + +// rules +// rule `#if_#then_#else_#fi_K-EQUAL-SYNTAX_Sort_Bool_Sort_Sort`{K}(C,B1,_Gen0)=>B1 requires C ensures #token("true","Bool") [UNIQUE_ID(2b32069ac3f589174502fa507ebc88fab7c902854c0a9baa8ab09beb551232e2), org.kframework.attributes.Location(Location(2289,8,2289,59)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody "requires" Bool [klabel(#ruleRequires), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \equals{SortBool{},R}( + VarC:SortBool{}, + \dv{SortBool{}}("true")), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + VarC:SortBool{} + ),\and{R} ( + \in{SortK{}, R} ( + X1:SortK{}, + VarB1:SortK{} + ),\and{R} ( + \in{SortK{}, R} ( + X2:SortK{}, + Var'Unds'Gen0:SortK{} + ), + \top{R} () + )))), + \equals{SortK{},R} ( + Lbl'Hash'if'UndsHash'then'UndsHash'else'UndsHash'fi'Unds'K-EQUAL-SYNTAX'Unds'Sort'Unds'Bool'Unds'Sort'Unds'Sort{SortK{}}(X0:SortBool{},X1:SortK{},X2:SortK{}), + \and{SortK{}} ( + VarB1:SortK{}, + \top{SortK{}}()))) + [UNIQUE'Unds'ID{}("2b32069ac3f589174502fa507ebc88fab7c902854c0a9baa8ab09beb551232e2"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(2289,8,2289,59)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody \"requires\" Bool [klabel(#ruleRequires), symbol]")] + +// rule `#if_#then_#else_#fi_K-EQUAL-SYNTAX_Sort_Bool_Sort_Sort`{K}(C,_Gen0,B2)=>B2 requires `notBool_`(C) ensures #token("true","Bool") [UNIQUE_ID(651bff3fa53d464ac7dd7aa77e1ef6071e14c959eb6df97baa325e2ad300daaa), org.kframework.attributes.Location(Location(2290,8,2290,67)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody "requires" Bool [klabel(#ruleRequires), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \equals{SortBool{},R}( + LblnotBool'Unds'{}(VarC:SortBool{}), + \dv{SortBool{}}("true")), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + VarC:SortBool{} + ),\and{R} ( + \in{SortK{}, R} ( + X1:SortK{}, + Var'Unds'Gen0:SortK{} + ),\and{R} ( + \in{SortK{}, R} ( + X2:SortK{}, + VarB2:SortK{} + ), + \top{R} () + )))), + \equals{SortK{},R} ( + Lbl'Hash'if'UndsHash'then'UndsHash'else'UndsHash'fi'Unds'K-EQUAL-SYNTAX'Unds'Sort'Unds'Bool'Unds'Sort'Unds'Sort{SortK{}}(X0:SortBool{},X1:SortK{},X2:SortK{}), + \and{SortK{}} ( + VarB2:SortK{}, + \top{SortK{}}()))) + [UNIQUE'Unds'ID{}("651bff3fa53d464ac7dd7aa77e1ef6071e14c959eb6df97baa325e2ad300daaa"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(2290,8,2290,67)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody \"requires\" Bool [klabel(#ruleRequires), symbol]")] + +// rule ``(``(inj{Strings,KItem}(SS)~>_DotVar1),``(_Gen0),_DotVar0)=>``(``(_DotVar1),``(`goAll(_)_UNICODE_Strings_Strings`(SS)),_DotVar0) requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(344524c98eca5dc8d7d9f73645696004047c6ca39ddcbdd70559d1ede3ea34ca), cool-like, org.kframework.attributes.Location(Location(15,10,16,34)), org.kframework.attributes.Source(Source(/home/sguest/work/k-test/unicode.k)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{} \rewrites{SortGeneratedTopCell{}} ( + \and{SortGeneratedTopCell{}} ( + Lbl'-LT-'generatedTop'-GT-'{}(Lbl'-LT-'k'-GT-'{}(kseq{}(inj{SortStrings{}, SortKItem{}}(VarSS:SortStrings{}),Var'Unds'DotVar1:SortK{})),Lbl'-LT-'out'-GT-'{}(Var'Unds'Gen0:SortStrings{}),Var'Unds'DotVar0:SortGeneratedCounterCell{}), + \top{SortGeneratedTopCell{}}()), + \and{SortGeneratedTopCell{}} ( + Lbl'-LT-'generatedTop'-GT-'{}(Lbl'-LT-'k'-GT-'{}(Var'Unds'DotVar1:SortK{}),Lbl'-LT-'out'-GT-'{}(LblgoAll'LParUndsRParUnds'UNICODE'Unds'Strings'Unds'Strings{}(VarSS:SortStrings{})),Var'Unds'DotVar0:SortGeneratedCounterCell{}), \top{SortGeneratedTopCell{}}())) + [UNIQUE'Unds'ID{}("344524c98eca5dc8d7d9f73645696004047c6ca39ddcbdd70559d1ede3ea34ca"), cool-like{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(15,10,16,34)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k-test/unicode.k)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `Bool2String(_)_STRING-COMMON_String_Bool`(#token("false","Bool"))=>#token("\"false\"","String") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(cca4780e4e7660055f781b9643f3125234a0f4f08ba76cacf8e5a18fe7fc999f), org.kframework.attributes.Location(Location(1764,8,1764,37)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + \dv{SortBool{}}("false") + ), + \top{R} () + )), + \equals{SortString{},R} ( + LblBool2String'LParUndsRParUnds'STRING-COMMON'Unds'String'Unds'Bool{}(X0:SortBool{}), + \and{SortString{}} ( + \dv{SortString{}}("false"), + \top{SortString{}}()))) + [UNIQUE'Unds'ID{}("cca4780e4e7660055f781b9643f3125234a0f4f08ba76cacf8e5a18fe7fc999f"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1764,8,1764,37)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `Bool2String(_)_STRING-COMMON_String_Bool`(#token("true","Bool"))=>#token("\"true\"","String") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(365df37345a5a44ac061f8741369c7bd74a49f0f6e7b716be0374806dd1add3d), org.kframework.attributes.Location(Location(1763,8,1763,36)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + \dv{SortBool{}}("true") + ), + \top{R} () + )), + \equals{SortString{},R} ( + LblBool2String'LParUndsRParUnds'STRING-COMMON'Unds'String'Unds'Bool{}(X0:SortBool{}), + \and{SortString{}} ( + \dv{SortString{}}("true"), + \top{SortString{}}()))) + [UNIQUE'Unds'ID{}("365df37345a5a44ac061f8741369c7bd74a49f0f6e7b716be0374806dd1add3d"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1763,8,1763,36)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `String2Bool(_)_STRING-COMMON_Bool_String`(#token("\"false\"","String"))=>#token("false","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(b73b5c8e0ae45020f2b9b8170d366691fee01a63763b79653a2075703ec4e835), org.kframework.attributes.Location(Location(1770,8,1770,37)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + \dv{SortString{}}("false") + ), + \top{R} () + )), + \equals{SortBool{},R} ( + LblString2Bool'LParUndsRParUnds'STRING-COMMON'Unds'Bool'Unds'String{}(X0:SortString{}), + \and{SortBool{}} ( + \dv{SortBool{}}("false"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("b73b5c8e0ae45020f2b9b8170d366691fee01a63763b79653a2075703ec4e835"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1770,8,1770,37)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `String2Bool(_)_STRING-COMMON_Bool_String`(#token("\"true\"","String"))=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(27a5d1d7872d61f82556a4e44bda13846dde7dc2d9c54304d7858de9a8b9d6b8), org.kframework.attributes.Location(Location(1769,8,1769,36)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + \dv{SortString{}}("true") + ), + \top{R} () + )), + \equals{SortBool{},R} ( + LblString2Bool'LParUndsRParUnds'STRING-COMMON'Unds'Bool'Unds'String{}(X0:SortString{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("27a5d1d7872d61f82556a4e44bda13846dde7dc2d9c54304d7858de9a8b9d6b8"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1769,8,1769,36)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_<=String__STRING-COMMON_Bool_String_String`(S1,S2)=>`notBool_`(`_`notBool_`(`_==Bool_`(B1,B2)) requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(31fe72efcfddcd8588a11d9d10c1b1a9f96ae3da46b647d4cb9d1e8b1bd1654f), org.kframework.attributes.Location(Location(1150,8,1150,57)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + VarB1:SortBool{} + ),\and{R} ( + \in{SortBool{}, R} ( + X1:SortBool{}, + VarB2:SortBool{} + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'UndsEqlsSlshEqls'Bool'Unds'{}(X0:SortBool{},X1:SortBool{}), + \and{SortBool{}} ( + LblnotBool'Unds'{}(Lbl'UndsEqlsEqls'Bool'Unds'{}(VarB1:SortBool{},VarB2:SortBool{})), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("31fe72efcfddcd8588a11d9d10c1b1a9f96ae3da46b647d4cb9d1e8b1bd1654f"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1150,8,1150,57)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_=/=Int_`(I1,I2)=>`notBool_`(`_==Int_`(I1,I2)) requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(4de6e05b11cdbed7ef5cb4c952127924661af4744c1e495370e1c8a962ba7be3), org.kframework.attributes.Location(Location(1429,8,1429,53)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortInt{}, R} ( + X0:SortInt{}, + VarI1:SortInt{} + ),\and{R} ( + \in{SortInt{}, R} ( + X1:SortInt{}, + VarI2:SortInt{} + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'UndsEqlsSlshEqls'Int'Unds'{}(X0:SortInt{},X1:SortInt{}), + \and{SortBool{}} ( + LblnotBool'Unds'{}(Lbl'UndsEqlsEqls'Int'Unds'{}(VarI1:SortInt{},VarI2:SortInt{})), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("4de6e05b11cdbed7ef5cb4c952127924661af4744c1e495370e1c8a962ba7be3"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1429,8,1429,53)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_=/=K_`(K1,K2)=>`notBool_`(`_==K_`(K1,K2)) requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(bccaba7335e4cd77501a0667f2f7b3eb4a2105d5f60d804915dd4b1b08902c0c), org.kframework.attributes.Location(Location(2287,8,2287,45)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + VarK1:SortK{} + ),\and{R} ( + \in{SortK{}, R} ( + X1:SortK{}, + VarK2:SortK{} + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'UndsEqlsSlshEqls'K'Unds'{}(X0:SortK{},X1:SortK{}), + \and{SortBool{}} ( + LblnotBool'Unds'{}(Lbl'UndsEqlsEqls'K'Unds'{}(VarK1:SortK{},VarK2:SortK{})), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("bccaba7335e4cd77501a0667f2f7b3eb4a2105d5f60d804915dd4b1b08902c0c"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(2287,8,2287,45)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_=/=String__STRING-COMMON_Bool_String_String`(S1,S2)=>`notBool_`(`_==String__STRING-COMMON_Bool_String_String`(S1,S2)) requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(f390a9b650f3de0e3a93773a46e65aae3decdeb2a10906058f204f031681c9b7), org.kframework.attributes.Location(Location(1843,8,1843,65)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + VarS1:SortString{} + ),\and{R} ( + \in{SortString{}, R} ( + X1:SortString{}, + VarS2:SortString{} + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'UndsEqlsSlshEqls'String'UndsUnds'STRING-COMMON'Unds'Bool'Unds'String'Unds'String{}(X0:SortString{},X1:SortString{}), + \and{SortBool{}} ( + LblnotBool'Unds'{}(Lbl'UndsEqlsEqls'String'UndsUnds'STRING-COMMON'Unds'Bool'Unds'String'Unds'String{}(VarS1:SortString{},VarS2:SortString{})), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("f390a9b650f3de0e3a93773a46e65aae3decdeb2a10906058f204f031681c9b7"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1843,8,1843,65)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_>=String__STRING-COMMON_Bool_String_String`(S1,S2)=>`notBool_`(`_String__STRING-COMMON_Bool_String_String`(S1,S2)=>`__Gen1 requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(61fbef33b3611f1cc2aaf3b5e8ddec4a0f434c557278c38461c65c8722743497), org.kframework.attributes.Location(Location(1123,8,1123,37)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + \and{SortBool{}}(\dv{SortBool{}}("false"),Var'Unds'Gen1:SortBool{}) + ),\and{R} ( + \in{SortBool{}, R} ( + X1:SortBool{}, + Var'Unds'Gen0:SortBool{} + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'Unds'andBool'Unds'{}(X0:SortBool{},X1:SortBool{}), + \and{SortBool{}} ( + Var'Unds'Gen1:SortBool{}, + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("61fbef33b3611f1cc2aaf3b5e8ddec4a0f434c557278c38461c65c8722743497"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1123,8,1123,37)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_andBool_`(B,#token("true","Bool"))=>B requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(e8d4ca75a690151f99f8904b068db555782f5599b11230a9d0b97a71afb6fc98), org.kframework.attributes.Location(Location(1122,8,1122,37)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + VarB:SortBool{} + ),\and{R} ( + \in{SortBool{}, R} ( + X1:SortBool{}, + \dv{SortBool{}}("true") + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'Unds'andBool'Unds'{}(X0:SortBool{},X1:SortBool{}), + \and{SortBool{}} ( + VarB:SortBool{}, + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("e8d4ca75a690151f99f8904b068db555782f5599b11230a9d0b97a71afb6fc98"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1122,8,1122,37)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_andBool_`(_Gen0,#token("false","Bool") #as _Gen1)=>_Gen1 requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(9c183fae7de06f560180386d14d29c609cadf0c98266ce2adbecb50100a1daca), org.kframework.attributes.Location(Location(1124,8,1124,37)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + Var'Unds'Gen0:SortBool{} + ),\and{R} ( + \in{SortBool{}, R} ( + X1:SortBool{}, + \and{SortBool{}}(\dv{SortBool{}}("false"),Var'Unds'Gen1:SortBool{}) + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'Unds'andBool'Unds'{}(X0:SortBool{},X1:SortBool{}), + \and{SortBool{}} ( + Var'Unds'Gen1:SortBool{}, + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("9c183fae7de06f560180386d14d29c609cadf0c98266ce2adbecb50100a1daca"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1124,8,1124,37)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_andBool_`(#token("true","Bool"),B)=>B requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(5b9db8dba12010819161cc42dadccd0adf0100a47c21f884ae66c0a3d5483a1f), org.kframework.attributes.Location(Location(1121,8,1121,37)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + \dv{SortBool{}}("true") + ),\and{R} ( + \in{SortBool{}, R} ( + X1:SortBool{}, + VarB:SortBool{} + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'Unds'andBool'Unds'{}(X0:SortBool{},X1:SortBool{}), + \and{SortBool{}} ( + VarB:SortBool{}, + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("5b9db8dba12010819161cc42dadccd0adf0100a47c21f884ae66c0a3d5483a1f"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1121,8,1121,37)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_andThenBool_`(#token("false","Bool") #as _Gen1,_Gen0)=>_Gen1 requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(5b729746be7bf2183d9eff138d97078a7c9489def6d8b2e1495c41ce3954997d), org.kframework.attributes.Location(Location(1128,8,1128,36)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + \and{SortBool{}}(\dv{SortBool{}}("false"),Var'Unds'Gen1:SortBool{}) + ),\and{R} ( + \in{SortBool{}, R} ( + X1:SortBool{}, + Var'Unds'Gen0:SortBool{} + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'Unds'andThenBool'Unds'{}(X0:SortBool{},X1:SortBool{}), + \and{SortBool{}} ( + Var'Unds'Gen1:SortBool{}, + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("5b729746be7bf2183d9eff138d97078a7c9489def6d8b2e1495c41ce3954997d"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1128,8,1128,36)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_andThenBool_`(K,#token("true","Bool"))=>K requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(82ac30b094be9b12206773d87b60274e929a41ca595f4674be1d37eeff873d7c), org.kframework.attributes.Location(Location(1127,8,1127,37)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + VarK:SortBool{} + ),\and{R} ( + \in{SortBool{}, R} ( + X1:SortBool{}, + \dv{SortBool{}}("true") + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'Unds'andThenBool'Unds'{}(X0:SortBool{},X1:SortBool{}), + \and{SortBool{}} ( + VarK:SortBool{}, + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("82ac30b094be9b12206773d87b60274e929a41ca595f4674be1d37eeff873d7c"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1127,8,1127,37)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_andThenBool_`(_Gen0,#token("false","Bool") #as _Gen1)=>_Gen1 requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(0508592878b546cbc6eeda6ec7b322584eea5c6d6eea3f72be8418fe4f7149b2), org.kframework.attributes.Location(Location(1129,8,1129,36)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + Var'Unds'Gen0:SortBool{} + ),\and{R} ( + \in{SortBool{}, R} ( + X1:SortBool{}, + \and{SortBool{}}(\dv{SortBool{}}("false"),Var'Unds'Gen1:SortBool{}) + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'Unds'andThenBool'Unds'{}(X0:SortBool{},X1:SortBool{}), + \and{SortBool{}} ( + Var'Unds'Gen1:SortBool{}, + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("0508592878b546cbc6eeda6ec7b322584eea5c6d6eea3f72be8418fe4f7149b2"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1129,8,1129,36)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_andThenBool_`(#token("true","Bool"),K)=>K requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(78a3191cbbdec57b0f411f41291076c8124bb0d9b6b57905674b2c6858d78689), org.kframework.attributes.Location(Location(1126,8,1126,37)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + \dv{SortBool{}}("true") + ),\and{R} ( + \in{SortBool{}, R} ( + X1:SortBool{}, + VarK:SortBool{} + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'Unds'andThenBool'Unds'{}(X0:SortBool{},X1:SortBool{}), + \and{SortBool{}} ( + VarK:SortBool{}, + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("78a3191cbbdec57b0f411f41291076c8124bb0d9b6b57905674b2c6858d78689"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1126,8,1126,37)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_divInt_`(I1,I2)=>`_/Int_`(`_-Int_`(I1,`_modInt_`(I1,I2)),I2) requires `_=/=Int_`(I2,#token("0","Int")) ensures #token("true","Bool") [UNIQUE_ID(83dcf9bc8c69f131715bc7a92d06c99b9a2b5f4c4fdafb69e6fdb2f1822712d4), org.kframework.attributes.Location(Location(1418,8,1419,23)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody "requires" Bool [klabel(#ruleRequires), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \equals{SortBool{},R}( + Lbl'UndsEqlsSlshEqls'Int'Unds'{}(VarI2:SortInt{},\dv{SortInt{}}("0")), + \dv{SortBool{}}("true")), + \and{R} ( + \in{SortInt{}, R} ( + X0:SortInt{}, + VarI1:SortInt{} + ),\and{R} ( + \in{SortInt{}, R} ( + X1:SortInt{}, + VarI2:SortInt{} + ), + \top{R} () + ))), + \equals{SortInt{},R} ( + Lbl'Unds'divInt'Unds'{}(X0:SortInt{},X1:SortInt{}), + \and{SortInt{}} ( + Lbl'UndsSlsh'Int'Unds'{}(Lbl'Unds'-Int'Unds'{}(VarI1:SortInt{},Lbl'Unds'modInt'Unds'{}(VarI1:SortInt{},VarI2:SortInt{})),VarI2:SortInt{}), + \top{SortInt{}}()))) + [UNIQUE'Unds'ID{}("83dcf9bc8c69f131715bc7a92d06c99b9a2b5f4c4fdafb69e6fdb2f1822712d4"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1418,8,1419,23)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody \"requires\" Bool [klabel(#ruleRequires), symbol]")] + +// rule `_dividesInt__INT-COMMON_Bool_Int_Int`(I1,I2)=>`_==Int_`(`_%Int_`(I2,I1),#token("0","Int")) requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(fd8facae0061fe5bc5c406f7ad2ed5d8d21960bf1118c9b240451253064dadb5), org.kframework.attributes.Location(Location(1430,8,1430,58)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortInt{}, R} ( + X0:SortInt{}, + VarI1:SortInt{} + ),\and{R} ( + \in{SortInt{}, R} ( + X1:SortInt{}, + VarI2:SortInt{} + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'Unds'dividesInt'UndsUnds'INT-COMMON'Unds'Bool'Unds'Int'Unds'Int{}(X0:SortInt{},X1:SortInt{}), + \and{SortBool{}} ( + Lbl'UndsEqlsEqls'Int'Unds'{}(Lbl'UndsPerc'Int'Unds'{}(VarI2:SortInt{},VarI1:SortInt{}),\dv{SortInt{}}("0")), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("fd8facae0061fe5bc5c406f7ad2ed5d8d21960bf1118c9b240451253064dadb5"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1430,8,1430,58)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_impliesBool_`(B,#token("false","Bool"))=>`notBool_`(B) requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(022c562a21d72cedfb795607d2249b8ad14b66399b720b3b2f4a05a1da08df96), org.kframework.attributes.Location(Location(1148,8,1148,45)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + VarB:SortBool{} + ),\and{R} ( + \in{SortBool{}, R} ( + X1:SortBool{}, + \dv{SortBool{}}("false") + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'Unds'impliesBool'Unds'{}(X0:SortBool{},X1:SortBool{}), + \and{SortBool{}} ( + LblnotBool'Unds'{}(VarB:SortBool{}), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("022c562a21d72cedfb795607d2249b8ad14b66399b720b3b2f4a05a1da08df96"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1148,8,1148,45)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_impliesBool_`(_Gen0,#token("true","Bool"))=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(99ba64afc26a739953df142ccd4b486bba68107fce8c9aa356d40afa7a988712), org.kframework.attributes.Location(Location(1147,8,1147,39)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + Var'Unds'Gen0:SortBool{} + ),\and{R} ( + \in{SortBool{}, R} ( + X1:SortBool{}, + \dv{SortBool{}}("true") + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'Unds'impliesBool'Unds'{}(X0:SortBool{},X1:SortBool{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("99ba64afc26a739953df142ccd4b486bba68107fce8c9aa356d40afa7a988712"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1147,8,1147,39)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_impliesBool_`(#token("false","Bool"),_Gen0)=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(55bb5c83c9563c712537b95401c0a5c88255fd7cdbd18b2d4358c54aee80660e), org.kframework.attributes.Location(Location(1146,8,1146,40)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + \dv{SortBool{}}("false") + ),\and{R} ( + \in{SortBool{}, R} ( + X1:SortBool{}, + Var'Unds'Gen0:SortBool{} + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'Unds'impliesBool'Unds'{}(X0:SortBool{},X1:SortBool{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("55bb5c83c9563c712537b95401c0a5c88255fd7cdbd18b2d4358c54aee80660e"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1146,8,1146,40)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_impliesBool_`(#token("true","Bool"),B)=>B requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(da818c43c21c5fb2cced7e02a74b6b4191d323de2967a671b961ad28550f3c7d), org.kframework.attributes.Location(Location(1145,8,1145,36)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + \dv{SortBool{}}("true") + ),\and{R} ( + \in{SortBool{}, R} ( + X1:SortBool{}, + VarB:SortBool{} + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'Unds'impliesBool'Unds'{}(X0:SortBool{},X1:SortBool{}), + \and{SortBool{}} ( + VarB:SortBool{}, + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("da818c43c21c5fb2cced7e02a74b6b4191d323de2967a671b961ad28550f3c7d"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1145,8,1145,36)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_modInt_`(I1,I2)=>`_%Int_`(`_+Int_`(`_%Int_`(I1,`absInt(_)_INT-COMMON_Int_Int`(I2)),`absInt(_)_INT-COMMON_Int_Int`(I2)),`absInt(_)_INT-COMMON_Int_Int`(I2)) requires `_=/=Int_`(I2,#token("0","Int")) ensures #token("true","Bool") [UNIQUE_ID(adfacb58b0678a49f66186954229939a953c9849d5b08edc8f887c0d7514b2c6), concrete, org.kframework.attributes.Location(Location(1421,5,1424,23)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody "requires" Bool [klabel(#ruleRequires), symbol]), simplification] + axiom{R} \implies{R} ( + \equals{SortBool{},R}( + Lbl'UndsEqlsSlshEqls'Int'Unds'{}(VarI2:SortInt{},\dv{SortInt{}}("0")), + \dv{SortBool{}}("true")), + \equals{SortInt{},R} ( + Lbl'Unds'modInt'Unds'{}(VarI1:SortInt{},VarI2:SortInt{}), + \and{SortInt{}} ( + Lbl'UndsPerc'Int'Unds'{}(Lbl'UndsPlus'Int'Unds'{}(Lbl'UndsPerc'Int'Unds'{}(VarI1:SortInt{},LblabsInt'LParUndsRParUnds'INT-COMMON'Unds'Int'Unds'Int{}(VarI2:SortInt{})),LblabsInt'LParUndsRParUnds'INT-COMMON'Unds'Int'Unds'Int{}(VarI2:SortInt{})),LblabsInt'LParUndsRParUnds'INT-COMMON'Unds'Int'Unds'Int{}(VarI2:SortInt{})), + \top{SortInt{}}()))) + [UNIQUE'Unds'ID{}("adfacb58b0678a49f66186954229939a953c9849d5b08edc8f887c0d7514b2c6"), concrete{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1421,5,1424,23)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody \"requires\" Bool [klabel(#ruleRequires), symbol]"), simplification{}()] + +// rule `_orBool_`(B,#token("false","Bool"))=>B requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(d7245713da157cf997438091f92bb78eb51a6cefa568bb0d30560ce08d647f26), org.kframework.attributes.Location(Location(1138,8,1138,32)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + VarB:SortBool{} + ),\and{R} ( + \in{SortBool{}, R} ( + X1:SortBool{}, + \dv{SortBool{}}("false") + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'Unds'orBool'Unds'{}(X0:SortBool{},X1:SortBool{}), + \and{SortBool{}} ( + VarB:SortBool{}, + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("d7245713da157cf997438091f92bb78eb51a6cefa568bb0d30560ce08d647f26"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1138,8,1138,32)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_orBool_`(_Gen0,#token("true","Bool"))=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(47860d52c18a441b229449cd89d5464256137dc32deb5551effbac0482c883f3), org.kframework.attributes.Location(Location(1136,8,1136,34)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + Var'Unds'Gen0:SortBool{} + ),\and{R} ( + \in{SortBool{}, R} ( + X1:SortBool{}, + \dv{SortBool{}}("true") + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'Unds'orBool'Unds'{}(X0:SortBool{},X1:SortBool{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("47860d52c18a441b229449cd89d5464256137dc32deb5551effbac0482c883f3"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1136,8,1136,34)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_orBool_`(#token("false","Bool"),B)=>B requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(991a3290bc7b6dca75d676a72a848ec6b2bd2827fb0e9626252aa1507394ca1b), org.kframework.attributes.Location(Location(1137,8,1137,32)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + \dv{SortBool{}}("false") + ),\and{R} ( + \in{SortBool{}, R} ( + X1:SortBool{}, + VarB:SortBool{} + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'Unds'orBool'Unds'{}(X0:SortBool{},X1:SortBool{}), + \and{SortBool{}} ( + VarB:SortBool{}, + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("991a3290bc7b6dca75d676a72a848ec6b2bd2827fb0e9626252aa1507394ca1b"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1137,8,1137,32)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_orBool_`(#token("true","Bool"),_Gen0)=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(71744528cdad83bc729990d3af3b544d27b09630b2615ca707dd2fc6ec93e7c2), org.kframework.attributes.Location(Location(1135,8,1135,34)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + \dv{SortBool{}}("true") + ),\and{R} ( + \in{SortBool{}, R} ( + X1:SortBool{}, + Var'Unds'Gen0:SortBool{} + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'Unds'orBool'Unds'{}(X0:SortBool{},X1:SortBool{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("71744528cdad83bc729990d3af3b544d27b09630b2615ca707dd2fc6ec93e7c2"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1135,8,1135,34)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_orElseBool_`(K,#token("false","Bool"))=>K requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(684b0444a1f711d49ff1502423a3346fb26958697423db488b05d25081fc0480), org.kframework.attributes.Location(Location(1143,8,1143,37)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + VarK:SortBool{} + ),\and{R} ( + \in{SortBool{}, R} ( + X1:SortBool{}, + \dv{SortBool{}}("false") + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'Unds'orElseBool'Unds'{}(X0:SortBool{},X1:SortBool{}), + \and{SortBool{}} ( + VarK:SortBool{}, + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("684b0444a1f711d49ff1502423a3346fb26958697423db488b05d25081fc0480"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1143,8,1143,37)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_orElseBool_`(_Gen0,#token("true","Bool"))=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(c9eccff94ecf6e810c600d4536bf1701485c13c3456c6b98c0cdab0fe7c5af14), org.kframework.attributes.Location(Location(1141,8,1141,33)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + Var'Unds'Gen0:SortBool{} + ),\and{R} ( + \in{SortBool{}, R} ( + X1:SortBool{}, + \dv{SortBool{}}("true") + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'Unds'orElseBool'Unds'{}(X0:SortBool{},X1:SortBool{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("c9eccff94ecf6e810c600d4536bf1701485c13c3456c6b98c0cdab0fe7c5af14"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1141,8,1141,33)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_orElseBool_`(#token("false","Bool"),K)=>K requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(eb8c85dac19a5951f694b65269c2b17c80d6d126d6a367958e4a5d736a880ecf), org.kframework.attributes.Location(Location(1142,8,1142,37)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + \dv{SortBool{}}("false") + ),\and{R} ( + \in{SortBool{}, R} ( + X1:SortBool{}, + VarK:SortBool{} + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'Unds'orElseBool'Unds'{}(X0:SortBool{},X1:SortBool{}), + \and{SortBool{}} ( + VarK:SortBool{}, + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("eb8c85dac19a5951f694b65269c2b17c80d6d126d6a367958e4a5d736a880ecf"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1142,8,1142,37)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_orElseBool_`(#token("true","Bool"),_Gen0)=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(354bd0860c7f38b59e285c935fd2ea553ebddbabb4973342ad25f0dac6ea7bf6), org.kframework.attributes.Location(Location(1140,8,1140,33)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + \dv{SortBool{}}("true") + ),\and{R} ( + \in{SortBool{}, R} ( + X1:SortBool{}, + Var'Unds'Gen0:SortBool{} + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'Unds'orElseBool'Unds'{}(X0:SortBool{},X1:SortBool{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("354bd0860c7f38b59e285c935fd2ea553ebddbabb4973342ad25f0dac6ea7bf6"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1140,8,1140,33)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_xorBool_`(B,B)=>#token("false","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(9a6d91cd75cd777b0d4db536b3e4b20578e74fe650e644b55294da95fd2dba7f), org.kframework.attributes.Location(Location(1133,8,1133,38)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + VarB:SortBool{} + ),\and{R} ( + \in{SortBool{}, R} ( + X1:SortBool{}, + VarB:SortBool{} + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'Unds'xorBool'Unds'{}(X0:SortBool{},X1:SortBool{}), + \and{SortBool{}} ( + \dv{SortBool{}}("false"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("9a6d91cd75cd777b0d4db536b3e4b20578e74fe650e644b55294da95fd2dba7f"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1133,8,1133,38)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_xorBool_`(B,#token("false","Bool"))=>B requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(7a2851f9d4ea4bd3f35070ee029fc3bdca36e361f7ee54addeff9d10ddeb7c75), org.kframework.attributes.Location(Location(1132,8,1132,38)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + VarB:SortBool{} + ),\and{R} ( + \in{SortBool{}, R} ( + X1:SortBool{}, + \dv{SortBool{}}("false") + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'Unds'xorBool'Unds'{}(X0:SortBool{},X1:SortBool{}), + \and{SortBool{}} ( + VarB:SortBool{}, + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("7a2851f9d4ea4bd3f35070ee029fc3bdca36e361f7ee54addeff9d10ddeb7c75"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1132,8,1132,38)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_xorBool_`(#token("false","Bool"),B)=>B requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(73513655c09a595907ab9d26d67e27f01d14a3435743b77000c02d10f35c05bf), org.kframework.attributes.Location(Location(1131,8,1131,38)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + \dv{SortBool{}}("false") + ),\and{R} ( + \in{SortBool{}, R} ( + X1:SortBool{}, + VarB:SortBool{} + ), + \top{R} () + ))), + \equals{SortBool{},R} ( + Lbl'Unds'xorBool'Unds'{}(X0:SortBool{},X1:SortBool{}), + \and{SortBool{}} ( + VarB:SortBool{}, + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("73513655c09a595907ab9d26d67e27f01d14a3435743b77000c02d10f35c05bf"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1131,8,1131,38)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `_|Set__SET_Set_Set_Set`(S1,S2)=>`_Set_`(S1,`Set:difference`(S2,S1)) requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(e9a710d8d1ca5c799420161879cbbff926de45a5bddd820d646f51d43eb67e62), concrete, org.kframework.attributes.Location(Location(749,8,749,45)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortSet{}, R} ( + X0:SortSet{}, + VarS1:SortSet{} + ),\and{R} ( + \in{SortSet{}, R} ( + X1:SortSet{}, + VarS2:SortSet{} + ), + \top{R} () + ))), + \equals{SortSet{},R} ( + Lbl'UndsPipe'Set'UndsUnds'SET'Unds'Set'Unds'Set'Unds'Set{}(X0:SortSet{},X1:SortSet{}), + \and{SortSet{}} ( + Lbl'Unds'Set'Unds'{}(VarS1:SortSet{},LblSet'Coln'difference{}(VarS2:SortSet{},VarS1:SortSet{})), + \top{SortSet{}}()))) + [UNIQUE'Unds'ID{}("e9a710d8d1ca5c799420161879cbbff926de45a5bddd820d646f51d43eb67e62"), concrete{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(749,8,749,45)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `bitRangeInt(_,_,_)_INT-COMMON_Int_Int_Int_Int`(I,IDX,LEN)=>`_modInt_`(`_>>Int_`(I,IDX),`_<`_+Int_`(#token("1","Int"),`countAllOccurrences(_,_)_STRING-COMMON_Int_String_String`(`substrString(_,_,_)_STRING-COMMON_String_String_Int_Int`(Source,`_+Int_`(`findString(_,_,_)_STRING-COMMON_Int_String_String_Int`(Source,ToCount,#token("0","Int")),`lengthString(_)_STRING-COMMON_Int_String`(ToCount)),`lengthString(_)_STRING-COMMON_Int_String`(Source)),ToCount)) requires `_>=Int_`(`findString(_,_,_)_STRING-COMMON_Int_String_String_Int`(Source,ToCount,#token("0","Int")),#token("0","Int")) ensures #token("true","Bool") [UNIQUE_ID(628cff029a6d79e4c99999c0309f91ab8cb12f0ba549bb3faa850f96304c970e), org.kframework.attributes.Location(Location(1874,8,1875,60)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody "requires" Bool [klabel(#ruleRequires), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \equals{SortBool{},R}( + Lbl'Unds-GT-Eqls'Int'Unds'{}(LblfindString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String'Unds'Int{}(VarSource:SortString{},VarToCount:SortString{},\dv{SortInt{}}("0")),\dv{SortInt{}}("0")), + \dv{SortBool{}}("true")), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + VarSource:SortString{} + ),\and{R} ( + \in{SortString{}, R} ( + X1:SortString{}, + VarToCount:SortString{} + ), + \top{R} () + ))), + \equals{SortInt{},R} ( + LblcountAllOccurrences'LParUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String{}(X0:SortString{},X1:SortString{}), + \and{SortInt{}} ( + Lbl'UndsPlus'Int'Unds'{}(\dv{SortInt{}}("1"),LblcountAllOccurrences'LParUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String{}(LblsubstrString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'Int'Unds'Int{}(VarSource:SortString{},Lbl'UndsPlus'Int'Unds'{}(LblfindString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String'Unds'Int{}(VarSource:SortString{},VarToCount:SortString{},\dv{SortInt{}}("0")),LbllengthString'LParUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String{}(VarToCount:SortString{})),LbllengthString'LParUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String{}(VarSource:SortString{})),VarToCount:SortString{})), + \top{SortInt{}}()))) + [UNIQUE'Unds'ID{}("628cff029a6d79e4c99999c0309f91ab8cb12f0ba549bb3faa850f96304c970e"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1874,8,1875,60)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody \"requires\" Bool [klabel(#ruleRequires), symbol]")] + +// rule `countAllOccurrences(_,_)_STRING-COMMON_Int_String_String`(Source,ToCount)=>#token("0","Int") requires `_`#if_#then_#else_#fi_K-EQUAL-SYNTAX_Sort_Bool_Sort_Sort`{Int}(`_==Int_`(`findString(_,_,_)_STRING-COMMON_Int_String_String_Int`(S1,`substrString(_,_,_)_STRING-COMMON_String_String_Int_Int`(S2,#token("0","Int"),#token("1","Int")),I),#token("-1","Int")),`findChar(_,_,_)_STRING-COMMON_Int_String_String_Int`(S1,`substrString(_,_,_)_STRING-COMMON_String_String_Int_Int`(S2,#token("1","Int"),`lengthString(_)_STRING-COMMON_Int_String`(S2)),I),`#if_#then_#else_#fi_K-EQUAL-SYNTAX_Sort_Bool_Sort_Sort`{Int}(`_==Int_`(`findChar(_,_,_)_STRING-COMMON_Int_String_String_Int`(S1,`substrString(_,_,_)_STRING-COMMON_String_String_Int_Int`(S2,#token("1","Int"),`lengthString(_)_STRING-COMMON_Int_String`(S2)),I),#token("-1","Int")),`findString(_,_,_)_STRING-COMMON_Int_String_String_Int`(S1,`substrString(_,_,_)_STRING-COMMON_String_String_Int_Int`(S2,#token("0","Int"),#token("1","Int")),I),`minInt(_,_)_INT-COMMON_Int_Int_Int`(`findString(_,_,_)_STRING-COMMON_Int_String_String_Int`(S1,`substrString(_,_,_)_STRING-COMMON_String_String_Int_Int`(S2,#token("0","Int"),#token("1","Int")),I),`findChar(_,_,_)_STRING-COMMON_Int_String_String_Int`(S1,`substrString(_,_,_)_STRING-COMMON_String_String_Int_Int`(S2,#token("1","Int"),`lengthString(_)_STRING-COMMON_Int_String`(S2)),I)))) requires `_=/=String__STRING-COMMON_Bool_String_String`(S2,#token("\"\"","String")) ensures #token("true","Bool") [UNIQUE_ID(9a3b7d1924363894c859ceb6bcec34fb944f01a5e0c90679d41b8430990b7295), org.kframework.attributes.Location(Location(1867,8,1867,431)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody "requires" Bool [klabel(#ruleRequires), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \equals{SortBool{},R}( + Lbl'UndsEqlsSlshEqls'String'UndsUnds'STRING-COMMON'Unds'Bool'Unds'String'Unds'String{}(VarS2:SortString{},\dv{SortString{}}("")), + \dv{SortBool{}}("true")), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + VarS1:SortString{} + ),\and{R} ( + \in{SortString{}, R} ( + X1:SortString{}, + VarS2:SortString{} + ),\and{R} ( + \in{SortInt{}, R} ( + X2:SortInt{}, + VarI:SortInt{} + ), + \top{R} () + )))), + \equals{SortInt{},R} ( + LblfindChar'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String'Unds'Int{}(X0:SortString{},X1:SortString{},X2:SortInt{}), + \and{SortInt{}} ( + Lbl'Hash'if'UndsHash'then'UndsHash'else'UndsHash'fi'Unds'K-EQUAL-SYNTAX'Unds'Sort'Unds'Bool'Unds'Sort'Unds'Sort{SortInt{}}(Lbl'UndsEqlsEqls'Int'Unds'{}(LblfindString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String'Unds'Int{}(VarS1:SortString{},LblsubstrString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'Int'Unds'Int{}(VarS2:SortString{},\dv{SortInt{}}("0"),\dv{SortInt{}}("1")),VarI:SortInt{}),\dv{SortInt{}}("-1")),LblfindChar'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String'Unds'Int{}(VarS1:SortString{},LblsubstrString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'Int'Unds'Int{}(VarS2:SortString{},\dv{SortInt{}}("1"),LbllengthString'LParUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String{}(VarS2:SortString{})),VarI:SortInt{}),Lbl'Hash'if'UndsHash'then'UndsHash'else'UndsHash'fi'Unds'K-EQUAL-SYNTAX'Unds'Sort'Unds'Bool'Unds'Sort'Unds'Sort{SortInt{}}(Lbl'UndsEqlsEqls'Int'Unds'{}(LblfindChar'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String'Unds'Int{}(VarS1:SortString{},LblsubstrString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'Int'Unds'Int{}(VarS2:SortString{},\dv{SortInt{}}("1"),LbllengthString'LParUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String{}(VarS2:SortString{})),VarI:SortInt{}),\dv{SortInt{}}("-1")),LblfindString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String'Unds'Int{}(VarS1:SortString{},LblsubstrString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'Int'Unds'Int{}(VarS2:SortString{},\dv{SortInt{}}("0"),\dv{SortInt{}}("1")),VarI:SortInt{}),LblminInt'LParUndsCommUndsRParUnds'INT-COMMON'Unds'Int'Unds'Int'Unds'Int{}(LblfindString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String'Unds'Int{}(VarS1:SortString{},LblsubstrString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'Int'Unds'Int{}(VarS2:SortString{},\dv{SortInt{}}("0"),\dv{SortInt{}}("1")),VarI:SortInt{}),LblfindChar'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String'Unds'Int{}(VarS1:SortString{},LblsubstrString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'Int'Unds'Int{}(VarS2:SortString{},\dv{SortInt{}}("1"),LbllengthString'LParUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String{}(VarS2:SortString{})),VarI:SortInt{})))), + \top{SortInt{}}()))) + [UNIQUE'Unds'ID{}("9a3b7d1924363894c859ceb6bcec34fb944f01a5e0c90679d41b8430990b7295"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1867,8,1867,431)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody \"requires\" Bool [klabel(#ruleRequires), symbol]")] + +// rule `findChar(_,_,_)_STRING-COMMON_Int_String_String_Int`(_Gen0,#token("\"\"","String"),_Gen1)=>#token("-1","Int") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(5a6cf981f0ec2494854cd3e517b0cf645a1c9762c92a14849adfca9a6a553117), org.kframework.attributes.Location(Location(1868,8,1868,32)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + Var'Unds'Gen0:SortString{} + ),\and{R} ( + \in{SortString{}, R} ( + X1:SortString{}, + \dv{SortString{}}("") + ),\and{R} ( + \in{SortInt{}, R} ( + X2:SortInt{}, + Var'Unds'Gen1:SortInt{} + ), + \top{R} () + )))), + \equals{SortInt{},R} ( + LblfindChar'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String'Unds'Int{}(X0:SortString{},X1:SortString{},X2:SortInt{}), + \and{SortInt{}} ( + \dv{SortInt{}}("-1"), + \top{SortInt{}}()))) + [UNIQUE'Unds'ID{}("5a6cf981f0ec2494854cd3e517b0cf645a1c9762c92a14849adfca9a6a553117"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1868,8,1868,32)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `freshInt(_)_INT_Int_Int`(I)=>I requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(cf2cb8f038b4bdc4edb1334a3b8ced9cd296a7af43f0a1916e082a4e1aefa08b), org.kframework.attributes.Location(Location(1433,8,1433,28)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortInt{}, R} ( + X0:SortInt{}, + VarI:SortInt{} + ), + \top{R} () + )), + \equals{SortInt{},R} ( + LblfreshInt'LParUndsRParUnds'INT'Unds'Int'Unds'Int{}(X0:SortInt{}), + \and{SortInt{}} ( + VarI:SortInt{}, + \top{SortInt{}}()))) + [UNIQUE'Unds'ID{}("cf2cb8f038b4bdc4edb1334a3b8ced9cd296a7af43f0a1916e082a4e1aefa08b"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1433,8,1433,28)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule getGeneratedCounterCell(``(_Gen0,_Gen1,Cell))=>Cell requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(6aaa6e2dcc27f3f1c36a11a988ed5674f7b6892c35cde7937bcb682488aaf8e1)] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortGeneratedTopCell{}, R} ( + X0:SortGeneratedTopCell{}, + Lbl'-LT-'generatedTop'-GT-'{}(Var'Unds'Gen0:SortKCell{},Var'Unds'Gen1:SortOutCell{},VarCell:SortGeneratedCounterCell{}) + ), + \top{R} () + )), + \equals{SortGeneratedCounterCell{},R} ( + LblgetGeneratedCounterCell{}(X0:SortGeneratedTopCell{}), + \and{SortGeneratedCounterCell{}} ( + VarCell:SortGeneratedCounterCell{}, + \top{SortGeneratedCounterCell{}}()))) + [UNIQUE'Unds'ID{}("6aaa6e2dcc27f3f1c36a11a988ed5674f7b6892c35cde7937bcb682488aaf8e1")] + +// rule `go(_)_UNICODE_String_String`(S)=>S requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(d22c65b3fea9a1ad2fed9e917a1b1835190dc91016f910b558ac8d96f3793d13), org.kframework.attributes.Location(Location(24,10,24,27)), org.kframework.attributes.Source(Source(/home/sguest/work/k-test/unicode.k)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]), owise] + axiom{R} \implies{R} ( + \and{R} ( + \not{R} ( + \or{R} ( + \and{R} ( + \top{R}(), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + \dv{SortString{}}("\u0939") + ), + \top{R} () + ) + ), + \or{R} ( + \and{R} ( + \top{R}(), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + \dv{SortString{}}("\U00010348") + ), + \top{R} () + ) + ), + \or{R} ( + \and{R} ( + \top{R}(), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + \dv{SortString{}}("\ud55c") + ), + \top{R} () + ) + ), + \or{R} ( + \and{R} ( + \top{R}(), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + \dv{SortString{}}("\x24") + ), + \top{R} () + ) + ), + \or{R} ( + \and{R} ( + \top{R}(), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + \dv{SortString{}}("\xa3") + ), + \top{R} () + ) + ), + \or{R} ( + \and{R} ( + \top{R}(), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + \dv{SortString{}}("\u0418") + ), + \top{R} () + ) + ), + \or{R} ( + \and{R} ( + \top{R}(), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + \dv{SortString{}}("A\x00B") + ), + \top{R} () + ) + ), + \or{R} ( + \and{R} ( + \top{R}(), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + \dv{SortString{}}("\u20AC") + ), + \top{R} () + ) + ), + \bottom{R}() + )))))))) + ), + \and{R}( + \top{R}(), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + VarS:SortString{} + ), + \top{R} () + ) + )), + \equals{SortString{},R} ( + Lblgo'LParUndsRParUnds'UNICODE'Unds'String'Unds'String{}(X0:SortString{}), + \and{SortString{}} ( + VarS:SortString{}, + \top{SortString{}}()))) + [UNIQUE'Unds'ID{}("d22c65b3fea9a1ad2fed9e917a1b1835190dc91016f910b558ac8d96f3793d13"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(24,10,24,27)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k-test/unicode.k)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]"), owise{}()] + +// rule `go(_)_UNICODE_String_String`(#token("\"A\\x00B\"","String"))=>#token("\"goodA\\x00B\"","String") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(71043d3ede2408017cf8c6159148aa53cd52fd19fc34a0349410015214aaca5c), org.kframework.attributes.Location(Location(26,10,26,38)), org.kframework.attributes.Source(Source(/home/sguest/work/k-test/unicode.k)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + \dv{SortString{}}("A\x00B") + ), + \top{R} () + )), + \equals{SortString{},R} ( + Lblgo'LParUndsRParUnds'UNICODE'Unds'String'Unds'String{}(X0:SortString{}), + \and{SortString{}} ( + \dv{SortString{}}("goodA\x00B"), + \top{SortString{}}()))) + [UNIQUE'Unds'ID{}("71043d3ede2408017cf8c6159148aa53cd52fd19fc34a0349410015214aaca5c"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(26,10,26,38)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k-test/unicode.k)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `go(_)_UNICODE_String_String`(#token("\"\\u0418\"","String"))=>#token("\"good\u0418\"","String") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(fbafa094e2f61c88f7b06a39ca3ae8df73746c5f8e04e70398eca111b8dc9651), org.kframework.attributes.Location(Location(32,10,32,33)), org.kframework.attributes.Source(Source(/home/sguest/work/k-test/unicode.k)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + \dv{SortString{}}("\u0418") + ), + \top{R} () + )), + \equals{SortString{},R} ( + Lblgo'LParUndsRParUnds'UNICODE'Unds'String'Unds'String{}(X0:SortString{}), + \and{SortString{}} ( + \dv{SortString{}}("good\u0418"), + \top{SortString{}}()))) + [UNIQUE'Unds'ID{}("fbafa094e2f61c88f7b06a39ca3ae8df73746c5f8e04e70398eca111b8dc9651"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(32,10,32,33)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k-test/unicode.k)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `go(_)_UNICODE_String_String`(#token("\"\\u20AC\"","String"))=>#token("\"good\u20ac\"","String") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(7771d4317c9be72f47df43be5f6579430419716cd150084e38958b6a6ff3ca39), org.kframework.attributes.Location(Location(36,10,36,33)), org.kframework.attributes.Source(Source(/home/sguest/work/k-test/unicode.k)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + \dv{SortString{}}("\u20AC") + ), + \top{R} () + )), + \equals{SortString{},R} ( + Lblgo'LParUndsRParUnds'UNICODE'Unds'String'Unds'String{}(X0:SortString{}), + \and{SortString{}} ( + \dv{SortString{}}("good\u20ac"), + \top{SortString{}}()))) + [UNIQUE'Unds'ID{}("7771d4317c9be72f47df43be5f6579430419716cd150084e38958b6a6ff3ca39"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(36,10,36,33)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k-test/unicode.k)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `go(_)_UNICODE_String_String`(#token("\"\\x24\"","String"))=>#token("\"good$\"","String") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(fb84627cea8a28fdaf8481ff6de1c8779072e531659e70c0d69d766e571a1678), org.kframework.attributes.Location(Location(28,10,28,31)), org.kframework.attributes.Source(Source(/home/sguest/work/k-test/unicode.k)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + \dv{SortString{}}("\x24") + ), + \top{R} () + )), + \equals{SortString{},R} ( + Lblgo'LParUndsRParUnds'UNICODE'Unds'String'Unds'String{}(X0:SortString{}), + \and{SortString{}} ( + \dv{SortString{}}("good$"), + \top{SortString{}}()))) + [UNIQUE'Unds'ID{}("fb84627cea8a28fdaf8481ff6de1c8779072e531659e70c0d69d766e571a1678"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(28,10,28,31)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k-test/unicode.k)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `go(_)_UNICODE_String_String`(#token("\"\xa3\"","String"))=>#token("\"good\\xA3\"","String") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(07b38bfdc0815eb3651cea393611a4ccac29025d30164f68d762a05456838c63), org.kframework.attributes.Location(Location(30,10,30,31)), org.kframework.attributes.Source(Source(/home/sguest/work/k-test/unicode.k)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + \dv{SortString{}}("\xa3") + ), + \top{R} () + )), + \equals{SortString{},R} ( + Lblgo'LParUndsRParUnds'UNICODE'Unds'String'Unds'String{}(X0:SortString{}), + \and{SortString{}} ( + \dv{SortString{}}("good\xA3"), + \top{SortString{}}()))) + [UNIQUE'Unds'ID{}("07b38bfdc0815eb3651cea393611a4ccac29025d30164f68d762a05456838c63"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(30,10,30,31)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k-test/unicode.k)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `go(_)_UNICODE_String_String`(#token("\"\u0939\"","String"))=>#token("\"good\\u0939\"","String") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(fee75844e5dca4a1b9b8cbccbac1a912ebde99028be4cd05a8e3d6d1b29fdd15), org.kframework.attributes.Location(Location(34,10,34,33)), org.kframework.attributes.Source(Source(/home/sguest/work/k-test/unicode.k)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + \dv{SortString{}}("\u0939") + ), + \top{R} () + )), + \equals{SortString{},R} ( + Lblgo'LParUndsRParUnds'UNICODE'Unds'String'Unds'String{}(X0:SortString{}), + \and{SortString{}} ( + \dv{SortString{}}("good\u0939"), + \top{SortString{}}()))) + [UNIQUE'Unds'ID{}("fee75844e5dca4a1b9b8cbccbac1a912ebde99028be4cd05a8e3d6d1b29fdd15"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(34,10,34,33)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k-test/unicode.k)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `go(_)_UNICODE_String_String`(#token("\"\ud55c\"","String"))=>#token("\"good\\uD55C\"","String") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(7cffdc95dfebe483c43f064c48fc0885654c155659647ab1062778af30538086), org.kframework.attributes.Location(Location(38,10,38,33)), org.kframework.attributes.Source(Source(/home/sguest/work/k-test/unicode.k)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + \dv{SortString{}}("\ud55c") + ), + \top{R} () + )), + \equals{SortString{},R} ( + Lblgo'LParUndsRParUnds'UNICODE'Unds'String'Unds'String{}(X0:SortString{}), + \and{SortString{}} ( + \dv{SortString{}}("good\uD55C"), + \top{SortString{}}()))) + [UNIQUE'Unds'ID{}("7cffdc95dfebe483c43f064c48fc0885654c155659647ab1062778af30538086"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(38,10,38,33)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k-test/unicode.k)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `go(_)_UNICODE_String_String`(#token("\"\U00010348\"","String"))=>#token("\"good\\U00010348\"","String") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(70ba7b6392f6843e1466cdc510478cab286524e8c8b1962181a2366cf8d15b92), org.kframework.attributes.Location(Location(40,10,40,36)), org.kframework.attributes.Source(Source(/home/sguest/work/k-test/unicode.k)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + \dv{SortString{}}("\U00010348") + ), + \top{R} () + )), + \equals{SortString{},R} ( + Lblgo'LParUndsRParUnds'UNICODE'Unds'String'Unds'String{}(X0:SortString{}), + \and{SortString{}} ( + \dv{SortString{}}("good\U00010348"), + \top{SortString{}}()))) + [UNIQUE'Unds'ID{}("70ba7b6392f6843e1466cdc510478cab286524e8c8b1962181a2366cf8d15b92"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(40,10,40,36)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k-test/unicode.k)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `goAll(_)_UNICODE_Strings_Strings`(`.List{"_,__UNICODE-SYNTAX_Strings_String_Strings"}_Strings`(.KList) #as _Gen0)=>_Gen0 requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(880e6750e24d9237074c4e91f38140294327faf9e02bd9e79394200e55705e8a), org.kframework.attributes.Location(Location(21,10,21,37)), org.kframework.attributes.Source(Source(/home/sguest/work/k-test/unicode.k)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortStrings{}, R} ( + X0:SortStrings{}, + \and{SortStrings{}}(Lbl'Stop'List'LBraQuotUndsCommUndsUnds'UNICODE-SYNTAX'Unds'Strings'Unds'String'Unds'Strings'QuotRBraUnds'Strings{}(),Var'Unds'Gen0:SortStrings{}) + ), + \top{R} () + )), + \equals{SortStrings{},R} ( + LblgoAll'LParUndsRParUnds'UNICODE'Unds'Strings'Unds'Strings{}(X0:SortStrings{}), + \and{SortStrings{}} ( + Var'Unds'Gen0:SortStrings{}, + \top{SortStrings{}}()))) + [UNIQUE'Unds'ID{}("880e6750e24d9237074c4e91f38140294327faf9e02bd9e79394200e55705e8a"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(21,10,21,37)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k-test/unicode.k)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `goAll(_)_UNICODE_Strings_Strings`(`_,__UNICODE-SYNTAX_Strings_String_Strings`(S,SS))=>`_,__UNICODE-SYNTAX_Strings_String_Strings`(`go(_)_UNICODE_String_String`(S),`goAll(_)_UNICODE_Strings_Strings`(SS)) requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(85e10f7de32f841efba01b2ab6331dc3c7431ed6425b01c1f0867f25002cc9dd), org.kframework.attributes.Location(Location(22,10,22,58)), org.kframework.attributes.Source(Source(/home/sguest/work/k-test/unicode.k)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortStrings{}, R} ( + X0:SortStrings{}, + Lbl'UndsCommUndsUnds'UNICODE-SYNTAX'Unds'Strings'Unds'String'Unds'Strings{}(VarS:SortString{},VarSS:SortStrings{}) + ), + \top{R} () + )), + \equals{SortStrings{},R} ( + LblgoAll'LParUndsRParUnds'UNICODE'Unds'Strings'Unds'Strings{}(X0:SortStrings{}), + \and{SortStrings{}} ( + Lbl'UndsCommUndsUnds'UNICODE-SYNTAX'Unds'Strings'Unds'String'Unds'Strings{}(Lblgo'LParUndsRParUnds'UNICODE'Unds'String'Unds'String{}(VarS:SortString{}),LblgoAll'LParUndsRParUnds'UNICODE'Unds'Strings'Unds'Strings{}(VarSS:SortStrings{})), + \top{SortStrings{}}()))) + [UNIQUE'Unds'ID{}("85e10f7de32f841efba01b2ab6331dc3c7431ed6425b01c1f0867f25002cc9dd"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(22,10,22,58)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k-test/unicode.k)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule initGeneratedCounterCell(.KList)=>``(#token("0","Int")) requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(5de11f6b50c4684c0e05b773f809d756f4ce9c03a4f24e23a9cddaf3fa31f553), initializer] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + + \top{R} () + ), + \equals{SortGeneratedCounterCell{},R} ( + LblinitGeneratedCounterCell{}(), + \and{SortGeneratedCounterCell{}} ( + Lbl'-LT-'generatedCounter'-GT-'{}(\dv{SortInt{}}("0")), + \top{SortGeneratedCounterCell{}}()))) + [UNIQUE'Unds'ID{}("5de11f6b50c4684c0e05b773f809d756f4ce9c03a4f24e23a9cddaf3fa31f553"), initializer{}()] + +// rule initGeneratedTopCell(Init)=>``(initKCell(Init),initOutCell(.KList),initGeneratedCounterCell(.KList)) requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(5242c5089028cdbcb655820844e6b76ed5907cc0bebd3db45d422986be5c0702), initializer] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortMap{}, R} ( + X0:SortMap{}, + VarInit:SortMap{} + ), + \top{R} () + )), + \equals{SortGeneratedTopCell{},R} ( + LblinitGeneratedTopCell{}(X0:SortMap{}), + \and{SortGeneratedTopCell{}} ( + Lbl'-LT-'generatedTop'-GT-'{}(LblinitKCell{}(VarInit:SortMap{}),LblinitOutCell{}(),LblinitGeneratedCounterCell{}()), + \top{SortGeneratedTopCell{}}()))) + [UNIQUE'Unds'ID{}("5242c5089028cdbcb655820844e6b76ed5907cc0bebd3db45d422986be5c0702"), initializer{}()] + +// rule initKCell(Init)=>``(inj{Strings,KItem}(`project:Strings`(`Map:lookup`(Init,inj{KConfigVar,KItem}(#token("$PGM","KConfigVar")))))) requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(aa88c546338a8a13ad22bcc495aed0bfb77f3e7c05cc8cb59f8bec5a54c46a4c), initializer] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortMap{}, R} ( + X0:SortMap{}, + VarInit:SortMap{} + ), + \top{R} () + )), + \equals{SortKCell{},R} ( + LblinitKCell{}(X0:SortMap{}), + \and{SortKCell{}} ( + Lbl'-LT-'k'-GT-'{}(kseq{}(inj{SortStrings{}, SortKItem{}}(Lblproject'Coln'Strings{}(kseq{}(LblMap'Coln'lookup{}(VarInit:SortMap{},inj{SortKConfigVar{}, SortKItem{}}(\dv{SortKConfigVar{}}("$PGM"))),dotk{}()))),dotk{}())), + \top{SortKCell{}}()))) + [UNIQUE'Unds'ID{}("aa88c546338a8a13ad22bcc495aed0bfb77f3e7c05cc8cb59f8bec5a54c46a4c"), initializer{}()] + +// rule initOutCell(.KList)=>``(`.List{"_,__UNICODE-SYNTAX_Strings_String_Strings"}_Strings`(.KList)) requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(b71395d72fbcc892d3d4990ec1af03c0d37bcbb0fd7aec92c0d374ef12820e87), initializer] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + + \top{R} () + ), + \equals{SortOutCell{},R} ( + LblinitOutCell{}(), + \and{SortOutCell{}} ( + Lbl'-LT-'out'-GT-'{}(Lbl'Stop'List'LBraQuotUndsCommUndsUnds'UNICODE-SYNTAX'Unds'Strings'Unds'String'Unds'Strings'QuotRBraUnds'Strings{}()), + \top{SortOutCell{}}()))) + [UNIQUE'Unds'ID{}("b71395d72fbcc892d3d4990ec1af03c0d37bcbb0fd7aec92c0d374ef12820e87"), initializer{}()] + +// rule isBool(K)=>#token("false","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(7f8273ebd616814dbf1acdd96b9534fbaa5b0491bfd05a61916e5015ad4a37ab), owise] + axiom{R} \implies{R} ( + \and{R} ( + \not{R} ( + \or{R} ( + \exists{R} (Var'Unds'Gen1:SortBool{}, + \and{R} ( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortBool{}, SortKItem{}}(Var'Unds'Gen1:SortBool{}),dotk{}()) + ), + \top{R} () + ) + )), + \bottom{R}() + ) + ), + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + VarK:SortK{} + ), + \top{R} () + ) + )), + \equals{SortBool{},R} ( + LblisBool{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("false"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("7f8273ebd616814dbf1acdd96b9534fbaa5b0491bfd05a61916e5015ad4a37ab"), owise{}()] + +// rule isBool(inj{Bool,KItem}(Bool))=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(dadad716b2f6a82fa4b2cc8f903a1b8f1f6e8cfa63f18b72a7cb35110bdcff77)] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortBool{}, SortKItem{}}(VarBool:SortBool{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortBool{},R} ( + LblisBool{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("dadad716b2f6a82fa4b2cc8f903a1b8f1f6e8cfa63f18b72a7cb35110bdcff77")] + +// rule isFloat(K)=>#token("false","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(2a794de414a5b222c2b378d31aee70dd82d84237a3ab65881c92100c0bf5cb57), owise] + axiom{R} \implies{R} ( + \and{R} ( + \not{R} ( + \or{R} ( + \exists{R} (Var'Unds'Gen1:SortFloat{}, + \and{R} ( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortFloat{}, SortKItem{}}(Var'Unds'Gen1:SortFloat{}),dotk{}()) + ), + \top{R} () + ) + )), + \bottom{R}() + ) + ), + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + VarK:SortK{} + ), + \top{R} () + ) + )), + \equals{SortBool{},R} ( + LblisFloat{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("false"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("2a794de414a5b222c2b378d31aee70dd82d84237a3ab65881c92100c0bf5cb57"), owise{}()] + +// rule isFloat(inj{Float,KItem}(Float))=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(d74a36c34f45e0bf74d89fdd362f124478ab18934b5786ff4aabfe527643c5f0)] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortFloat{}, SortKItem{}}(VarFloat:SortFloat{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortBool{},R} ( + LblisFloat{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("d74a36c34f45e0bf74d89fdd362f124478ab18934b5786ff4aabfe527643c5f0")] + +// rule isGeneratedCounterCell(K)=>#token("false","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(7d501e1637f26769ad3b9439efef0285daa79523b0d071b3a792972ce92e4fe2), owise] + axiom{R} \implies{R} ( + \and{R} ( + \not{R} ( + \or{R} ( + \exists{R} (Var'Unds'Gen1:SortGeneratedCounterCell{}, + \and{R} ( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortGeneratedCounterCell{}, SortKItem{}}(Var'Unds'Gen1:SortGeneratedCounterCell{}),dotk{}()) + ), + \top{R} () + ) + )), + \bottom{R}() + ) + ), + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + VarK:SortK{} + ), + \top{R} () + ) + )), + \equals{SortBool{},R} ( + LblisGeneratedCounterCell{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("false"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("7d501e1637f26769ad3b9439efef0285daa79523b0d071b3a792972ce92e4fe2"), owise{}()] + +// rule isGeneratedCounterCell(inj{GeneratedCounterCell,KItem}(GeneratedCounterCell))=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(f7b6a3dbee5a80d5eeba727f40009876995660d4052a45fc50c55f88c5fc1a7c)] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortGeneratedCounterCell{}, SortKItem{}}(VarGeneratedCounterCell:SortGeneratedCounterCell{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortBool{},R} ( + LblisGeneratedCounterCell{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("f7b6a3dbee5a80d5eeba727f40009876995660d4052a45fc50c55f88c5fc1a7c")] + +// rule isGeneratedTopCell(K)=>#token("false","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(ec16314688c4b2d204af490e243a3e83a2e82fbc74988c3574b997cc9ca56816), owise] + axiom{R} \implies{R} ( + \and{R} ( + \not{R} ( + \or{R} ( + \exists{R} (Var'Unds'Gen1:SortGeneratedTopCell{}, + \and{R} ( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortGeneratedTopCell{}, SortKItem{}}(Var'Unds'Gen1:SortGeneratedTopCell{}),dotk{}()) + ), + \top{R} () + ) + )), + \bottom{R}() + ) + ), + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + VarK:SortK{} + ), + \top{R} () + ) + )), + \equals{SortBool{},R} ( + LblisGeneratedTopCell{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("false"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("ec16314688c4b2d204af490e243a3e83a2e82fbc74988c3574b997cc9ca56816"), owise{}()] + +// rule isGeneratedTopCell(inj{GeneratedTopCell,KItem}(GeneratedTopCell))=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(3bcf423225700e329d0533cfd806eb9bab91f9d8de0979c8d8e381fe5d076bb2)] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortGeneratedTopCell{}, SortKItem{}}(VarGeneratedTopCell:SortGeneratedTopCell{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortBool{},R} ( + LblisGeneratedTopCell{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("3bcf423225700e329d0533cfd806eb9bab91f9d8de0979c8d8e381fe5d076bb2")] + +// rule isGeneratedTopCellFragment(K)=>#token("false","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(1f022b25cc5a2adbe99fbae6b50007c803258a5749eb01e05c86096f7b35c0df), owise] + axiom{R} \implies{R} ( + \and{R} ( + \not{R} ( + \or{R} ( + \exists{R} (Var'Unds'Gen0:SortGeneratedTopCellFragment{}, + \and{R} ( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortGeneratedTopCellFragment{}, SortKItem{}}(Var'Unds'Gen0:SortGeneratedTopCellFragment{}),dotk{}()) + ), + \top{R} () + ) + )), + \bottom{R}() + ) + ), + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + VarK:SortK{} + ), + \top{R} () + ) + )), + \equals{SortBool{},R} ( + LblisGeneratedTopCellFragment{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("false"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("1f022b25cc5a2adbe99fbae6b50007c803258a5749eb01e05c86096f7b35c0df"), owise{}()] + +// rule isGeneratedTopCellFragment(inj{GeneratedTopCellFragment,KItem}(GeneratedTopCellFragment))=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(559f2cdc0ab425bb065cc3174f4a1af4d9ca834f762a814cf3dfbf9a9d7f8271)] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortGeneratedTopCellFragment{}, SortKItem{}}(VarGeneratedTopCellFragment:SortGeneratedTopCellFragment{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortBool{},R} ( + LblisGeneratedTopCellFragment{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("559f2cdc0ab425bb065cc3174f4a1af4d9ca834f762a814cf3dfbf9a9d7f8271")] + +// rule isInt(K)=>#token("false","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(5c9850befff40cc79151dbc5a8999b5ffaad767f244ed97f9f29b56b7170bf24), owise] + axiom{R} \implies{R} ( + \and{R} ( + \not{R} ( + \or{R} ( + \exists{R} (Var'Unds'Gen1:SortInt{}, + \and{R} ( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortInt{}, SortKItem{}}(Var'Unds'Gen1:SortInt{}),dotk{}()) + ), + \top{R} () + ) + )), + \bottom{R}() + ) + ), + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + VarK:SortK{} + ), + \top{R} () + ) + )), + \equals{SortBool{},R} ( + LblisInt{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("false"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("5c9850befff40cc79151dbc5a8999b5ffaad767f244ed97f9f29b56b7170bf24"), owise{}()] + +// rule isInt(inj{Int,KItem}(Int))=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(92664aa821c8898ff16b4e72ad0bdf363f755c7660d28dcb69c129a2c94bc6b5)] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortInt{}, SortKItem{}}(VarInt:SortInt{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortBool{},R} ( + LblisInt{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("92664aa821c8898ff16b4e72ad0bdf363f755c7660d28dcb69c129a2c94bc6b5")] + +// rule isK(K)=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(16ff77cff0ef50026a8b3f4614b87bda465701918596b7ad2280baffff56f847)] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + VarK:SortK{} + ), + \top{R} () + )), + \equals{SortBool{},R} ( + LblisK{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("16ff77cff0ef50026a8b3f4614b87bda465701918596b7ad2280baffff56f847")] + +// rule isKCell(K)=>#token("false","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(1668e9146ab7dd7867682198dd9dddc0c7c88d8f9fad9ed2366229fc4db18733), owise] + axiom{R} \implies{R} ( + \and{R} ( + \not{R} ( + \or{R} ( + \exists{R} (Var'Unds'Gen0:SortKCell{}, + \and{R} ( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortKCell{}, SortKItem{}}(Var'Unds'Gen0:SortKCell{}),dotk{}()) + ), + \top{R} () + ) + )), + \bottom{R}() + ) + ), + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + VarK:SortK{} + ), + \top{R} () + ) + )), + \equals{SortBool{},R} ( + LblisKCell{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("false"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("1668e9146ab7dd7867682198dd9dddc0c7c88d8f9fad9ed2366229fc4db18733"), owise{}()] + +// rule isKCell(inj{KCell,KItem}(KCell))=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(2695222b1238f711f8a356c0a1bc0ac418d7bd78fd3282e7c60882e2631a46df)] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortKCell{}, SortKItem{}}(VarKCell:SortKCell{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortBool{},R} ( + LblisKCell{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("2695222b1238f711f8a356c0a1bc0ac418d7bd78fd3282e7c60882e2631a46df")] + +// rule isKCellOpt(K)=>#token("false","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(fa44a9c94132ade195fc2cb566fa82471e4592c977a49183ac2142c5062701ca), owise] + axiom{R} \implies{R} ( + \and{R} ( + \not{R} ( + \or{R} ( + \exists{R} (Var'Unds'Gen1:SortKCellOpt{}, + \and{R} ( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortKCellOpt{}, SortKItem{}}(Var'Unds'Gen1:SortKCellOpt{}),dotk{}()) + ), + \top{R} () + ) + )), + \bottom{R}() + ) + ), + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + VarK:SortK{} + ), + \top{R} () + ) + )), + \equals{SortBool{},R} ( + LblisKCellOpt{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("false"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("fa44a9c94132ade195fc2cb566fa82471e4592c977a49183ac2142c5062701ca"), owise{}()] + +// rule isKCellOpt(inj{KCellOpt,KItem}(KCellOpt))=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(1516473b1e153a368c273997543a4378ad451e5e828db8e289f4447f7e5228a5)] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortKCellOpt{}, SortKItem{}}(VarKCellOpt:SortKCellOpt{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortBool{},R} ( + LblisKCellOpt{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("1516473b1e153a368c273997543a4378ad451e5e828db8e289f4447f7e5228a5")] + +// rule isKConfigVar(K)=>#token("false","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(f1c02853e001635e66a06d14d1cd322a996f4acbe38a7f9c88df6c97ea6a4677), owise] + axiom{R} \implies{R} ( + \and{R} ( + \not{R} ( + \or{R} ( + \exists{R} (Var'Unds'Gen0:SortKConfigVar{}, + \and{R} ( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortKConfigVar{}, SortKItem{}}(Var'Unds'Gen0:SortKConfigVar{}),dotk{}()) + ), + \top{R} () + ) + )), + \bottom{R}() + ) + ), + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + VarK:SortK{} + ), + \top{R} () + ) + )), + \equals{SortBool{},R} ( + LblisKConfigVar{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("false"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("f1c02853e001635e66a06d14d1cd322a996f4acbe38a7f9c88df6c97ea6a4677"), owise{}()] + +// rule isKConfigVar(inj{KConfigVar,KItem}(KConfigVar))=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(0ef0a00bb321f2c2a62a3239327de70ecb8e907a950cd20034c46b84e040ebcd)] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortKConfigVar{}, SortKItem{}}(VarKConfigVar:SortKConfigVar{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortBool{},R} ( + LblisKConfigVar{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("0ef0a00bb321f2c2a62a3239327de70ecb8e907a950cd20034c46b84e040ebcd")] + +// rule isKItem(K)=>#token("false","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(f766beabd3e632a98e221201d003f26f45f1feef2aff6da0ab07edde06a5d99d), owise] + axiom{R} \implies{R} ( + \and{R} ( + \not{R} ( + \or{R} ( + \exists{R} (Var'Unds'Gen0:SortKItem{}, + \and{R} ( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(Var'Unds'Gen0:SortKItem{},dotk{}()) + ), + \top{R} () + ) + )), + \bottom{R}() + ) + ), + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + VarK:SortK{} + ), + \top{R} () + ) + )), + \equals{SortBool{},R} ( + LblisKItem{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("false"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("f766beabd3e632a98e221201d003f26f45f1feef2aff6da0ab07edde06a5d99d"), owise{}()] + +// rule isKItem(KItem)=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(ed3c25a7dab5e5fbc101589e2fa74ac91aa107f051d22a01378222d08643373c)] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(VarKItem:SortKItem{},dotk{}()) + ), + \top{R} () + )), + \equals{SortBool{},R} ( + LblisKItem{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("ed3c25a7dab5e5fbc101589e2fa74ac91aa107f051d22a01378222d08643373c")] + +// rule isList(K)=>#token("false","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(0b6d1ffc254fbf57473abfe22e81bcfa646561c43d4e2cc175eab60cfb2b68aa), owise] + axiom{R} \implies{R} ( + \and{R} ( + \not{R} ( + \or{R} ( + \exists{R} (Var'Unds'Gen1:SortList{}, + \and{R} ( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortList{}, SortKItem{}}(Var'Unds'Gen1:SortList{}),dotk{}()) + ), + \top{R} () + ) + )), + \bottom{R}() + ) + ), + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + VarK:SortK{} + ), + \top{R} () + ) + )), + \equals{SortBool{},R} ( + LblisList{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("false"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("0b6d1ffc254fbf57473abfe22e81bcfa646561c43d4e2cc175eab60cfb2b68aa"), owise{}()] + +// rule isList(inj{List,KItem}(List))=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(7d4dddf5bbdb61cfd11fb9be1071be7bd551cf186607cf6f493cfade3221c446)] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortList{}, SortKItem{}}(VarList:SortList{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortBool{},R} ( + LblisList{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("7d4dddf5bbdb61cfd11fb9be1071be7bd551cf186607cf6f493cfade3221c446")] + +// rule isMap(K)=>#token("false","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(5da72349a323db3019243ab26f08b728d336c1a52aecaa0bcb7de4adae14bd71), owise] + axiom{R} \implies{R} ( + \and{R} ( + \not{R} ( + \or{R} ( + \exists{R} (Var'Unds'Gen1:SortMap{}, + \and{R} ( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortMap{}, SortKItem{}}(Var'Unds'Gen1:SortMap{}),dotk{}()) + ), + \top{R} () + ) + )), + \bottom{R}() + ) + ), + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + VarK:SortK{} + ), + \top{R} () + ) + )), + \equals{SortBool{},R} ( + LblisMap{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("false"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("5da72349a323db3019243ab26f08b728d336c1a52aecaa0bcb7de4adae14bd71"), owise{}()] + +// rule isMap(inj{Map,KItem}(Map))=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(4879c0fcf6b7d7f3d6b751e4f460f8dced005a44ae5ff600cffcea784cf58795)] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortMap{}, SortKItem{}}(VarMap:SortMap{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortBool{},R} ( + LblisMap{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("4879c0fcf6b7d7f3d6b751e4f460f8dced005a44ae5ff600cffcea784cf58795")] + +// rule isOutCell(K)=>#token("false","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(62e83bb7fdd31b7fe15ad39ad7d360d3143e0dfae4b1c3216ca3cd7e01d2e946), owise] + axiom{R} \implies{R} ( + \and{R} ( + \not{R} ( + \or{R} ( + \exists{R} (Var'Unds'Gen1:SortOutCell{}, + \and{R} ( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortOutCell{}, SortKItem{}}(Var'Unds'Gen1:SortOutCell{}),dotk{}()) + ), + \top{R} () + ) + )), + \bottom{R}() + ) + ), + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + VarK:SortK{} + ), + \top{R} () + ) + )), + \equals{SortBool{},R} ( + LblisOutCell{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("false"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("62e83bb7fdd31b7fe15ad39ad7d360d3143e0dfae4b1c3216ca3cd7e01d2e946"), owise{}()] + +// rule isOutCell(inj{OutCell,KItem}(OutCell))=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(84e88ba77f0e5b3dd13caa9748cae0e3ac57d8509c1c36c6aa34a6e1fa572e02)] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortOutCell{}, SortKItem{}}(VarOutCell:SortOutCell{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortBool{},R} ( + LblisOutCell{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("84e88ba77f0e5b3dd13caa9748cae0e3ac57d8509c1c36c6aa34a6e1fa572e02")] + +// rule isOutCellOpt(K)=>#token("false","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(3cbf9a963d9657f23e7c6ac33fa389466575f311958451378f07901746c08900), owise] + axiom{R} \implies{R} ( + \and{R} ( + \not{R} ( + \or{R} ( + \exists{R} (Var'Unds'Gen0:SortOutCellOpt{}, + \and{R} ( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortOutCellOpt{}, SortKItem{}}(Var'Unds'Gen0:SortOutCellOpt{}),dotk{}()) + ), + \top{R} () + ) + )), + \bottom{R}() + ) + ), + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + VarK:SortK{} + ), + \top{R} () + ) + )), + \equals{SortBool{},R} ( + LblisOutCellOpt{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("false"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("3cbf9a963d9657f23e7c6ac33fa389466575f311958451378f07901746c08900"), owise{}()] + +// rule isOutCellOpt(inj{OutCellOpt,KItem}(OutCellOpt))=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(b91e75e9442987e15a1808b425a0c6e65dab2c15a73d30e90e8ad06fdcf7f447)] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortOutCellOpt{}, SortKItem{}}(VarOutCellOpt:SortOutCellOpt{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortBool{},R} ( + LblisOutCellOpt{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("b91e75e9442987e15a1808b425a0c6e65dab2c15a73d30e90e8ad06fdcf7f447")] + +// rule isSet(K)=>#token("false","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(4bb33358689dc4ec69171f146dc69c169560a878b09ca872d2c4da9e2dbd0d5e), owise] + axiom{R} \implies{R} ( + \and{R} ( + \not{R} ( + \or{R} ( + \exists{R} (Var'Unds'Gen1:SortSet{}, + \and{R} ( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortSet{}, SortKItem{}}(Var'Unds'Gen1:SortSet{}),dotk{}()) + ), + \top{R} () + ) + )), + \bottom{R}() + ) + ), + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + VarK:SortK{} + ), + \top{R} () + ) + )), + \equals{SortBool{},R} ( + LblisSet{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("false"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("4bb33358689dc4ec69171f146dc69c169560a878b09ca872d2c4da9e2dbd0d5e"), owise{}()] + +// rule isSet(inj{Set,KItem}(Set))=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(f205bc460bdb728b4c3458643699be30d519db4d8b13e80e2c27082b9e846e80)] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortSet{}, SortKItem{}}(VarSet:SortSet{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortBool{},R} ( + LblisSet{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("f205bc460bdb728b4c3458643699be30d519db4d8b13e80e2c27082b9e846e80")] + +// rule isString(K)=>#token("false","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(771c9ac303cbf7ec1228dd7a6f0b5db7e43db7edb5d4582845e18d9d602cb63f), owise] + axiom{R} \implies{R} ( + \and{R} ( + \not{R} ( + \or{R} ( + \exists{R} (Var'Unds'Gen0:SortString{}, + \and{R} ( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortString{}, SortKItem{}}(Var'Unds'Gen0:SortString{}),dotk{}()) + ), + \top{R} () + ) + )), + \bottom{R}() + ) + ), + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + VarK:SortK{} + ), + \top{R} () + ) + )), + \equals{SortBool{},R} ( + LblisString{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("false"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("771c9ac303cbf7ec1228dd7a6f0b5db7e43db7edb5d4582845e18d9d602cb63f"), owise{}()] + +// rule isString(inj{String,KItem}(String))=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(109ced650ead4a5092ddba090e1b8e181633ed0aa5c5f93bce9f88be215668ef)] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortString{}, SortKItem{}}(VarString:SortString{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortBool{},R} ( + LblisString{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("109ced650ead4a5092ddba090e1b8e181633ed0aa5c5f93bce9f88be215668ef")] + +// rule isStrings(K)=>#token("false","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(58552434cf251a5de0fd9fec067d7982d46f1f21d587a4fb3312f8507154f2dc), owise] + axiom{R} \implies{R} ( + \and{R} ( + \not{R} ( + \or{R} ( + \exists{R} (Var'Unds'Gen0:SortStrings{}, + \and{R} ( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortStrings{}, SortKItem{}}(Var'Unds'Gen0:SortStrings{}),dotk{}()) + ), + \top{R} () + ) + )), + \bottom{R}() + ) + ), + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + VarK:SortK{} + ), + \top{R} () + ) + )), + \equals{SortBool{},R} ( + LblisStrings{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("false"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("58552434cf251a5de0fd9fec067d7982d46f1f21d587a4fb3312f8507154f2dc"), owise{}()] + +// rule isStrings(inj{Strings,KItem}(Strings))=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(968bb552c3d971a357f62643478b258260446407237d8b81fee66c8270399d39)] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortStrings{}, SortKItem{}}(VarStrings:SortStrings{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortBool{},R} ( + LblisStrings{}(X0:SortK{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("968bb552c3d971a357f62643478b258260446407237d8b81fee66c8270399d39")] + +// rule `minInt(_,_)_INT-COMMON_Int_Int_Int`(I1,I2)=>I1 requires `_<=Int_`(I1,I2) ensures #token("true","Bool") [UNIQUE_ID(fb09b6acc4366cb77203e07c4efe8a9cf304e1bac9fb0664deea05d3eb9a80c6), org.kframework.attributes.Location(Location(1426,8,1426,57)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody "requires" Bool [klabel(#ruleRequires), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \equals{SortBool{},R}( + Lbl'Unds-LT-Eqls'Int'Unds'{}(VarI1:SortInt{},VarI2:SortInt{}), + \dv{SortBool{}}("true")), + \and{R} ( + \in{SortInt{}, R} ( + X0:SortInt{}, + VarI1:SortInt{} + ),\and{R} ( + \in{SortInt{}, R} ( + X1:SortInt{}, + VarI2:SortInt{} + ), + \top{R} () + ))), + \equals{SortInt{},R} ( + LblminInt'LParUndsCommUndsRParUnds'INT-COMMON'Unds'Int'Unds'Int'Unds'Int{}(X0:SortInt{},X1:SortInt{}), + \and{SortInt{}} ( + VarI1:SortInt{}, + \top{SortInt{}}()))) + [UNIQUE'Unds'ID{}("fb09b6acc4366cb77203e07c4efe8a9cf304e1bac9fb0664deea05d3eb9a80c6"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1426,8,1426,57)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody \"requires\" Bool [klabel(#ruleRequires), symbol]")] + +// rule `minInt(_,_)_INT-COMMON_Int_Int_Int`(I1,I2)=>I2 requires `_>=Int_`(I1,I2) ensures #token("true","Bool") [UNIQUE_ID(e1effeabf96bb3a3beffd5b679ad5df95c4f8bbf42872b0793331e52a8470fb3), org.kframework.attributes.Location(Location(1427,8,1427,57)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody "requires" Bool [klabel(#ruleRequires), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \equals{SortBool{},R}( + Lbl'Unds-GT-Eqls'Int'Unds'{}(VarI1:SortInt{},VarI2:SortInt{}), + \dv{SortBool{}}("true")), + \and{R} ( + \in{SortInt{}, R} ( + X0:SortInt{}, + VarI1:SortInt{} + ),\and{R} ( + \in{SortInt{}, R} ( + X1:SortInt{}, + VarI2:SortInt{} + ), + \top{R} () + ))), + \equals{SortInt{},R} ( + LblminInt'LParUndsCommUndsRParUnds'INT-COMMON'Unds'Int'Unds'Int'Unds'Int{}(X0:SortInt{},X1:SortInt{}), + \and{SortInt{}} ( + VarI2:SortInt{}, + \top{SortInt{}}()))) + [UNIQUE'Unds'ID{}("e1effeabf96bb3a3beffd5b679ad5df95c4f8bbf42872b0793331e52a8470fb3"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1427,8,1427,57)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody \"requires\" Bool [klabel(#ruleRequires), symbol]")] + +// rule `notBool_`(#token("false","Bool"))=>#token("true","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(17ebc68421572b8ebe609c068fb49cbb6cbbe3246e2142257ad8befdda38f415), org.kframework.attributes.Location(Location(1119,8,1119,29)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + \dv{SortBool{}}("false") + ), + \top{R} () + )), + \equals{SortBool{},R} ( + LblnotBool'Unds'{}(X0:SortBool{}), + \and{SortBool{}} ( + \dv{SortBool{}}("true"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("17ebc68421572b8ebe609c068fb49cbb6cbbe3246e2142257ad8befdda38f415"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1119,8,1119,29)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `notBool_`(#token("true","Bool"))=>#token("false","Bool") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(53fc758ece1ff16581673016dfacc556cc30fcf6b3c35b586f001d76a1f9336c), org.kframework.attributes.Location(Location(1118,8,1118,29)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortBool{}, R} ( + X0:SortBool{}, + \dv{SortBool{}}("true") + ), + \top{R} () + )), + \equals{SortBool{},R} ( + LblnotBool'Unds'{}(X0:SortBool{}), + \and{SortBool{}} ( + \dv{SortBool{}}("false"), + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("53fc758ece1ff16581673016dfacc556cc30fcf6b3c35b586f001d76a1f9336c"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1118,8,1118,29)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `project:Bool`(inj{Bool,KItem}(K))=>K requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(5872f0d5b8131216db7bc41e2c3a423e55f4b8581589fcbd1bf93b2ca6862d54), projection] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortBool{}, SortKItem{}}(VarK:SortBool{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortBool{},R} ( + Lblproject'Coln'Bool{}(X0:SortK{}), + \and{SortBool{}} ( + VarK:SortBool{}, + \top{SortBool{}}()))) + [UNIQUE'Unds'ID{}("5872f0d5b8131216db7bc41e2c3a423e55f4b8581589fcbd1bf93b2ca6862d54"), projection{}()] + +// rule `project:Float`(inj{Float,KItem}(K))=>K requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(ef206f477d884c0b6413273ff35b1206769cdb5a5ceba7b97d9e8e0a7b14e399), projection] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortFloat{}, SortKItem{}}(VarK:SortFloat{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortFloat{},R} ( + Lblproject'Coln'Float{}(X0:SortK{}), + \and{SortFloat{}} ( + VarK:SortFloat{}, + \top{SortFloat{}}()))) + [UNIQUE'Unds'ID{}("ef206f477d884c0b6413273ff35b1206769cdb5a5ceba7b97d9e8e0a7b14e399"), projection{}()] + +// rule `project:GeneratedCounterCell`(inj{GeneratedCounterCell,KItem}(K))=>K requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(63453db9d9aa121b63bb877e2fa4998d399ef82d2a1e4b90f87a32ba55401217), projection] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortGeneratedCounterCell{}, SortKItem{}}(VarK:SortGeneratedCounterCell{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortGeneratedCounterCell{},R} ( + Lblproject'Coln'GeneratedCounterCell{}(X0:SortK{}), + \and{SortGeneratedCounterCell{}} ( + VarK:SortGeneratedCounterCell{}, + \top{SortGeneratedCounterCell{}}()))) + [UNIQUE'Unds'ID{}("63453db9d9aa121b63bb877e2fa4998d399ef82d2a1e4b90f87a32ba55401217"), projection{}()] + +// rule `project:GeneratedTopCell`(inj{GeneratedTopCell,KItem}(K))=>K requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(b0fabd8c7c81fe08ebd569aff59747d357e441ae1fcd05d9d594d57e38e3d55e), projection] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortGeneratedTopCell{}, SortKItem{}}(VarK:SortGeneratedTopCell{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortGeneratedTopCell{},R} ( + Lblproject'Coln'GeneratedTopCell{}(X0:SortK{}), + \and{SortGeneratedTopCell{}} ( + VarK:SortGeneratedTopCell{}, + \top{SortGeneratedTopCell{}}()))) + [UNIQUE'Unds'ID{}("b0fabd8c7c81fe08ebd569aff59747d357e441ae1fcd05d9d594d57e38e3d55e"), projection{}()] + +// rule `project:GeneratedTopCellFragment`(inj{GeneratedTopCellFragment,KItem}(K))=>K requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(2084fac322aa142a07f881814b8a286bf62d5c6d05777b7aa715ccc534cf9a42), projection] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortGeneratedTopCellFragment{}, SortKItem{}}(VarK:SortGeneratedTopCellFragment{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortGeneratedTopCellFragment{},R} ( + Lblproject'Coln'GeneratedTopCellFragment{}(X0:SortK{}), + \and{SortGeneratedTopCellFragment{}} ( + VarK:SortGeneratedTopCellFragment{}, + \top{SortGeneratedTopCellFragment{}}()))) + [UNIQUE'Unds'ID{}("2084fac322aa142a07f881814b8a286bf62d5c6d05777b7aa715ccc534cf9a42"), projection{}()] + +// rule `project:Int`(inj{Int,KItem}(K))=>K requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(f316b871091516c401f1d2382cc5f66322602b782c7b01e1aeb6c2ddab50e24b), projection] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortInt{}, SortKItem{}}(VarK:SortInt{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortInt{},R} ( + Lblproject'Coln'Int{}(X0:SortK{}), + \and{SortInt{}} ( + VarK:SortInt{}, + \top{SortInt{}}()))) + [UNIQUE'Unds'ID{}("f316b871091516c401f1d2382cc5f66322602b782c7b01e1aeb6c2ddab50e24b"), projection{}()] + +// rule `project:K`(K)=>K requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(25b529ddcefd25ef63f99a62040145ef27638e7679ea9202218fe14be98dff3a), projection] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + VarK:SortK{} + ), + \top{R} () + )), + \equals{SortK{},R} ( + Lblproject'Coln'K{}(X0:SortK{}), + \and{SortK{}} ( + VarK:SortK{}, + \top{SortK{}}()))) + [UNIQUE'Unds'ID{}("25b529ddcefd25ef63f99a62040145ef27638e7679ea9202218fe14be98dff3a"), projection{}()] + +// rule `project:KCell`(inj{KCell,KItem}(K))=>K requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(894c13c4c410f11e35bc3781505aeddde4ff400ddda1daf8b35259dbf0de9a24), projection] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortKCell{}, SortKItem{}}(VarK:SortKCell{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortKCell{},R} ( + Lblproject'Coln'KCell{}(X0:SortK{}), + \and{SortKCell{}} ( + VarK:SortKCell{}, + \top{SortKCell{}}()))) + [UNIQUE'Unds'ID{}("894c13c4c410f11e35bc3781505aeddde4ff400ddda1daf8b35259dbf0de9a24"), projection{}()] + +// rule `project:KCellOpt`(inj{KCellOpt,KItem}(K))=>K requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(f684dd78d97feadf0cbcb3cbb8892e0842f137c7b29a904cb2f3fc9755b29b30), projection] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortKCellOpt{}, SortKItem{}}(VarK:SortKCellOpt{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortKCellOpt{},R} ( + Lblproject'Coln'KCellOpt{}(X0:SortK{}), + \and{SortKCellOpt{}} ( + VarK:SortKCellOpt{}, + \top{SortKCellOpt{}}()))) + [UNIQUE'Unds'ID{}("f684dd78d97feadf0cbcb3cbb8892e0842f137c7b29a904cb2f3fc9755b29b30"), projection{}()] + +// rule `project:KItem`(K)=>K requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(1242e49c17638c9a66a35e3bb8c237288f7e9aa9a6499101e8cdc55be320cd29), projection] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(VarK:SortKItem{},dotk{}()) + ), + \top{R} () + )), + \equals{SortKItem{},R} ( + Lblproject'Coln'KItem{}(X0:SortK{}), + \and{SortKItem{}} ( + VarK:SortKItem{}, + \top{SortKItem{}}()))) + [UNIQUE'Unds'ID{}("1242e49c17638c9a66a35e3bb8c237288f7e9aa9a6499101e8cdc55be320cd29"), projection{}()] + +// rule `project:List`(inj{List,KItem}(K))=>K requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(2b75eac5a59779d336e6cf9632bf9ba7d67286f322e753108b34e62f2443efe5), projection] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortList{}, SortKItem{}}(VarK:SortList{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortList{},R} ( + Lblproject'Coln'List{}(X0:SortK{}), + \and{SortList{}} ( + VarK:SortList{}, + \top{SortList{}}()))) + [UNIQUE'Unds'ID{}("2b75eac5a59779d336e6cf9632bf9ba7d67286f322e753108b34e62f2443efe5"), projection{}()] + +// rule `project:Map`(inj{Map,KItem}(K))=>K requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(031237d4aae58d86914d6370d37ccd15f4738378ed780333c59cc81b4f7bc598), projection] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortMap{}, SortKItem{}}(VarK:SortMap{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortMap{},R} ( + Lblproject'Coln'Map{}(X0:SortK{}), + \and{SortMap{}} ( + VarK:SortMap{}, + \top{SortMap{}}()))) + [UNIQUE'Unds'ID{}("031237d4aae58d86914d6370d37ccd15f4738378ed780333c59cc81b4f7bc598"), projection{}()] + +// rule `project:OutCell`(inj{OutCell,KItem}(K))=>K requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(4e3e6539e2af0340f8ef522f658e9c3072f28f7a9875daaadf0d7c5c8cb39125), projection] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortOutCell{}, SortKItem{}}(VarK:SortOutCell{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortOutCell{},R} ( + Lblproject'Coln'OutCell{}(X0:SortK{}), + \and{SortOutCell{}} ( + VarK:SortOutCell{}, + \top{SortOutCell{}}()))) + [UNIQUE'Unds'ID{}("4e3e6539e2af0340f8ef522f658e9c3072f28f7a9875daaadf0d7c5c8cb39125"), projection{}()] + +// rule `project:OutCellOpt`(inj{OutCellOpt,KItem}(K))=>K requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(bcba46708b0d08a2e82568b9775b9b5e99020e4da73bad65442918575a7b2eb2), projection] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortOutCellOpt{}, SortKItem{}}(VarK:SortOutCellOpt{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortOutCellOpt{},R} ( + Lblproject'Coln'OutCellOpt{}(X0:SortK{}), + \and{SortOutCellOpt{}} ( + VarK:SortOutCellOpt{}, + \top{SortOutCellOpt{}}()))) + [UNIQUE'Unds'ID{}("bcba46708b0d08a2e82568b9775b9b5e99020e4da73bad65442918575a7b2eb2"), projection{}()] + +// rule `project:Set`(inj{Set,KItem}(K))=>K requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(0e7f5070c993161786e314f7199d985afebac9e07b5c784f6f623780c60ce9d0), projection] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortSet{}, SortKItem{}}(VarK:SortSet{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortSet{},R} ( + Lblproject'Coln'Set{}(X0:SortK{}), + \and{SortSet{}} ( + VarK:SortSet{}, + \top{SortSet{}}()))) + [UNIQUE'Unds'ID{}("0e7f5070c993161786e314f7199d985afebac9e07b5c784f6f623780c60ce9d0"), projection{}()] + +// rule `project:String`(inj{String,KItem}(K))=>K requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(e491dad8f644d2344f08cb72af01ade1e6ce9f564010a2de7909b3b6c7e2ae85), projection] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortString{}, SortKItem{}}(VarK:SortString{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortString{},R} ( + Lblproject'Coln'String{}(X0:SortK{}), + \and{SortString{}} ( + VarK:SortString{}, + \top{SortString{}}()))) + [UNIQUE'Unds'ID{}("e491dad8f644d2344f08cb72af01ade1e6ce9f564010a2de7909b3b6c7e2ae85"), projection{}()] + +// rule `project:Strings`(inj{Strings,KItem}(K))=>K requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(a7364fe66bf603890008d1e32bd1e2d77f59899aff68b05d9c8ce086af57eab2), projection] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortK{}, R} ( + X0:SortK{}, + kseq{}(inj{SortStrings{}, SortKItem{}}(VarK:SortStrings{}),dotk{}()) + ), + \top{R} () + )), + \equals{SortStrings{},R} ( + Lblproject'Coln'Strings{}(X0:SortK{}), + \and{SortStrings{}} ( + VarK:SortStrings{}, + \top{SortStrings{}}()))) + [UNIQUE'Unds'ID{}("a7364fe66bf603890008d1e32bd1e2d77f59899aff68b05d9c8ce086af57eab2"), projection{}()] + +// rule `replace(_,_,_,_)_STRING-COMMON_String_String_String_String_Int`(Source,ToReplace,Replacement,Count)=>`_+String__STRING-COMMON_String_String_String`(`_+String__STRING-COMMON_String_String_String`(`substrString(_,_,_)_STRING-COMMON_String_String_Int_Int`(Source,#token("0","Int"),`findString(_,_,_)_STRING-COMMON_Int_String_String_Int`(Source,ToReplace,#token("0","Int"))),Replacement),`replace(_,_,_,_)_STRING-COMMON_String_String_String_String_Int`(`substrString(_,_,_)_STRING-COMMON_String_String_Int_Int`(Source,`_+Int_`(`findString(_,_,_)_STRING-COMMON_Int_String_String_Int`(Source,ToReplace,#token("0","Int")),`lengthString(_)_STRING-COMMON_Int_String`(ToReplace)),`lengthString(_)_STRING-COMMON_Int_String`(Source)),ToReplace,Replacement,`_-Int_`(Count,#token("1","Int")))) requires `_>Int_`(Count,#token("0","Int")) ensures #token("true","Bool") [UNIQUE_ID(311b80d2cb12d368f230eba968464e1fc926bd57e304059b282b82af4d9626d9), org.kframework.attributes.Location(Location(1884,8,1887,30)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody "requires" Bool [klabel(#ruleRequires), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \equals{SortBool{},R}( + Lbl'Unds-GT-'Int'Unds'{}(VarCount:SortInt{},\dv{SortInt{}}("0")), + \dv{SortBool{}}("true")), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + VarSource:SortString{} + ),\and{R} ( + \in{SortString{}, R} ( + X1:SortString{}, + VarToReplace:SortString{} + ),\and{R} ( + \in{SortString{}, R} ( + X2:SortString{}, + VarReplacement:SortString{} + ),\and{R} ( + \in{SortInt{}, R} ( + X3:SortInt{}, + VarCount:SortInt{} + ), + \top{R} () + ))))), + \equals{SortString{},R} ( + Lblreplace'LParUndsCommUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'String'Unds'String'Unds'Int{}(X0:SortString{},X1:SortString{},X2:SortString{},X3:SortInt{}), + \and{SortString{}} ( + Lbl'UndsPlus'String'UndsUnds'STRING-COMMON'Unds'String'Unds'String'Unds'String{}(Lbl'UndsPlus'String'UndsUnds'STRING-COMMON'Unds'String'Unds'String'Unds'String{}(LblsubstrString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'Int'Unds'Int{}(VarSource:SortString{},\dv{SortInt{}}("0"),LblfindString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String'Unds'Int{}(VarSource:SortString{},VarToReplace:SortString{},\dv{SortInt{}}("0"))),VarReplacement:SortString{}),Lblreplace'LParUndsCommUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'String'Unds'String'Unds'Int{}(LblsubstrString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'Int'Unds'Int{}(VarSource:SortString{},Lbl'UndsPlus'Int'Unds'{}(LblfindString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String'Unds'Int{}(VarSource:SortString{},VarToReplace:SortString{},\dv{SortInt{}}("0")),LbllengthString'LParUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String{}(VarToReplace:SortString{})),LbllengthString'LParUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String{}(VarSource:SortString{})),VarToReplace:SortString{},VarReplacement:SortString{},Lbl'Unds'-Int'Unds'{}(VarCount:SortInt{},\dv{SortInt{}}("1")))), + \top{SortString{}}()))) + [UNIQUE'Unds'ID{}("311b80d2cb12d368f230eba968464e1fc926bd57e304059b282b82af4d9626d9"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1884,8,1887,30)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody \"requires\" Bool [klabel(#ruleRequires), symbol]")] + +// rule `replace(_,_,_,_)_STRING-COMMON_String_String_String_String_Int`(Source,_Gen0,_Gen1,#token("0","Int"))=>Source requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(4367434b0f61c404f7a2e926426bd23874dd547de689c5d15089967fbab2b3d5), org.kframework.attributes.Location(Location(1888,8,1888,49)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + VarSource:SortString{} + ),\and{R} ( + \in{SortString{}, R} ( + X1:SortString{}, + Var'Unds'Gen0:SortString{} + ),\and{R} ( + \in{SortString{}, R} ( + X2:SortString{}, + Var'Unds'Gen1:SortString{} + ),\and{R} ( + \in{SortInt{}, R} ( + X3:SortInt{}, + \dv{SortInt{}}("0") + ), + \top{R} () + ))))), + \equals{SortString{},R} ( + Lblreplace'LParUndsCommUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'String'Unds'String'Unds'Int{}(X0:SortString{},X1:SortString{},X2:SortString{},X3:SortInt{}), + \and{SortString{}} ( + VarSource:SortString{}, + \top{SortString{}}()))) + [UNIQUE'Unds'ID{}("4367434b0f61c404f7a2e926426bd23874dd547de689c5d15089967fbab2b3d5"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1888,8,1888,49)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `replaceAll(_,_,_)_STRING-COMMON_String_String_String_String`(Source,ToReplace,Replacement)=>`replace(_,_,_,_)_STRING-COMMON_String_String_String_String_Int`(Source,ToReplace,Replacement,`countAllOccurrences(_,_)_STRING-COMMON_Int_String_String`(Source,ToReplace)) requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(262167183c3ec2e214d12bac6e639d7ac1a9f973582e16eca6c1af1da7ecc0a5), org.kframework.attributes.Location(Location(1889,8,1889,154)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + VarSource:SortString{} + ),\and{R} ( + \in{SortString{}, R} ( + X1:SortString{}, + VarToReplace:SortString{} + ),\and{R} ( + \in{SortString{}, R} ( + X2:SortString{}, + VarReplacement:SortString{} + ), + \top{R} () + )))), + \equals{SortString{},R} ( + LblreplaceAll'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'String'Unds'String{}(X0:SortString{},X1:SortString{},X2:SortString{}), + \and{SortString{}} ( + Lblreplace'LParUndsCommUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'String'Unds'String'Unds'Int{}(VarSource:SortString{},VarToReplace:SortString{},VarReplacement:SortString{},LblcountAllOccurrences'LParUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String{}(VarSource:SortString{},VarToReplace:SortString{})), + \top{SortString{}}()))) + [UNIQUE'Unds'ID{}("262167183c3ec2e214d12bac6e639d7ac1a9f973582e16eca6c1af1da7ecc0a5"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1889,8,1889,154)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `replaceFirst(_,_,_)_STRING-COMMON_String_String_String_String`(Source,ToReplace,Replacement)=>`_+String__STRING-COMMON_String_String_String`(`_+String__STRING-COMMON_String_String_String`(`substrString(_,_,_)_STRING-COMMON_String_String_Int_Int`(Source,#token("0","Int"),`findString(_,_,_)_STRING-COMMON_Int_String_String_Int`(Source,ToReplace,#token("0","Int"))),Replacement),`substrString(_,_,_)_STRING-COMMON_String_String_Int_Int`(Source,`_+Int_`(`findString(_,_,_)_STRING-COMMON_Int_String_String_Int`(Source,ToReplace,#token("0","Int")),`lengthString(_)_STRING-COMMON_Int_String`(ToReplace)),`lengthString(_)_STRING-COMMON_Int_String`(Source))) requires `_>=Int_`(`findString(_,_,_)_STRING-COMMON_Int_String_String_Int`(Source,ToReplace,#token("0","Int")),#token("0","Int")) ensures #token("true","Bool") [UNIQUE_ID(e290042e5b5b2f620c0ca1871e708c3713c62b63b283e317bb7568e13968fe0c), org.kframework.attributes.Location(Location(1877,8,1879,66)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody "requires" Bool [klabel(#ruleRequires), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \equals{SortBool{},R}( + Lbl'Unds-GT-Eqls'Int'Unds'{}(LblfindString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String'Unds'Int{}(VarSource:SortString{},VarToReplace:SortString{},\dv{SortInt{}}("0")),\dv{SortInt{}}("0")), + \dv{SortBool{}}("true")), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + VarSource:SortString{} + ),\and{R} ( + \in{SortString{}, R} ( + X1:SortString{}, + VarToReplace:SortString{} + ),\and{R} ( + \in{SortString{}, R} ( + X2:SortString{}, + VarReplacement:SortString{} + ), + \top{R} () + )))), + \equals{SortString{},R} ( + LblreplaceFirst'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'String'Unds'String{}(X0:SortString{},X1:SortString{},X2:SortString{}), + \and{SortString{}} ( + Lbl'UndsPlus'String'UndsUnds'STRING-COMMON'Unds'String'Unds'String'Unds'String{}(Lbl'UndsPlus'String'UndsUnds'STRING-COMMON'Unds'String'Unds'String'Unds'String{}(LblsubstrString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'Int'Unds'Int{}(VarSource:SortString{},\dv{SortInt{}}("0"),LblfindString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String'Unds'Int{}(VarSource:SortString{},VarToReplace:SortString{},\dv{SortInt{}}("0"))),VarReplacement:SortString{}),LblsubstrString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'Int'Unds'Int{}(VarSource:SortString{},Lbl'UndsPlus'Int'Unds'{}(LblfindString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String'Unds'Int{}(VarSource:SortString{},VarToReplace:SortString{},\dv{SortInt{}}("0")),LbllengthString'LParUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String{}(VarToReplace:SortString{})),LbllengthString'LParUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String{}(VarSource:SortString{}))), + \top{SortString{}}()))) + [UNIQUE'Unds'ID{}("e290042e5b5b2f620c0ca1871e708c3713c62b63b283e317bb7568e13968fe0c"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1877,8,1879,66)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody \"requires\" Bool [klabel(#ruleRequires), symbol]")] + +// rule `replaceFirst(_,_,_)_STRING-COMMON_String_String_String_String`(Source,ToReplace,_Gen0)=>Source requires `_`maxInt(_,_)_INT-COMMON_Int_Int_Int`(`rfindString(_,_,_)_STRING-COMMON_Int_String_String_Int`(S1,`substrString(_,_,_)_STRING-COMMON_String_String_Int_Int`(S2,#token("0","Int"),#token("1","Int")),I),`rfindChar(_,_,_)_STRING-COMMON_Int_String_String_Int`(S1,`substrString(_,_,_)_STRING-COMMON_String_String_Int_Int`(S2,#token("1","Int"),`lengthString(_)_STRING-COMMON_Int_String`(S2)),I)) requires `_=/=String__STRING-COMMON_Bool_String_String`(S2,#token("\"\"","String")) ensures #token("true","Bool") [UNIQUE_ID(b7f740050d72a847424b022a9c8217325aba8a154a42831aa3c7a3b0727f3205), org.kframework.attributes.Location(Location(1869,8,1869,182)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody "requires" Bool [klabel(#ruleRequires), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \equals{SortBool{},R}( + Lbl'UndsEqlsSlshEqls'String'UndsUnds'STRING-COMMON'Unds'Bool'Unds'String'Unds'String{}(VarS2:SortString{},\dv{SortString{}}("")), + \dv{SortBool{}}("true")), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + VarS1:SortString{} + ),\and{R} ( + \in{SortString{}, R} ( + X1:SortString{}, + VarS2:SortString{} + ),\and{R} ( + \in{SortInt{}, R} ( + X2:SortInt{}, + VarI:SortInt{} + ), + \top{R} () + )))), + \equals{SortInt{},R} ( + LblrfindChar'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String'Unds'Int{}(X0:SortString{},X1:SortString{},X2:SortInt{}), + \and{SortInt{}} ( + LblmaxInt'LParUndsCommUndsRParUnds'INT-COMMON'Unds'Int'Unds'Int'Unds'Int{}(LblrfindString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String'Unds'Int{}(VarS1:SortString{},LblsubstrString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'Int'Unds'Int{}(VarS2:SortString{},\dv{SortInt{}}("0"),\dv{SortInt{}}("1")),VarI:SortInt{}),LblrfindChar'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String'Unds'Int{}(VarS1:SortString{},LblsubstrString'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'String'Unds'String'Unds'Int'Unds'Int{}(VarS2:SortString{},\dv{SortInt{}}("1"),LbllengthString'LParUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String{}(VarS2:SortString{})),VarI:SortInt{})), + \top{SortInt{}}()))) + [UNIQUE'Unds'ID{}("b7f740050d72a847424b022a9c8217325aba8a154a42831aa3c7a3b0727f3205"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1869,8,1869,182)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody \"requires\" Bool [klabel(#ruleRequires), symbol]")] + +// rule `rfindChar(_,_,_)_STRING-COMMON_Int_String_String_Int`(_Gen0,#token("\"\"","String"),_Gen1)=>#token("-1","Int") requires #token("true","Bool") ensures #token("true","Bool") [UNIQUE_ID(23b9fa88124c547d94aed32124d1ccd1069732b059f4c8b430ab4617979690f6), org.kframework.attributes.Location(Location(1870,8,1870,33)), org.kframework.attributes.Source(Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])] + axiom{R} \implies{R} ( + \and{R}( + \top{R}(), + \and{R} ( + \in{SortString{}, R} ( + X0:SortString{}, + Var'Unds'Gen0:SortString{} + ),\and{R} ( + \in{SortString{}, R} ( + X1:SortString{}, + \dv{SortString{}}("") + ),\and{R} ( + \in{SortInt{}, R} ( + X2:SortInt{}, + Var'Unds'Gen1:SortInt{} + ), + \top{R} () + )))), + \equals{SortInt{},R} ( + LblrfindChar'LParUndsCommUndsCommUndsRParUnds'STRING-COMMON'Unds'Int'Unds'String'Unds'String'Unds'Int{}(X0:SortString{},X1:SortString{},X2:SortInt{}), + \and{SortInt{}} ( + \dv{SortInt{}}("-1"), + \top{SortInt{}}()))) + [UNIQUE'Unds'ID{}("23b9fa88124c547d94aed32124d1ccd1069732b059f4c8b430ab4617979690f6"), org'Stop'kframework'Stop'attributes'Stop'Location{}("Location(1870,8,1870,33)"), org'Stop'kframework'Stop'attributes'Stop'Source{}("Source(/home/sguest/work/k/k-distribution/target/release/k/include/kframework/builtin/domains.md)"), org'Stop'kframework'Stop'definition'Stop'Production{}("syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol]")] + +// rule `signExtendBitRangeInt(_,_,_)_INT-COMMON_Int_Int_Int_Int`(I,IDX,LEN)=>`_-Int_`(`_modInt_`(`_+Int_`(`bitRangeInt(_,_,_)_INT-COMMON_Int_Int_Int_Int`(I,IDX,LEN),`_< Date: Wed, 6 Sep 2023 15:52:53 -0400 Subject: [PATCH 19/28] Add BYTES_LAYOUT --- cmake/RuntimeConfig.cmake | 1 + config/macros.h | 1 + lib/ast/AST.cpp | 4 ++-- runtime/collect/collect.cpp | 1 + runtime/collections/hash.cpp | 1 + runtime/collections/kelemle.cpp | 4 ++++ runtime/meta/substitution.cpp | 6 +++++- 7 files changed, 15 insertions(+), 3 deletions(-) diff --git a/cmake/RuntimeConfig.cmake b/cmake/RuntimeConfig.cmake index ac83eef71..9dee5902a 100644 --- a/cmake/RuntimeConfig.cmake +++ b/cmake/RuntimeConfig.cmake @@ -36,6 +36,7 @@ set(BOOL_LAYOUT 7) set(SYMBOL_LAYOUT 8) set(VARIABLE_LAYOUT 9) set(RANGEMAP_LAYOUT 11) +set(BYTES_LAYOUT 12) get_filename_component(INSTALL_DIR_ABS_PATH "${CMAKE_INSTALL_PREFIX}" REALPATH BASE_DIR "${CMAKE_BINARY_DIR}") diff --git a/config/macros.h b/config/macros.h index 455d284e9..6b3dfa992 100644 --- a/config/macros.h +++ b/config/macros.h @@ -23,6 +23,7 @@ #define SYMBOL_LAYOUT @SYMBOL_LAYOUT@ #define VARIABLE_LAYOUT @VARIABLE_LAYOUT@ #define RANGEMAP_LAYOUT @RANGEMAP_LAYOUT@ +#define BYTES_LAYOUT @BYTES_LAYOUT@ #define STRINGIFY(x) #x #define TOSTRING(X) STRINGIFY(X) diff --git a/lib/ast/AST.cpp b/lib/ast/AST.cpp index 35f03ace6..3f184fb15 100644 --- a/lib/ast/AST.cpp +++ b/lib/ast/AST.cpp @@ -251,7 +251,6 @@ std::string KORESymbol::layoutString(KOREDefinition *definition) const { ValueType cat = sort->getCategory(definition); switch (cat.cat) { case SortCategory::Map: result.push_back('1'); break; - case SortCategory::RangeMap: result.push_back('b'); break; case SortCategory::List: result.push_back('2'); break; case SortCategory::Set: result.push_back('3'); break; case SortCategory::Int: result.push_back('4'); break; @@ -259,9 +258,10 @@ std::string KORESymbol::layoutString(KOREDefinition *definition) const { case SortCategory::StringBuffer: result.push_back('6'); break; case SortCategory::Bool: result.push_back('7'); break; case SortCategory::Variable: result.push_back('8'); break; + case SortCategory::RangeMap: result.push_back('9'); break; + case SortCategory::Bytes: result.push_back('a'); break; case SortCategory::MInt: result.append("_" + std::to_string(cat.bits) + "_"); - case SortCategory::Bytes: case SortCategory::Symbol: result.push_back('0'); break; case SortCategory::Uncomputed: abort(); } diff --git a/runtime/collect/collect.cpp b/runtime/collect/collect.cpp index 33423fd41..54072887c 100644 --- a/runtime/collect/collect.cpp +++ b/runtime/collect/collect.cpp @@ -210,6 +210,7 @@ migrate_child(void *currBlock, layoutitem *args, unsigned i, bool ptr) { case LIST_LAYOUT: migrate_list(ptr ? *(list **)arg : arg); break; case SET_LAYOUT: migrate_set(ptr ? *(set **)arg : arg); break; case STRINGBUFFER_LAYOUT: migrate_string_buffer((stringbuffer **)arg); break; + case BYTES_LAYOUT: case SYMBOL_LAYOUT: case VARIABLE_LAYOUT: migrate((block **)arg); break; case INT_LAYOUT: migrate_mpz((mpz_ptr *)arg); break; diff --git a/runtime/collections/hash.cpp b/runtime/collections/hash.cpp index 3acdeef0f..20ef28be9 100644 --- a/runtime/collections/hash.cpp +++ b/runtime/collections/hash.cpp @@ -111,6 +111,7 @@ void k_hash(block *arg, void *h) { break; } case SYMBOL_LAYOUT: + case BYTES_LAYOUT: case VARIABLE_LAYOUT: { block **childptrptr = (block **)(argintptr + offset); k_hash(*childptrptr, h); diff --git a/runtime/collections/kelemle.cpp b/runtime/collections/kelemle.cpp index aedcf4a63..c71aee1ea 100644 --- a/runtime/collections/kelemle.cpp +++ b/runtime/collections/kelemle.cpp @@ -106,6 +106,7 @@ bool hook_KEQUAL_eq(block *arg1, block *arg2) { } break; } + case BYTES_LAYOUT: case SYMBOL_LAYOUT: { block **child1ptrptr = (block **)(child1intptr); block **child2ptrptr = (block **)(child2intptr); @@ -212,6 +213,9 @@ bool hook_KEQUAL_lt(block *arg1, block *arg2) { case BOOL_LAYOUT: { abort(); // Implement when needed. } + case BYTES_LAYOUT: { + abort(); // Implement when needed. + } case SYMBOL_LAYOUT: { abort(); // Implement when needed. } diff --git a/runtime/meta/substitution.cpp b/runtime/meta/substitution.cpp index d1c1639b4..c1a5bcd0c 100644 --- a/runtime/meta/substitution.cpp +++ b/runtime/meta/substitution.cpp @@ -91,6 +91,7 @@ block *debruijnizeInternal(block *currBlock) { case INT_LAYOUT: case FLOAT_LAYOUT: case BOOL_LAYOUT: + case BYTES_LAYOUT: default: // mint break; } @@ -166,6 +167,7 @@ block *replaceBinderInternal(block *currBlock) { case INT_LAYOUT: case FLOAT_LAYOUT: case BOOL_LAYOUT: + case BYTES_LAYOUT: default: // mint break; } @@ -246,7 +248,8 @@ block *substituteInternal(block *currBlock) { } case STRINGBUFFER_LAYOUT: case INT_LAYOUT: - case FLOAT_LAYOUT: arguments.push_back(*(void **)arg); break; + case FLOAT_LAYOUT: + case BYTES_LAYOUT: arguments.push_back(*(void **)arg); break; case BOOL_LAYOUT: default: // mint arguments.push_back(arg); @@ -359,6 +362,7 @@ block *incrementDebruijn(block *currBlock) { case INT_LAYOUT: case FLOAT_LAYOUT: case BOOL_LAYOUT: + case BYTES_LAYOUT: default: // mint break; } From 92df03a4c6bb2540d2bae3e3ab8dfc9e21ece62a Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Wed, 6 Sep 2023 16:54:51 -0400 Subject: [PATCH 20/28] Add missing calls to set_is_bytes in hooks --- runtime/strings/bytes.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/runtime/strings/bytes.cpp b/runtime/strings/bytes.cpp index 9126916df..90317ec9a 100644 --- a/runtime/strings/bytes.cpp +++ b/runtime/strings/bytes.cpp @@ -92,6 +92,7 @@ hook_BYTES_int2bytes(SortInt len, SortInt i, SortEndianness endianness_ptr) { bool neg = mpz_sgn(i) < 0; string *result = static_cast(koreAllocToken(sizeof(string) + len_long)); + set_is_bytes(result, true); set_len(result, len_long); memset(result->data, neg ? 0xff : 0x00, len_long); int order = endianness == tag_big_endian() ? 1 : -1; @@ -144,6 +145,7 @@ SortBytes hook_BYTES_substr(SortBytes input, SortInt start, SortInt end) { uint64_t len = uend - ustart; auto ret = static_cast( koreAllocToken(sizeof(string) + sizeof(KCHAR) * len)); + set_is_bytes(ret, true); set_len(ret, len); memcpy(&(ret->data), &(input->data[ustart]), len * sizeof(KCHAR)); return ret; @@ -202,6 +204,7 @@ SortBytes hook_BYTES_padRight(SortBytes b, SortInt length, SortInt v) { KLLVM_HOOK_INVALID_ARGUMENT("Integer overflow on value: {}", uv); } string *result = static_cast(koreAllocToken(sizeof(string) + ulen)); + set_is_bytes(result, true); set_len(result, ulen); memcpy(result->data, b->data, len(b)); memset(result->data + len(b), uv, ulen - len(b)); @@ -218,6 +221,7 @@ SortBytes hook_BYTES_padLeft(SortBytes b, SortInt length, SortInt v) { KLLVM_HOOK_INVALID_ARGUMENT("Integer overflow on value: {}", uv); } string *result = static_cast(koreAllocToken(sizeof(string) + ulen)); + set_is_bytes(result, true); set_len(result, ulen); memset(result->data, uv, ulen - len(b)); memcpy(result->data + ulen - len(b), b->data, len(b)); @@ -234,6 +238,7 @@ SortBytes hook_BYTES_concat(SortBytes a, SortBytes b) { auto len_b = len(b); auto newlen = len_a + len_b; auto ret = static_cast(koreAllocToken(sizeof(string) + newlen)); + set_is_bytes(ret, true); set_len(ret, newlen); memcpy(&(ret->data), &(a->data), len(a) * sizeof(KCHAR)); memcpy(&(ret->data[len(a)]), &(b->data), len(b) * sizeof(KCHAR)); From 88ee65dd69faee569d722dbb9c3ed276d0abc1f3 Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Thu, 7 Sep 2023 10:58:41 -0400 Subject: [PATCH 21/28] Set is_bytes bit in hook_BYTES_empty --- runtime/strings/bytes.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/runtime/strings/bytes.cpp b/runtime/strings/bytes.cpp index 90317ec9a..07c684465 100644 --- a/runtime/strings/bytes.cpp +++ b/runtime/strings/bytes.cpp @@ -18,7 +18,7 @@ mpz_ptr move_int(mpz_t); SortBytes hook_BYTES_empty() { static string empty; - empty.h.hdr = NOT_YOUNG_OBJECT_BIT; + empty.h.hdr = NOT_YOUNG_OBJECT_BIT | IS_BYTES_BIT; return ∅ } From 650a5a5594afc7821e8daaba0679595979385a96 Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Thu, 7 Sep 2023 11:39:44 -0400 Subject: [PATCH 22/28] Set is_bytes to false in STRING hooks which delegate to BYTES --- runtime/strings/strings.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/runtime/strings/strings.cpp b/runtime/strings/strings.cpp index edd16e9fa..04a65004e 100644 --- a/runtime/strings/strings.cpp +++ b/runtime/strings/strings.cpp @@ -65,7 +65,9 @@ bool hook_STRING_ne(SortString a, SortString b) { } SortString hook_STRING_concat(SortString a, SortString b) { - return hook_BYTES_concat(a, b); + auto ret = hook_BYTES_concat(a, b); + set_is_bytes(ret, false); + return ret; } SortInt hook_STRING_length(SortString a) { @@ -102,7 +104,9 @@ SortInt hook_STRING_ord(SortString input) { } SortString hook_STRING_substr(SortString input, SortInt start, SortInt end) { - return hook_BYTES_substr(input, start, end); + auto ret = hook_BYTES_substr(input, start, end); + set_is_bytes(ret, false); + return ret; } SortInt hook_STRING_find(SortString haystack, SortString needle, SortInt pos) { From c78ce0348702c3cf714b24e6da06d81501454d9a Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Thu, 7 Sep 2023 13:29:27 -0400 Subject: [PATCH 23/28] Correct ! to ~ in set_is_bytes --- include/runtime/header.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/runtime/header.h b/include/runtime/header.h index c1d7c24f6..1956208bd 100644 --- a/include/runtime/header.h +++ b/include/runtime/header.h @@ -125,7 +125,7 @@ set_is_bytes(T *s, bool is_bytes) { if (is_bytes) { s->h.hdr |= IS_BYTES_BIT; } else { - s->h.hdr &= !IS_BYTES_BIT; + s->h.hdr &= ~IS_BYTES_BIT; } } From c9a4b1abe1fd08f77776a79995d304daf49712b1 Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Thu, 7 Sep 2023 14:20:47 -0400 Subject: [PATCH 24/28] Update set_len to not unintentionally clear is_bytes bit --- include/runtime/header.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/include/runtime/header.h b/include/runtime/header.h index 1956208bd..d57357513 100644 --- a/include/runtime/header.h +++ b/include/runtime/header.h @@ -140,7 +140,8 @@ __attribute__((always_inline)) constexpr uint64_t len(T const *s) { template __attribute__((always_inline)) constexpr void set_len(T *s, uint64_t l) { - s->h.hdr = l | (l > BLOCK_SIZE - sizeof(char *) ? NOT_YOUNG_OBJECT_BIT : 0); + s->h.hdr = (s->h.hdr & ~LENGTH_MASK) | l + | (l > BLOCK_SIZE - sizeof(char *) ? NOT_YOUNG_OBJECT_BIT : 0); } __attribute__((always_inline)) constexpr uint64_t size_hdr(uint64_t hdr) { From 11749cdccbf08c1f3467de0c9273671f98d3e380 Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Thu, 7 Sep 2023 14:40:50 -0400 Subject: [PATCH 25/28] Fix set_len to also clear original NOT_YOUNG_OBJECT_BIT --- include/runtime/header.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/runtime/header.h b/include/runtime/header.h index d57357513..44f22f849 100644 --- a/include/runtime/header.h +++ b/include/runtime/header.h @@ -140,8 +140,8 @@ __attribute__((always_inline)) constexpr uint64_t len(T const *s) { template __attribute__((always_inline)) constexpr void set_len(T *s, uint64_t l) { - s->h.hdr = (s->h.hdr & ~LENGTH_MASK) | l - | (l > BLOCK_SIZE - sizeof(char *) ? NOT_YOUNG_OBJECT_BIT : 0); + s->h.hdr &= ~(LENGTH_MASK | NOT_YOUNG_OBJECT_BIT); + s->h.hdr |= l | (l > BLOCK_SIZE - sizeof(char *) ? NOT_YOUNG_OBJECT_BIT : 0); } __attribute__((always_inline)) constexpr uint64_t size_hdr(uint64_t hdr) { From 591f80bcef470706b89728ac3454e9144231b03d Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Fri, 8 Sep 2023 13:08:08 -0400 Subject: [PATCH 26/28] Restore set_len behavior, rename to init_with_len, move all calls to set_is_bytes after this init --- include/runtime/header.h | 7 +++---- runtime/alloc/alloc.cpp | 12 ++++++------ runtime/io/io.cpp | 6 +++--- runtime/json/json.cpp | 10 +++++++--- runtime/meta/ffi.cpp | 4 ++-- runtime/meta/substitution.cpp | 2 +- runtime/strings/bytes.cpp | 12 ++++++------ runtime/strings/numeric.cpp | 2 +- runtime/strings/strings.cpp | 16 ++++++++-------- runtime/util/ConfigurationPrinter.cpp | 2 +- unittests/runtime-strings/stringtest.cpp | 4 ++-- 11 files changed, 40 insertions(+), 37 deletions(-) diff --git a/include/runtime/header.h b/include/runtime/header.h index 44f22f849..28cf39971 100644 --- a/include/runtime/header.h +++ b/include/runtime/header.h @@ -139,9 +139,8 @@ __attribute__((always_inline)) constexpr uint64_t len(T const *s) { } template -__attribute__((always_inline)) constexpr void set_len(T *s, uint64_t l) { - s->h.hdr &= ~(LENGTH_MASK | NOT_YOUNG_OBJECT_BIT); - s->h.hdr |= l | (l > BLOCK_SIZE - sizeof(char *) ? NOT_YOUNG_OBJECT_BIT : 0); +__attribute__((always_inline)) constexpr void init_with_len(T *s, uint64_t l) { + s->h.hdr = l | (l > BLOCK_SIZE - sizeof(char *) ? NOT_YOUNG_OBJECT_BIT : 0); } __attribute__((always_inline)) constexpr uint64_t size_hdr(uint64_t hdr) { @@ -241,7 +240,7 @@ struct kore_alloc_heap { return ::operator new(size); } else { string *result = (string *)koreAllocToken(size + sizeof(blockheader)); - set_len(result, size); + init_with_len(result, size); return result->data; } } diff --git a/runtime/alloc/alloc.cpp b/runtime/alloc/alloc.cpp index e52d3d8c7..8a8beefc8 100644 --- a/runtime/alloc/alloc.cpp +++ b/runtime/alloc/alloc.cpp @@ -111,7 +111,7 @@ void *koreResizeLastAlloc(void *oldptr, size_t newrequest, size_t last_size) { void *koreAllocMP(size_t requested) { string *_new = (string *)koreAllocToken(sizeof(string) + requested); - set_len(_new, requested); + init_with_len(_new, requested); return _new->data; } @@ -119,7 +119,7 @@ void *koreReallocMP(void *ptr, size_t old_size, size_t new_size) { string *_new = (string *)koreAllocToken(sizeof(string) + new_size); size_t min = old_size > new_size ? new_size : old_size; memcpy(_new->data, ptr, min); - set_len(_new, new_size); + init_with_len(_new, new_size); return _new->data; } @@ -127,25 +127,25 @@ void koreFree(void *ptr, size_t size) { } __attribute__((always_inline)) void *koreAllocInteger(size_t requested) { mpz_hdr *result = (mpz_hdr *)koreAlloc(sizeof(mpz_hdr)); - set_len(result, sizeof(mpz_hdr) - sizeof(blockheader)); + init_with_len(result, sizeof(mpz_hdr) - sizeof(blockheader)); return &result->i; } __attribute__((always_inline)) void *koreAllocFloating(size_t requested) { floating_hdr *result = (floating_hdr *)koreAlloc(sizeof(floating_hdr)); - set_len(result, sizeof(floating_hdr) - sizeof(blockheader)); + init_with_len(result, sizeof(floating_hdr) - sizeof(blockheader)); return &result->f; } __attribute__((always_inline)) void *koreAllocIntegerOld(size_t requested) { mpz_hdr *result = (mpz_hdr *)koreAllocOld(sizeof(mpz_hdr)); - set_len(result, sizeof(mpz_hdr) - sizeof(blockheader)); + init_with_len(result, sizeof(mpz_hdr) - sizeof(blockheader)); return &result->i; } __attribute__((always_inline)) void *koreAllocFloatingOld(size_t requested) { floating_hdr *result = (floating_hdr *)koreAllocOld(sizeof(floating_hdr)); - set_len(result, sizeof(floating_hdr) - sizeof(blockheader)); + init_with_len(result, sizeof(floating_hdr) - sizeof(blockheader)); return &result->f; } } diff --git a/runtime/io/io.cpp b/runtime/io/io.cpp index 00036a235..4c2d4478b 100644 --- a/runtime/io/io.cpp +++ b/runtime/io/io.cpp @@ -337,7 +337,7 @@ SortIOString hook_IO_read(SortInt i, SortInt len) { block *retBlock = static_cast(koreAlloc(sizeof(block) + sizeof(string *))); retBlock->h = header_string(); - set_len(result, bytes); + init_with_len(result, bytes); memcpy(retBlock->children, &result, sizeof(string *)); return retBlock; } @@ -601,7 +601,7 @@ string *hook_KREFLECTION_kompiledDir(void) { auto len = strlen(str_ptr); auto ret = static_cast(koreAllocToken(sizeof(string) + len)); memcpy(ret->data, str_ptr, len); - set_len(ret, len); + init_with_len(ret, len); return ret; } @@ -647,7 +647,7 @@ SortIOFile hook_IO_mkstemp(SortString filename) { string *retString = static_cast( koreAllocToken(sizeof(string) + sizeof(char) * length)); memcpy(retString->data, temp, sizeof(char) * length); - set_len(retString, length); + init_with_len(retString, length); memcpy(retBlock->children, &retString, sizeof(string *)); memcpy(retBlock->children + 1, &p, sizeof(mpz_ptr)); retBlock->h = getBlockHeaderForSymbol( diff --git a/runtime/json/json.cpp b/runtime/json/json.cpp index 94b53e4b9..1a4ba32a9 100644 --- a/runtime/json/json.cpp +++ b/runtime/json/json.cpp @@ -137,7 +137,7 @@ get_header(boolHdr, "inj{SortBool{}, SortJSON{}}") stringinj *inj = (stringinj *)koreAlloc(sizeof(stringinj)); inj->h = strHdr(); string *token = (string *)koreAllocToken(sizeof(string) + len); - set_len(token, len); + init_with_len(token, len); memcpy(token->data, str, len); inj->data = token; result = (block *)inj; @@ -145,7 +145,9 @@ get_header(boolHdr, "inj{SortBool{}, SortJSON{}}") return true; } - bool StartObject() { return true; } + bool StartObject() { + return true; + } bool Key(const char *str, SizeType len, bool copy) { return String(str, len, copy); @@ -173,7 +175,9 @@ get_header(boolHdr, "inj{SortBool{}, SortJSON{}}") return true; } - bool StartArray() { return true; } + bool StartArray() { + return true; + } bool EndArray(SizeType elementCount) { result = dotList(); diff --git a/runtime/meta/ffi.cpp b/runtime/meta/ffi.cpp index afdab4b4d..8c458b1fa 100644 --- a/runtime/meta/ffi.cpp +++ b/runtime/meta/ffi.cpp @@ -266,7 +266,7 @@ string *ffiCall( ffi_call(&cif, address, (void *)(rvalue->data), avalues); free(argtypes); - set_len(rvalue, rtype->size); + init_with_len(rvalue, rtype->size); free(avalues); for (auto &s : structTypes) { @@ -397,7 +397,7 @@ string *hook_FFI_alloc(block *kitem, mpz_t size, mpz_t align) { KLLVM_HOOK_INVALID_ARGUMENT("Could not allocate"); } memset(ret, 0, sizeof(string *) + s); - set_len(ret, s); + init_with_len(ret, s); ret->h.hdr |= NOT_YOUNG_OBJECT_BIT; allocatedKItemPtrs[kitem] = ret; diff --git a/runtime/meta/substitution.cpp b/runtime/meta/substitution.cpp index c1a5bcd0c..d9c2d731e 100644 --- a/runtime/meta/substitution.cpp +++ b/runtime/meta/substitution.cpp @@ -381,7 +381,7 @@ block *alphaRename(block *term) { size_t var_len = len(var); auto newToken = (string *)koreAllocToken(sizeof(string) + var_len); memcpy(newToken->data, var->data, var_len); - set_len(newToken, var_len); + init_with_len(newToken, var_len); newToken->h.hdr |= VARIABLE_BIT; return (block *)newToken; } diff --git a/runtime/strings/bytes.cpp b/runtime/strings/bytes.cpp index 07c684465..a3cf7243b 100644 --- a/runtime/strings/bytes.cpp +++ b/runtime/strings/bytes.cpp @@ -92,8 +92,8 @@ hook_BYTES_int2bytes(SortInt len, SortInt i, SortEndianness endianness_ptr) { bool neg = mpz_sgn(i) < 0; string *result = static_cast(koreAllocToken(sizeof(string) + len_long)); + init_with_len(result, len_long); set_is_bytes(result, true); - set_len(result, len_long); memset(result->data, neg ? 0xff : 0x00, len_long); int order = endianness == tag_big_endian() ? 1 : -1; mpz_t twos; @@ -110,7 +110,7 @@ hook_BYTES_int2bytes(SortInt len, SortInt i, SortEndianness endianness_ptr) { string *allocStringCopy(string *b, size_t len) { string *result = static_cast(koreAllocToken(sizeof(string) + len)); memcpy(result->data, b->data, len); - set_len(result, len); + init_with_len(result, len); return result; } @@ -145,8 +145,8 @@ SortBytes hook_BYTES_substr(SortBytes input, SortInt start, SortInt end) { uint64_t len = uend - ustart; auto ret = static_cast( koreAllocToken(sizeof(string) + sizeof(KCHAR) * len)); + init_with_len(ret, len); set_is_bytes(ret, true); - set_len(ret, len); memcpy(&(ret->data), &(input->data[ustart]), len * sizeof(KCHAR)); return ret; } @@ -204,8 +204,8 @@ SortBytes hook_BYTES_padRight(SortBytes b, SortInt length, SortInt v) { KLLVM_HOOK_INVALID_ARGUMENT("Integer overflow on value: {}", uv); } string *result = static_cast(koreAllocToken(sizeof(string) + ulen)); + init_with_len(result, ulen); set_is_bytes(result, true); - set_len(result, ulen); memcpy(result->data, b->data, len(b)); memset(result->data + len(b), uv, ulen - len(b)); return result; @@ -221,8 +221,8 @@ SortBytes hook_BYTES_padLeft(SortBytes b, SortInt length, SortInt v) { KLLVM_HOOK_INVALID_ARGUMENT("Integer overflow on value: {}", uv); } string *result = static_cast(koreAllocToken(sizeof(string) + ulen)); + init_with_len(result, ulen); set_is_bytes(result, true); - set_len(result, ulen); memset(result->data, uv, ulen - len(b)); memcpy(result->data + ulen - len(b), b->data, len(b)); return result; @@ -238,8 +238,8 @@ SortBytes hook_BYTES_concat(SortBytes a, SortBytes b) { auto len_b = len(b); auto newlen = len_a + len_b; auto ret = static_cast(koreAllocToken(sizeof(string) + newlen)); + init_with_len(ret, newlen); set_is_bytes(ret, true); - set_len(ret, newlen); memcpy(&(ret->data), &(a->data), len(a) * sizeof(KCHAR)); memcpy(&(ret->data[len(a)]), &(b->data), len(b) * sizeof(KCHAR)); return ret; diff --git a/runtime/strings/numeric.cpp b/runtime/strings/numeric.cpp index 36b38ae7b..683bd70d7 100644 --- a/runtime/strings/numeric.cpp +++ b/runtime/strings/numeric.cpp @@ -20,7 +20,7 @@ std::string floatToString(const floating *f, const char *suffix) { char *str = mpfr_get_str(NULL, &printed_exp, 10, 0, f->f, MPFR_RNDN); size_t len = strlen(str); string *newstr = (string *)koreAllocToken(sizeof(string) + len + 2); - set_len(newstr, len + 2); + init_with_len(newstr, len + 2); size_t idx = 0; if (str[0] == '-') { newstr->data[0] = '-'; diff --git a/runtime/strings/strings.cpp b/runtime/strings/strings.cpp index 04a65004e..18b0d5677 100644 --- a/runtime/strings/strings.cpp +++ b/runtime/strings/strings.cpp @@ -88,7 +88,7 @@ SortString hook_STRING_chr(SortInt ord) { } auto ret = static_cast(koreAllocToken(sizeof(string) + sizeof(KCHAR))); - set_len(ret, 1); + init_with_len(ret, 1); ret->data[0] = static_cast(uord); return ret; } @@ -190,7 +190,7 @@ string *makeString(const KCHAR *input, ssize_t len = -1) { } auto ret = static_cast(koreAllocToken(sizeof(string) + len)); memcpy(ret->data, input, len); - set_len(ret, len); + init_with_len(ret, len); return ret; } @@ -199,7 +199,7 @@ char *getTerminatedString(string *str) { string *buf = static_cast(koreAllocToken(sizeof(string) + (length + 1))); memcpy(buf->data, str->data, length); - set_len(buf, length + 1); + init_with_len(buf, length + 1); buf->data[length] = '\0'; return buf->data; } @@ -213,7 +213,7 @@ SortString hook_STRING_base2string_long(SortInt input, uint64_t base) { auto str_len = str.size() + 1; auto result = static_cast(koreAllocToken(sizeof(string) + str_len)); strncpy(result->data, str.c_str(), str_len); - set_len(result, str.size()); + init_with_len(result, str.size()); return static_cast(koreResizeLastAlloc( result, sizeof(string) + len(result), sizeof(string) + str_len)); @@ -314,7 +314,7 @@ inline SortString hook_STRING_replace( size_t new_len = len(haystack) - i * diff; auto ret = static_cast( koreAllocToken(sizeof(string) + new_len * sizeof(KCHAR))); - set_len(ret, new_len); + init_with_len(ret, new_len); int m = 0; for (size_t r = 0, h = 0; r < new_len;) { if (m >= i) { @@ -405,10 +405,10 @@ string *hook_STRING_floatFormat(string *str, string *fmt) { SortStringBuffer hook_BUFFER_empty() { auto result = static_cast(koreAlloc(sizeof(stringbuffer))); - set_len(result, sizeof(stringbuffer) - sizeof(blockheader)); + init_with_len(result, sizeof(stringbuffer) - sizeof(blockheader)); result->strlen = 0; auto str = static_cast(koreAllocToken(sizeof(string) + 16)); - set_len(str, 16); + init_with_len(str, 16); result->contents = str; return result; } @@ -441,7 +441,7 @@ hook_BUFFER_concat_raw(stringbuffer *buf, char const *data, uint64_t n) { } memcpy(buf->contents->data + buf->strlen, data, n); buf->strlen += n; - set_len(buf->contents, newCapacity); + init_with_len(buf->contents, newCapacity); return buf; } diff --git a/runtime/util/ConfigurationPrinter.cpp b/runtime/util/ConfigurationPrinter.cpp index 47a5b398a..d47f12c7e 100644 --- a/runtime/util/ConfigurationPrinter.cpp +++ b/runtime/util/ConfigurationPrinter.cpp @@ -121,7 +121,7 @@ void sfprintf(writer *file, const char *fmt, ...) { } va_end(args_copy); string *str = (string *)finalBuf; - set_len(str, res); + init_with_len(str, res); hook_BUFFER_concat(file->buffer, str); } va_end(args); diff --git a/unittests/runtime-strings/stringtest.cpp b/unittests/runtime-strings/stringtest.cpp index 41d735100..39883e9f4 100644 --- a/unittests/runtime-strings/stringtest.cpp +++ b/unittests/runtime-strings/stringtest.cpp @@ -553,13 +553,13 @@ BOOST_AUTO_TEST_CASE(buffer_concat) { int len = rand() % 1000; totalLen += len; auto str = static_cast(malloc(sizeof(string) + len)); - set_len(str, len); + init_with_len(str, len); memset(str->data, 'a', len); hook_BUFFER_concat(buf, str); } auto result = hook_BUFFER_toString(buf); auto expected = static_cast(malloc(sizeof(string) + totalLen)); - set_len(expected, totalLen); + init_with_len(expected, totalLen); memset(expected->data, 'a', totalLen); BOOST_CHECK_EQUAL(totalLen, len(result)); BOOST_CHECK_EQUAL(0, memcmp(result->data, expected->data, totalLen)); From 3decc945caa87bd2b5e29868988c0892e1540831 Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Fri, 8 Sep 2023 13:26:00 -0400 Subject: [PATCH 27/28] Fix json.cpp formatting, caused by bug in clang-format-14 --- runtime/json/json.cpp | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/runtime/json/json.cpp b/runtime/json/json.cpp index 1a4ba32a9..c6196ca8b 100644 --- a/runtime/json/json.cpp +++ b/runtime/json/json.cpp @@ -145,9 +145,7 @@ get_header(boolHdr, "inj{SortBool{}, SortJSON{}}") return true; } - bool StartObject() { - return true; - } + bool StartObject() { return true; } bool Key(const char *str, SizeType len, bool copy) { return String(str, len, copy); @@ -175,9 +173,7 @@ get_header(boolHdr, "inj{SortBool{}, SortJSON{}}") return true; } - bool StartArray() { - return true; - } + bool StartArray() { return true; } bool EndArray(SizeType elementCount) { result = dotList(); From 44cf5fc01e0923ca122d41cc9b4d639114cce482 Mon Sep 17 00:00:00 2001 From: Scott Guest Date: Sat, 9 Sep 2023 08:52:10 -0400 Subject: [PATCH 28/28] Reorder SortCategory so that MInt is last --- cmake/RuntimeConfig.cmake | 4 ++-- include/kllvm/ast/AST.h | 5 +++-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/cmake/RuntimeConfig.cmake b/cmake/RuntimeConfig.cmake index 9dee5902a..2d565fc57 100644 --- a/cmake/RuntimeConfig.cmake +++ b/cmake/RuntimeConfig.cmake @@ -35,8 +35,8 @@ set(STRINGBUFFER_LAYOUT 6) set(BOOL_LAYOUT 7) set(SYMBOL_LAYOUT 8) set(VARIABLE_LAYOUT 9) -set(RANGEMAP_LAYOUT 11) -set(BYTES_LAYOUT 12) +set(RANGEMAP_LAYOUT 10) +set(BYTES_LAYOUT 11) get_filename_component(INSTALL_DIR_ABS_PATH "${CMAKE_INSTALL_PREFIX}" REALPATH BASE_DIR "${CMAKE_BINARY_DIR}") diff --git a/include/kllvm/ast/AST.h b/include/kllvm/ast/AST.h index 4096f30cb..c277ceea3 100644 --- a/include/kllvm/ast/AST.h +++ b/include/kllvm/ast/AST.h @@ -122,9 +122,10 @@ enum class SortCategory { Bool, Symbol, Variable, - MInt, RangeMap, - Bytes + Bytes, + // WARNING: MInt must be the last value, so that valueType.cat + valueType.bits can unique identify the ValueType + MInt }; // represents the syntactic category of an LLVM backend term at runtime