Update error text
This commit is contained in:
parent
98169af415
commit
f9f9360efc
@ -26,9 +26,9 @@ pub enum ErrorKind {
|
||||
FunctionNotDefined(String),
|
||||
#[error("Expected a return type of {0}, got {1} instead")]
|
||||
ReturnTypeMismatch(TypeKind, TypeKind),
|
||||
#[error("Function not defined: {0}")]
|
||||
#[error("Function already defined: {0}")]
|
||||
FunctionAlreadyDefined(String),
|
||||
#[error("Variable not defined: {0}")]
|
||||
#[error("Variable already defined: {0}")]
|
||||
VariableAlreadyDefined(String),
|
||||
#[error("Variable {0} is not declared as mutable")]
|
||||
VariableNotMutable(String),
|
||||
|
@ -7,8 +7,10 @@ fn array() -> [[[u16; 4];1];1] {
|
||||
fn main() -> u16 {
|
||||
let mut list = array();
|
||||
|
||||
list[0][0][2] = 19;
|
||||
let a = 1;
|
||||
let a = [[[5, 3, 2]]];
|
||||
|
||||
return list[0][0][a + 1];
|
||||
list[0][0][2] = 19;
|
||||
// let a = 1;
|
||||
|
||||
return a[0][0][1];
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user