Merge remote-tracking branch 'origin/mr/11'

This commit is contained in:
Tony Garnock-Jones 2023-07-21 17:42:26 +02:00
commit 08e62fd681
2 changed files with 30 additions and 30 deletions

View File

@ -377,7 +377,7 @@ pub fn compile(config: &CompilerConfig) -> io::Result<()> {
seq!["fn default() -> Self ", codeblock![
seq![b.language_struct_name(), " ", vertical(false, braces(b.literals.iter().map(|(value, name)| {
let bs = preserves::value::PackedWriter::encode_iovalue(&value).unwrap();
item(format!("{}: /* {:?} */ _support::decode_lit(&vec!{:?}).unwrap()",
item(format!("{}: /* {:?} */ _support::decode_lit(&{:?}).unwrap()",
name,
value,
bs))

View File

@ -39,35 +39,35 @@ pub struct Language<N: preserves::value::NestedValue> {
impl<N: preserves::value::NestedValue> Default for Language<N> {
fn default() -> Self {
Language {
LIT_15_FALSE: /* #f */ _support::decode_lit(&vec![128]).unwrap(),
LIT_28_1: /* 1 */ _support::decode_lit(&vec![145]).unwrap(),
LIT_0_BOOLEAN: /* Boolean */ _support::decode_lit(&vec![179, 7, 66, 111, 111, 108, 101, 97, 110]).unwrap(),
LIT_5_BYTE_STRING: /* ByteString */ _support::decode_lit(&vec![179, 10, 66, 121, 116, 101, 83, 116, 114, 105, 110, 103]).unwrap(),
LIT_2_DOUBLE: /* Double */ _support::decode_lit(&vec![179, 6, 68, 111, 117, 98, 108, 101]).unwrap(),
LIT_1_FLOAT: /* Float */ _support::decode_lit(&vec![179, 5, 70, 108, 111, 97, 116]).unwrap(),
LIT_3_SIGNED_INTEGER: /* SignedInteger */ _support::decode_lit(&vec![179, 13, 83, 105, 103, 110, 101, 100, 73, 110, 116, 101, 103, 101, 114]).unwrap(),
LIT_4_STRING: /* String */ _support::decode_lit(&vec![179, 6, 83, 116, 114, 105, 110, 103]).unwrap(),
LIT_6_SYMBOL: /* Symbol */ _support::decode_lit(&vec![179, 6, 83, 121, 109, 98, 111, 108]).unwrap(),
LIT_14_AND: /* and */ _support::decode_lit(&vec![179, 3, 97, 110, 100]).unwrap(),
LIT_21_ANY: /* any */ _support::decode_lit(&vec![179, 3, 97, 110, 121]).unwrap(),
LIT_22_ATOM: /* atom */ _support::decode_lit(&vec![179, 4, 97, 116, 111, 109]).unwrap(),
LIT_8_BUNDLE: /* bundle */ _support::decode_lit(&vec![179, 6, 98, 117, 110, 100, 108, 101]).unwrap(),
LIT_18_DEFINITIONS: /* definitions */ _support::decode_lit(&vec![179, 11, 100, 101, 102, 105, 110, 105, 116, 105, 111, 110, 115]).unwrap(),
LIT_12_DICT: /* dict */ _support::decode_lit(&vec![179, 4, 100, 105, 99, 116]).unwrap(),
LIT_27_DICTOF: /* dictof */ _support::decode_lit(&vec![179, 6, 100, 105, 99, 116, 111, 102]).unwrap(),
LIT_23_EMBEDDED: /* embedded */ _support::decode_lit(&vec![179, 8, 101, 109, 98, 101, 100, 100, 101, 100]).unwrap(),
LIT_19_EMBEDDED_TYPE: /* embeddedType */ _support::decode_lit(&vec![179, 12, 101, 109, 98, 101, 100, 100, 101, 100, 84, 121, 112, 101]).unwrap(),
LIT_24_LIT: /* lit */ _support::decode_lit(&vec![179, 3, 108, 105, 116]).unwrap(),
LIT_7_NAMED: /* named */ _support::decode_lit(&vec![179, 5, 110, 97, 109, 101, 100]).unwrap(),
LIT_13_OR: /* or */ _support::decode_lit(&vec![179, 2, 111, 114]).unwrap(),
LIT_9_REC: /* rec */ _support::decode_lit(&vec![179, 3, 114, 101, 99]).unwrap(),
LIT_16_REF: /* ref */ _support::decode_lit(&vec![179, 3, 114, 101, 102]).unwrap(),
LIT_17_SCHEMA: /* schema */ _support::decode_lit(&vec![179, 6, 115, 99, 104, 101, 109, 97]).unwrap(),
LIT_25_SEQOF: /* seqof */ _support::decode_lit(&vec![179, 5, 115, 101, 113, 111, 102]).unwrap(),
LIT_26_SETOF: /* setof */ _support::decode_lit(&vec![179, 5, 115, 101, 116, 111, 102]).unwrap(),
LIT_10_TUPLE: /* tuple */ _support::decode_lit(&vec![179, 5, 116, 117, 112, 108, 101]).unwrap(),
LIT_11_TUPLE_PREFIX: /* tuplePrefix */ _support::decode_lit(&vec![179, 11, 116, 117, 112, 108, 101, 80, 114, 101, 102, 105, 120]).unwrap(),
LIT_20_VERSION: /* version */ _support::decode_lit(&vec![179, 7, 118, 101, 114, 115, 105, 111, 110]).unwrap()
LIT_15_FALSE: /* #f */ _support::decode_lit(&[128]).unwrap(),
LIT_28_1: /* 1 */ _support::decode_lit(&[145]).unwrap(),
LIT_0_BOOLEAN: /* Boolean */ _support::decode_lit(&[179, 7, 66, 111, 111, 108, 101, 97, 110]).unwrap(),
LIT_5_BYTE_STRING: /* ByteString */ _support::decode_lit(&[179, 10, 66, 121, 116, 101, 83, 116, 114, 105, 110, 103]).unwrap(),
LIT_2_DOUBLE: /* Double */ _support::decode_lit(&[179, 6, 68, 111, 117, 98, 108, 101]).unwrap(),
LIT_1_FLOAT: /* Float */ _support::decode_lit(&[179, 5, 70, 108, 111, 97, 116]).unwrap(),
LIT_3_SIGNED_INTEGER: /* SignedInteger */ _support::decode_lit(&[179, 13, 83, 105, 103, 110, 101, 100, 73, 110, 116, 101, 103, 101, 114]).unwrap(),
LIT_4_STRING: /* String */ _support::decode_lit(&[179, 6, 83, 116, 114, 105, 110, 103]).unwrap(),
LIT_6_SYMBOL: /* Symbol */ _support::decode_lit(&[179, 6, 83, 121, 109, 98, 111, 108]).unwrap(),
LIT_14_AND: /* and */ _support::decode_lit(&[179, 3, 97, 110, 100]).unwrap(),
LIT_21_ANY: /* any */ _support::decode_lit(&[179, 3, 97, 110, 121]).unwrap(),
LIT_22_ATOM: /* atom */ _support::decode_lit(&[179, 4, 97, 116, 111, 109]).unwrap(),
LIT_8_BUNDLE: /* bundle */ _support::decode_lit(&[179, 6, 98, 117, 110, 100, 108, 101]).unwrap(),
LIT_18_DEFINITIONS: /* definitions */ _support::decode_lit(&[179, 11, 100, 101, 102, 105, 110, 105, 116, 105, 111, 110, 115]).unwrap(),
LIT_12_DICT: /* dict */ _support::decode_lit(&[179, 4, 100, 105, 99, 116]).unwrap(),
LIT_27_DICTOF: /* dictof */ _support::decode_lit(&[179, 6, 100, 105, 99, 116, 111, 102]).unwrap(),
LIT_23_EMBEDDED: /* embedded */ _support::decode_lit(&[179, 8, 101, 109, 98, 101, 100, 100, 101, 100]).unwrap(),
LIT_19_EMBEDDED_TYPE: /* embeddedType */ _support::decode_lit(&[179, 12, 101, 109, 98, 101, 100, 100, 101, 100, 84, 121, 112, 101]).unwrap(),
LIT_24_LIT: /* lit */ _support::decode_lit(&[179, 3, 108, 105, 116]).unwrap(),
LIT_7_NAMED: /* named */ _support::decode_lit(&[179, 5, 110, 97, 109, 101, 100]).unwrap(),
LIT_13_OR: /* or */ _support::decode_lit(&[179, 2, 111, 114]).unwrap(),
LIT_9_REC: /* rec */ _support::decode_lit(&[179, 3, 114, 101, 99]).unwrap(),
LIT_16_REF: /* ref */ _support::decode_lit(&[179, 3, 114, 101, 102]).unwrap(),
LIT_17_SCHEMA: /* schema */ _support::decode_lit(&[179, 6, 115, 99, 104, 101, 109, 97]).unwrap(),
LIT_25_SEQOF: /* seqof */ _support::decode_lit(&[179, 5, 115, 101, 113, 111, 102]).unwrap(),
LIT_26_SETOF: /* setof */ _support::decode_lit(&[179, 5, 115, 101, 116, 111, 102]).unwrap(),
LIT_10_TUPLE: /* tuple */ _support::decode_lit(&[179, 5, 116, 117, 112, 108, 101]).unwrap(),
LIT_11_TUPLE_PREFIX: /* tuplePrefix */ _support::decode_lit(&[179, 11, 116, 117, 112, 108, 101, 80, 114, 101, 102, 105, 120]).unwrap(),
LIT_20_VERSION: /* version */ _support::decode_lit(&[179, 7, 118, 101, 114, 115, 105, 111, 110]).unwrap()
}
}
}