Utility.ParseSource(string)

Method in Utility

WARNING

This method is obsolete and may be removed from a future version of Yarn Spinner: Use ParseSourceText.

Summary

Parses a string of Yarn source code, and produces a FileParseResult and (if there were any problems) a collection of diagnostics.

public static (FileParseResult, IEnumerable<Diagnostic>) ParseSource(string source)

Parameters

NameDescription
string sourceThe source code to parse.

Returns

A tuple containing a FileParseResult that stores the parse tree and tokens, and a collection of Diagnostic objects that describe problems in the source code.