import { Gms2ResourceBase } from '../components/resources/Gms2ResourceBase.js';
import { GmlToken } from './GmlToken.js';
import { GmlTokenVersioned } from './GmlTokenVersioned.js';
declare global {
    const hello = "world";
}
export interface GmlTokenReferenceOptions {
    versionSuffix?: string;
}
/**
 * Replace a portion of a string, starting at `start`,
 * and subsequent `length` chars with a different string
 */
export declare function stringReplaceSegment(string: string, start: number, length: number): string;
export interface GmlPosition {
    code: string;
    position: number;
    length: number;
    line: number;
}
export interface GmlStripped {
    input: string;
    stripped: string;
    strings: GmlPosition[];
    comments: GmlPosition[];
}
/**
 * Return a copy of the source GML with all comments and
 * strings replaced with whitespace, preserving the ovderall
 * structure of the GML but preventing such content from
 * confusing other parser activities (stuff inside strings
 * and comments can use keywords or variable names without
 * creating references -- further, string and comment delimiters
 * can confuse *each other*, so clearing all of that is helpful.)
 */
export declare function stripCommentsAndStringsFromGml(gml: string): GmlStripped;
/**
 * Find all functions defined in the outer scope for
 * some chunk of GML.
 */
export declare function findOuterFunctions<Resource extends Gms2ResourceBase = Gms2ResourceBase>(gml: string, resource?: Resource): GmlToken[];
export declare function findTokenReferences<Resource extends Gms2ResourceBase = Gms2ResourceBase>(gml: string, token: string | GmlToken, options?: {
    /**
     * The resource this GML comes from. If not provided,
     * this information will not be attached to the resulting
     * token data.
     */
    resource?: Resource;
    suffixPattern?: string;
    /**
     * By default, discovered references that are the *same* references
     * as the search token are ignored.
     */
    includeSelf?: boolean;
    /**
     * If the source GML comes from a resource with multiple GML files,
     * the sublocation should be used to differentiate.
     */
    sublocation?: string;
}): GmlTokenVersioned[];
//# sourceMappingURL=codeParser.d.ts.map