mirror of
https://github.com/HigherOrderCO/Bend.git
synced 2024-09-19 07:37:56 +03:00
Fix typos
This commit is contained in:
parent
898440d025
commit
b75aaead7e
@ -13,7 +13,7 @@ pub trait BuiltinAdt {
|
|||||||
/// Returns true if the built-in adt was used.
|
/// Returns true if the built-in adt was used.
|
||||||
fn encode_terms(&self, book: &mut Book) -> bool;
|
fn encode_terms(&self, book: &mut Book) -> bool;
|
||||||
|
|
||||||
/// Checks if the adt name or any constructor name was overriden by the user.
|
/// Checks if the adt name or any constructor name was overridden by the user.
|
||||||
fn check(&self, book: &Book) -> Result<(), String> {
|
fn check(&self, book: &Book) -> Result<(), String> {
|
||||||
let adt_name = self.name();
|
let adt_name = self.name();
|
||||||
if book.adts.contains_key(&adt_name) {
|
if book.adts.contains_key(&adt_name) {
|
||||||
@ -21,7 +21,7 @@ pub trait BuiltinAdt {
|
|||||||
}
|
}
|
||||||
for (ctr, ..) in self.constructors() {
|
for (ctr, ..) in self.constructors() {
|
||||||
if book.ctrs.contains_key(&ctr) {
|
if book.ctrs.contains_key(&ctr) {
|
||||||
return Err(format!("{ctr} is a built-in constructor and should not be overriden."));
|
return Err(format!("{ctr} is a built-in constructor and should not be overridden."));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Ok(())
|
Ok(())
|
||||||
|
@ -2,4 +2,4 @@
|
|||||||
source: tests/golden_tests.rs
|
source: tests/golden_tests.rs
|
||||||
input_file: tests/golden_tests/run_file/override_list_ctr.hvm
|
input_file: tests/golden_tests/run_file/override_list_ctr.hvm
|
||||||
---
|
---
|
||||||
LNil is a built-in constructor and should not be overriden.
|
LNil is a built-in constructor and should not be overridden.
|
||||||
|
@ -2,4 +2,4 @@
|
|||||||
source: tests/golden_tests.rs
|
source: tests/golden_tests.rs
|
||||||
input_file: tests/golden_tests/run_file/override_str_ctr.hvm
|
input_file: tests/golden_tests/run_file/override_str_ctr.hvm
|
||||||
---
|
---
|
||||||
SCons is a built-in constructor and should not be overriden.
|
SCons is a built-in constructor and should not be overridden.
|
||||||
|
Loading…
Reference in New Issue
Block a user