Consider using `vscode.executeDocumentSymbolProvider` to get access to parameters
Rather than parsing files yourself, you can leverage the language server support built into vscode. By using the complex command vscode.executeDocumentSymbolProvider vscode will provide all the document symbols found in the file. From there you can do something like find all the SymbolKind.Function and SymbolKind.Method and then look for children with locations before the ending ) or =>. (since there currently isn't a SymbolKind.Parameter unfortunately).
Here is an example of how I use vscode.executeDocumentSymbolProvider in GitLens: https://github.com/eamodio/vscode-gitlens/blob/develop/src/codelens/codeLensProvider.ts#L174
Other than the ending characters of the function (assuming there isn't enough to go on in the symbol data), the rest should be language agnostic -- so you can support most languages that vscode has language server support for.