Example #1
0
        public static Node ParseFile(string file)
        {
            string code = File.ReadAllText(file);
            Node   n    = AkiraParser.Parse(code);

            return(n);
        }
Example #2
0
        public static Node ParseModule(string file)
        {
            string name = Path.GetFileNameWithoutExtension(file);
            string code = File.ReadAllText(file);
            Node   n    = AkiraParser.Parse(code);

            n.AddFirst(__(":", __("id"), __(name)));
            n.Data = "module";
            return(n);
        }