Skip to content

Commit

Permalink
fix: build failed
Browse files Browse the repository at this point in the history
  • Loading branch information
sbwtw committed Jan 6, 2024
1 parent c7e3e69 commit a531400
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/src/test/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -47,12 +47,12 @@ fn test_scope_lookup() {
let app_ctx = mgr.write().get_context(app_id).unwrap();
let global = StLexerBuilder::new().build_str("VAR_GLOBAL END_VAR VAR_GLOBAL g1: REAL; END_VAR");
let global = StDeclarationParser::new().parse(global).unwrap();
let _global_id = app_ctx.write().add_declaration(global);
let _global_id = app_ctx.write().add_declaration(global, Uuid::nil());

let test_func =
StLexerBuilder::new().build_str("program prg: int VAR g1: BYTE; END_VAR end_program");
let test_fun_decl = StDeclarationParser::new().parse(test_func).unwrap();
let test_fun_decl_id = app_ctx.write().add_declaration(test_fun_decl);
let test_fun_decl_id = app_ctx.write().add_declaration(test_fun_decl, Uuid::nil());

let scope = Scope::new(Some(mgr.clone()), Some(app_id), Some(test_fun_decl_id));
let variable = scope.find_variable(&StString::new("g1"));
Expand Down

0 comments on commit a531400

Please sign in to comment.