parse

Function parse 

Source
pub fn parse(source: &str) -> Result<Module, PtxParseError>
Expand description

Parse a PTX source string into a lightweight abstract syntax tree (AST).

The parser performs a tolerant, line-oriented pass that recognises module-level directives and function definitions. Inside functions it categorises labels, directives, and instructions, providing a structured representation without attempting full semantic validation of PTX.