{"id":"word--assert","name":"assert","owner":"yeho","package":"language","kind":"keyword","signature":"assert","description":"Unavailable statement; use an explicit check and error","context":"Use the replacement that makes ownership and flow explicit. Revisit dedicated syntax only after it earns a compiler, runtime, and verification contract.","parameters":[],"returns":"","members":[],"tags":["boundaries","cpu","keyword","language","yeho"],"updated":"2026-09-09","source":{"repository":"yeho","path":"parser_core.cpp and parser_statements.cpp rejection diagnostics; language-core.md §13.4"},"status":"unavailable","notes":["panic, assert, fatal, exception subclasses, and finally are not admitted error syntax.","Dedicated event, emit, and watch syntax is deferred in favor of ordinary values, functions, tasks, and tunnels."],"examples":[{"id":"complete","title":"Complete program","description":"A complete example you can paste into start.yh.","code":"// assert is not admitted; validate explicitly.\nint score = 10\nif score < 0 { Console.Error(\"Score must be nonnegative\") }\nelse { Console.Log(Text.From(score)) }\n","tags":["cpu","language"],"run":"cpu-oracle","expected":null,"verifyRun":false,"manifest":"manifestVersion = \"2\"\npackage = \"api.example.word__assert\"\nversion = \"0.1.0\"\nlanguageEdition = \"yeho-core-2026.1\"\n\n[app]\nkind = \"headless\"\n","verification":"type checked","sha256":"5e40e0c9c9046de9736c442502ece78badbaef596f48507d9a6cdea685c93572","checked":"2026-09-09","diagnostic":"","observedOutput":null,"checkedBackend":null}],"searchTerms":[],"url":"https://demonhunterlabs.com/academy/api?item=word--assert","json":"https://demonhunterlabs.com/reference/items/word--assert.json","markdown":"https://demonhunterlabs.com/reference/text/word--assert.md"}
