function defineEnvironment(names, props, handler) {
                    if (typeof names === "string") {
                        names = [names];
                    }
                    if (typeof props === "number") {
                        props = { numArgs: props };
                    }
                    // Set default values of environments
                    var data = {
                        numArgs: props.numArgs || 0,
                        argTypes: props.argTypes,
                        greediness: 1,
                        allowedInText: !!props.allowedInText,
                        numOptionalArgs: props.numOptionalArgs || 0,
                        handler: handler,
                    };
                    for (var i = 0; i < names.length; ++i) {
                        module.exports[names[i]] = data;
                    }
                }
This function lexes a single normal token. It takes a position and
whether it should completely ignore whitespace or not.