allTokens lexes the entire input, but does not parse it. It returns all the tokens from the input, unstructured and in order. It may mutate input as it expands env vars.
(filename string, input []byte)
| 61 | // It returns all the tokens from the input, unstructured |
| 62 | // and in order. It may mutate input as it expands env vars. |
| 63 | func allTokens(filename string, input []byte) ([]Token, error) { |
| 64 | return Tokenize(replaceEnvVars(input), filename) |
| 65 | } |
| 66 | |
| 67 | // replaceEnvVars replaces all occurrences of environment variables. |
| 68 | // It mutates the underlying array and returns the updated slice. |